MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / IConsoleSwitch

Function IConsoleSwitch

src/console_gui.cpp:426–439  ·  view source on GitHub ↗

Toggle in-game console between opened and closed. */

Source from the content-addressed store, hash-verified

424
425/** Toggle in-game console between opened and closed. */
426void IConsoleSwitch()
427{
428 switch (_iconsole_mode) {
429 case ICONSOLE_CLOSED:
430 new IConsoleWindow();
431 break;
432
433 case ICONSOLE_OPENED: case ICONSOLE_FULL:
434 CloseWindowById(WC_CONSOLE, 0);
435 break;
436 }
437
438 MarkWholeScreenDirty();
439}
440
441/** Close the in-game console. */
442void IConsoleClose()

Callers 4

OnKeyPressMethod · 0.85
IConsoleCloseFunction · 0.85
MenuClickHelpFunction · 0.85
OnHotkeyMethod · 0.85

Calls 2

CloseWindowByIdFunction · 0.85
MarkWholeScreenDirtyFunction · 0.85

Tested by

no test coverage detected