mirror of
				https://github.com/luanti-org/luanti.git
				synced 2025-11-04 09:15:29 +01:00 
			
		
		
		
	Change exit keybinding and fix bug in allow_close[]
This commit is contained in:
		@@ -57,7 +57,7 @@ Some can be changed in the key config dialog in the settings tab.
 | 
			
		||||
| T                             | Chat                                                           |
 | 
			
		||||
| /                             | Command                                                        |
 | 
			
		||||
| Esc                           | Pause menu/abort/exit (pauses only singleplayer game)          |
 | 
			
		||||
| Ctrl + Esc                    | Exit directly to main menu from anywhere, bypassing pause menu |
 | 
			
		||||
| Shift + Esc                   | Exit directly to main menu from anywhere, bypassing pause menu |
 | 
			
		||||
| +                             | Increase view range                                            |
 | 
			
		||||
| -                             | Decrease view range                                            |
 | 
			
		||||
| K                             | Enable/disable fly mode (needs fly privilege)                  |
 | 
			
		||||
 
 | 
			
		||||
@@ -151,7 +151,7 @@ bool MyEventReceiver::OnEvent(const SEvent &event)
 | 
			
		||||
			fullscreen_is_down = event.KeyInput.PressedDown;
 | 
			
		||||
			return true;
 | 
			
		||||
		} else if (keyCode == EscapeKey &&
 | 
			
		||||
				event.KeyInput.PressedDown && event.KeyInput.Control) {
 | 
			
		||||
				event.KeyInput.PressedDown && event.KeyInput.Shift) {
 | 
			
		||||
			g_gamecallback->disconnect();
 | 
			
		||||
			return true;
 | 
			
		||||
		}
 | 
			
		||||
 
 | 
			
		||||
@@ -206,7 +206,10 @@ public:
 | 
			
		||||
 | 
			
		||||
	void defaultAllowClose(bool value)
 | 
			
		||||
	{
 | 
			
		||||
		// Also set m_allowclose here in order to have the correct value if
 | 
			
		||||
		// escape is pressed before regenerateGui() is called.
 | 
			
		||||
		m_default_allowclose = value;
 | 
			
		||||
		m_allowclose = value;
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	void setDebugView(bool value)
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user