From c85d939d9b3f6c10288dc86ffa7811408e349657 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 28 Feb 2012 02:14:15 +0300 Subject: Add different sound effects for different events. Can be configured in audio tab in settings. --- src/net/ea/charserverhandler.cpp | 4 ++-- src/net/ea/gamehandler.cpp | 2 +- src/net/ea/playerhandler.cpp | 7 +++---- 3 files changed, 6 insertions(+), 7 deletions(-) (limited to 'src/net/ea') diff --git a/src/net/ea/charserverhandler.cpp b/src/net/ea/charserverhandler.cpp index 2dc51acf3..67894b0d9 100644 --- a/src/net/ea/charserverhandler.cpp +++ b/src/net/ea/charserverhandler.cpp @@ -167,7 +167,7 @@ void CharServerHandler::processCharCreateFailed(Net::MessageIn &msg) errorMessage = _("Incorrect race."); break; } - new OkDialog(_("Error"), errorMessage); + new OkDialog(_("Error"), errorMessage, DIALOG_ERROR); if (mCharCreateDialog) mCharCreateDialog->unlock(); } @@ -185,7 +185,7 @@ void CharServerHandler::processCharDelete(Net::MessageIn &msg A_UNUSED) void CharServerHandler::processCharDeleteFailed(Net::MessageIn &msg A_UNUSED) { unlockCharSelectDialog(); - new OkDialog(_("Error"), _("Failed to delete character.")); + new OkDialog(_("Error"), _("Failed to delete character."), DIALOG_ERROR); } void CharServerHandler::clear() diff --git a/src/net/ea/gamehandler.cpp b/src/net/ea/gamehandler.cpp index 6d021d6a9..c8c870dbd 100644 --- a/src/net/ea/gamehandler.cpp +++ b/src/net/ea/gamehandler.cpp @@ -101,7 +101,7 @@ void GameHandler::processCharSwitchResponse(Net::MessageIn &msg) void GameHandler::processMapQuitResponse(Net::MessageIn &msg) { if (msg.readInt8()) - new OkDialog(_("Game"), _("Request to quit denied!"), nullptr); + new OkDialog(_("Game"), _("Request to quit denied!"), DIALOG_ERROR); } } // namespace Ea diff --git a/src/net/ea/playerhandler.cpp b/src/net/ea/playerhandler.cpp index 27aa4da80..ddcf7d9c0 100644 --- a/src/net/ea/playerhandler.cpp +++ b/src/net/ea/playerhandler.cpp @@ -336,7 +336,7 @@ void PlayerHandler::processPlayerStatUpdate1(Net::MessageIn &msg) weightNotice = new OkDialog(_("Message"), _("You are carrying more than " "half your weight. You are " - "unable to regain health."), false); + "unable to regain health."), DIALOG_ERROR, false); weightNotice->addActionListener( &weightListener); } @@ -346,7 +346,7 @@ void PlayerHandler::processPlayerStatUpdate1(Net::MessageIn &msg) weightNotice = new OkDialog(_("Message"), _("You are carrying less than " "half your weight. You " - "can regain health."), false); + "can regain health."), DIALOG_ERROR, false); weightNotice->addActionListener( &weightListener); } @@ -426,8 +426,7 @@ void PlayerHandler::processPlayerStatUpdate1(Net::MessageIn &msg) if (PlayerInfo::getAttribute(HP) == 0 && !deathNotice) { deathNotice = new OkDialog(_("Message"), - randomDeathMessage(), - false); + randomDeathMessage(), false); deathNotice->addActionListener(&deathListener); player_node->setAction(Being::DEAD); } -- cgit v1.2.3-70-g09d2