diff --git a/data/game_config.cfg b/data/game_config.cfg index b22668b95b0..9cf776986a8 100644 --- a/data/game_config.cfg +++ b/data/game_config.cfg @@ -106,6 +106,7 @@ game_user_leave = "leave.wav" ready_for_start = "bell.wav" game_has_begun = "gamestart.ogg" + game_created = "chat-highlight.ogg" [status] slowed="slowed.wav" diff --git a/src/game_initialization/lobby_info.cpp b/src/game_initialization/lobby_info.cpp index edba8487ca2..08ee6576e6e 100644 --- a/src/game_initialization/lobby_info.cpp +++ b/src/game_initialization/lobby_info.cpp @@ -74,7 +74,7 @@ void do_notify(notify_mode mode, const std::string& sender, const std::string& m mp_ui_alerts::public_message(true, sender, message); break; case NOTIFY_GAME_CREATED: - mp_ui_alerts::game_created(true, sender, message); + mp_ui_alerts::game_created(sender, message); break; default: break; diff --git a/src/game_initialization/lobby_info.hpp b/src/game_initialization/lobby_info.hpp index 9a116e6bef2..6220b3be2d8 100644 --- a/src/game_initialization/lobby_info.hpp +++ b/src/game_initialization/lobby_info.hpp @@ -183,7 +183,6 @@ enum notify_mode { NOTIFY_WHISPER_OTHER_WINDOW, NOTIFY_LOBBY_JOIN, NOTIFY_LOBBY_QUIT, - NOTIFY_COUNT, NOTIFY_GAME_CREATED }; diff --git a/src/mp_ui_alerts.cpp b/src/mp_ui_alerts.cpp index 6af74b436b1..47b8216458d 100644 --- a/src/mp_ui_alerts.cpp +++ b/src/mp_ui_alerts.cpp @@ -50,14 +50,12 @@ bool notif_pref(const std::string& id) } // end anonymous namespace -// Note: This list must agree with data/gui/.../lobby_sound_options.cfg -// @lilinitsy: As of 1.14, it seems the above comment is not true, but someone could check. const std::vector items {"player_joins", "player_leaves", "private_message", "friend_message", "public_message", "server_message", "ready_for_start", "game_has_begun", "turn_changed", "game_created"}; -void game_created(bool is_lobby, const std::string & scenario, const std::string & name) +void game_created(const std::string & scenario, const std::string & name) { std::string id = "game_created"; - if (is_lobby && !lobby_pref(id)) { + if (!lobby_pref(id)) { return ; } diff --git a/src/mp_ui_alerts.hpp b/src/mp_ui_alerts.hpp index ffe4716b536..431da4c7a74 100644 --- a/src/mp_ui_alerts.hpp +++ b/src/mp_ui_alerts.hpp @@ -27,7 +27,7 @@ namespace mp_ui_alerts { // Functions called when such an event occurs void player_joins(bool is_lobby); void player_leaves(bool is_lobby); - void game_created(bool is_lobby, const std::string & scenario, const std::string & name); + void game_created(const std::string & scenario, const std::string & name); void public_message(bool is_lobby, const std::string & sender, const std::string & message); void friend_message(bool is_lobby, const std::string & sender, const std::string & message); void private_message(bool is_lobby, const std::string & sender, const std::string & message);