summaryrefslogtreecommitdiff
path: root/src/game.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/game.cpp')
-rw-r--r--src/game.cpp23
1 files changed, 21 insertions, 2 deletions
diff --git a/src/game.cpp b/src/game.cpp
index ebf5028b7..465e83ea5 100644
--- a/src/game.cpp
+++ b/src/game.cpp
@@ -52,6 +52,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include "tile.h" // For TextureSource
#include "logoutputbuffer.h"
#include "subgame.h"
+#include "quicktune_shortcutter.h"
/*
Setting this to 1 enables a special camera mode that forces
@@ -676,9 +677,7 @@ void the_game(
s32 hotbar_imagesize = 48;
// The color of the sky
-
//video::SColor skycolor = video::SColor(255,140,186,250);
-
video::SColor bgcolor_bright = video::SColor(255,170,200,230);
/*
@@ -699,6 +698,9 @@ void the_game(
// Add chat log output for errors to be shown in chat
LogOutputBuffer chat_log_error_buf(LMT_ERROR);
+ // Create UI for modifying quicktune values
+ QuicktuneShortcutter quicktune;
+
/*
Create server.
SharedPtr will delete it when it goes out of scope.
@@ -1542,6 +1544,23 @@ void the_game(
+ itos(range_new));
statustext_time = 0;
}
+
+ // Handle QuicktuneShortcutter
+ if(input->wasKeyDown(getKeySetting("keymap_quicktune_next")))
+ quicktune.next();
+ if(input->wasKeyDown(getKeySetting("keymap_quicktune_prev")))
+ quicktune.prev();
+ if(input->wasKeyDown(getKeySetting("keymap_quicktune_inc")))
+ quicktune.inc();
+ if(input->wasKeyDown(getKeySetting("keymap_quicktune_dec")))
+ quicktune.dec();
+ {
+ std::string msg = quicktune.getMessage();
+ if(msg != ""){
+ statustext = narrow_to_wide(msg);
+ statustext_time = 0;
+ }
+ }
// Item selection with mouse wheel
u16 new_playeritem = client.getPlayerItem();