1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Create faster key cache for main game loop (client)

This commit is contained in:
Craig Robbins 2014-11-10 12:26:19 +10:00
parent 18c583ee0b
commit 987e565eeb
4 changed files with 202 additions and 53 deletions

View file

@ -32,8 +32,12 @@
#include "settings.h"
#include <algorithm>
#include "mainmenumanager.h" // for g_gamecallback
#define KMaxButtonPerColumns 12
extern MainGameCallback *g_gamecallback;
enum
{
GUI_ID_BACK_BUTTON = 101, GUI_ID_ABORT_BUTTON, GUI_ID_SCROLL_BAR,
@ -234,7 +238,11 @@ bool GUIKeyChangeMenu::acceptInput()
if(e != NULL && e->getType() == gui::EGUIET_CHECK_BOX)
g_settings->setBool("doubletap_jump", ((gui::IGUICheckBox*)e)->isChecked());
}
clearKeyCache();
g_gamecallback->signalKeyConfigChange();
return true;
}