mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2025-12-23 15:52:55 +01:00
Add shortcut for the Multiplayer window (#3509)
This commit is contained in:
@@ -4117,6 +4117,7 @@ STR_5808 :{WINDOW_COLOUR_2}Number of shops and stalls: {BLACK}{COMMA16}
|
|||||||
STR_5809 :{WINDOW_COLOUR_2}Number of information kiosks and other facilities: {BLACK}{COMMA16}
|
STR_5809 :{WINDOW_COLOUR_2}Number of information kiosks and other facilities: {BLACK}{COMMA16}
|
||||||
STR_5810 :Disable train length limit
|
STR_5810 :Disable train length limit
|
||||||
STR_5811 :{SMALLFONT}{BLACK}If checked, you can have up to{NEWLINE}255 cars per train
|
STR_5811 :{SMALLFONT}{BLACK}If checked, you can have up to{NEWLINE}255 cars per train
|
||||||
|
STR_5812 :Show multiplayer window
|
||||||
|
|
||||||
#############
|
#############
|
||||||
# Scenarios #
|
# Scenarios #
|
||||||
|
|||||||
@@ -77,6 +77,7 @@ enum {
|
|||||||
SHORTCUT_SHOW_OPTIONS,
|
SHORTCUT_SHOW_OPTIONS,
|
||||||
SHORTCUT_MUTE_SOUND,
|
SHORTCUT_MUTE_SOUND,
|
||||||
SHORTCUT_WINDOWED_MODE_TOGGLE,
|
SHORTCUT_WINDOWED_MODE_TOGGLE,
|
||||||
|
SHORTCUT_SHOW_MULTIPLAYER,
|
||||||
|
|
||||||
SHORTCUT_COUNT
|
SHORTCUT_COUNT
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -537,6 +537,12 @@ static void shortcut_windowed_mode_toggle()
|
|||||||
platform_toggle_windowed_mode();
|
platform_toggle_windowed_mode();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void shortcut_show_multiplayer()
|
||||||
|
{
|
||||||
|
if (network_get_mode() != NETWORK_MODE_NONE)
|
||||||
|
window_multiplayer_open();
|
||||||
|
}
|
||||||
|
|
||||||
static const shortcut_action shortcut_table[SHORTCUT_COUNT] = {
|
static const shortcut_action shortcut_table[SHORTCUT_COUNT] = {
|
||||||
shortcut_close_top_most_window,
|
shortcut_close_top_most_window,
|
||||||
shortcut_close_all_floating_windows,
|
shortcut_close_all_floating_windows,
|
||||||
@@ -585,7 +591,8 @@ static const shortcut_action shortcut_table[SHORTCUT_COUNT] = {
|
|||||||
shortcut_quick_save_game,
|
shortcut_quick_save_game,
|
||||||
shortcut_show_options,
|
shortcut_show_options,
|
||||||
shortcut_mute_sound,
|
shortcut_mute_sound,
|
||||||
shortcut_windowed_mode_toggle
|
shortcut_windowed_mode_toggle,
|
||||||
|
shortcut_show_multiplayer,
|
||||||
};
|
};
|
||||||
|
|
||||||
#pragma endregion
|
#pragma endregion
|
||||||
|
|||||||
@@ -2448,6 +2448,8 @@ enum {
|
|||||||
|
|
||||||
STR_CHEAT_DISABLE_TRAIN_LENGTH_LIMIT = 5810,
|
STR_CHEAT_DISABLE_TRAIN_LENGTH_LIMIT = 5810,
|
||||||
STR_CHEAT_DISABLE_TRAIN_LENGTH_LIMIT_TIP = 5811,
|
STR_CHEAT_DISABLE_TRAIN_LENGTH_LIMIT_TIP = 5811,
|
||||||
|
|
||||||
|
STR_SHORTCUT_SHOW_MULTIPLAYER = 5812,
|
||||||
|
|
||||||
// Have to include resource strings (from scenarios and objects) for the time being now that language is partially working
|
// Have to include resource strings (from scenarios and objects) for the time being now that language is partially working
|
||||||
STR_COUNT = 32768
|
STR_COUNT = 32768
|
||||||
|
|||||||
@@ -130,7 +130,8 @@ const rct_string_id ShortcutStringIds[] = {
|
|||||||
STR_SHORTCUT_QUICK_SAVE_GAME,
|
STR_SHORTCUT_QUICK_SAVE_GAME,
|
||||||
STR_SHORTCUT_SHOW_OPTIONS,
|
STR_SHORTCUT_SHOW_OPTIONS,
|
||||||
STR_SHORTCUT_MUTE_SOUND,
|
STR_SHORTCUT_MUTE_SOUND,
|
||||||
STR_SHORTCUT_WINDOWED_MODE_TOGGLE
|
STR_SHORTCUT_WINDOWED_MODE_TOGGLE,
|
||||||
|
STR_SHORTCUT_SHOW_MULTIPLAYER,
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user