mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-14 00:55:20 +02:00
Overhaul the input system
This allows us to map the keys which are not considered in irrlicht's EKEY_CODE system, such as \, [, /, ] etc.
This commit is contained in:
@@ -290,12 +290,9 @@ bool GUIInventoryMenu::OnEvent(const SEvent& event)
|
||||
{
|
||||
if(event.EventType==EET_KEY_INPUT_EVENT)
|
||||
{
|
||||
if(event.KeyInput.Key==KEY_ESCAPE && event.KeyInput.PressedDown)
|
||||
{
|
||||
quitMenu();
|
||||
return true;
|
||||
}
|
||||
if(event.KeyInput.Key==getKeySetting("keymap_inventory") && event.KeyInput.PressedDown)
|
||||
KeyPress kp(event.KeyInput);
|
||||
if (event.KeyInput.PressedDown && (kp == EscapeKey ||
|
||||
kp == getKeySetting("keymap_inventory")))
|
||||
{
|
||||
quitMenu();
|
||||
return true;
|
||||
|
Reference in New Issue
Block a user