summaryrefslogtreecommitdiff
path: root/src/localplayer.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-03-31 20:16:39 +0300
committerAndrei Karas <akaras@inbox.ru>2013-03-31 20:16:39 +0300
commit35d4ce0ed75b2575067007a85d5c211d292ebada (patch)
treee5749655db88531768635586e52508cefdfd8a5a /src/localplayer.cpp
parent8f52bfee633b4aa2f7e49c1e16428d8f1c03fcfc (diff)
downloadManaVerse-35d4ce0ed75b2575067007a85d5c211d292ebada.tar.gz
ManaVerse-35d4ce0ed75b2575067007a85d5c211d292ebada.tar.bz2
ManaVerse-35d4ce0ed75b2575067007a85d5c211d292ebada.tar.xz
ManaVerse-35d4ce0ed75b2575067007a85d5c211d292ebada.zip
Rename SoundManager sigleton from sound to soundManager.
Diffstat (limited to 'src/localplayer.cpp')
-rw-r--r--src/localplayer.cpp19
1 files changed, 10 insertions, 9 deletions
diff --git a/src/localplayer.cpp b/src/localplayer.cpp
index 3d2af40c6..c1d3b9c5f 100644
--- a/src/localplayer.cpp
+++ b/src/localplayer.cpp
@@ -202,7 +202,7 @@ LocalPlayer::~LocalPlayer()
if (mAwayDialog)
{
- sound.volumeRestore();
+ soundManager.volumeRestore();
delete mAwayDialog;
mAwayDialog = nullptr;
}
@@ -1307,11 +1307,12 @@ void LocalPlayer::attack(Being *const target, const bool keep,
std::string soundFile = mEquippedWeapon->getSound(
EQUIP_EVENT_STRIKE);
if (!soundFile.empty())
- sound.playSfx(soundFile);
+ soundManager.playSfx(soundFile);
}
else
{
- sound.playSfx(paths.getValue("attackSfxFile", "fist-swish.ogg"));
+ soundManager.playSfx(paths.getValue(
+ "attackSfxFile", "fist-swish.ogg"));
}
*/
if (!Client::limitPackets(PACKET_ATTACK))
@@ -2160,13 +2161,13 @@ void LocalPlayer::changeAwayMode()
config.getStringValue("afkMessage"),
DIALOG_SILENCE, true, false);
mAwayDialog->addActionListener(mAwayListener);
- sound.volumeOff();
+ soundManager.volumeOff();
addAfkEffect();
}
else
{
mAwayDialog = nullptr;
- sound.volumeRestore();
+ soundManager.volumeRestore();
if (chatWindow)
{
chatWindow->displayAwayLog();
@@ -3591,12 +3592,12 @@ void LocalPlayer::updateCoords()
MapItem::MUSIC);
if (str.empty())
str = mMap->getMusicFile();
- if (str != sound.getCurrentMusicFile())
+ if (str != soundManager.getCurrentMusicFile())
{
if (str.empty())
- sound.fadeOutMusic();
+ soundManager.fadeOutMusic();
else
- sound.fadeOutAndPlayMusic(str);
+ soundManager.fadeOutAndPlayMusic(str);
}
}
}
@@ -4129,7 +4130,7 @@ void LocalPlayer::checkNewName(Being *const being)
if (!mWaitFor.empty() && mWaitFor == nick)
{
debugMsg(strprintf(_("You see %s"), mWaitFor.c_str()));
- sound.playGuiSound(SOUND_INFO);
+ soundManager.playGuiSound(SOUND_INFO);
mWaitFor.clear();
}
}