aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorNay <dnpd.dd@gmail.com>2011-07-04 16:03:11 +0100
committerNay <dnpd.dd@gmail.com>2011-07-04 16:03:11 +0100
commit9ed52dc64687be74600ca95f302cf55b7ad77167 (patch)
treefcf41d622bca2ef8e3caf35cf0e845ea27cbda1a /src
parentd6782fa826508920f8de22709a32e83611bfdffe (diff)
Core/Commands: Update the trinity_string and cleanup the code related to .list auras command
Diffstat (limited to 'src')
-rwxr-xr-xsrc/server/game/Chat/Commands/Level3.cpp36
1 files changed, 8 insertions, 28 deletions
diff --git a/src/server/game/Chat/Commands/Level3.cpp b/src/server/game/Chat/Commands/Level3.cpp
index 83469f17100..1543bb3ea4c 100755
--- a/src/server/game/Chat/Commands/Level3.cpp
+++ b/src/server/game/Chat/Commands/Level3.cpp
@@ -2409,27 +2409,14 @@ bool ChatHandler::HandleListAurasCommand (const char * /*args*/)
Aura const* aura = aurApp->GetBase();
char const* name = aura->GetSpellProto()->SpellName[GetSessionDbcLocale()];
- if (m_session)
- {
- std::ostringstream ss_name;
- ss_name << "|cffffffff|Hspell:" << aura->GetId() << "|h[" << name << "]|h|r";
-
- PSendSysMessage(LANG_COMMAND_TARGET_AURADETAIL, aura->GetId(), aurApp->GetEffectMask(),
- aura->GetCharges(), aura->GetStackAmount(), aurApp->GetSlot(),
- aura->GetDuration(), aura->GetMaxDuration(),
- ss_name.str().c_str(),
- (aura->IsPassive() ? passiveStr : ""), (talent ? talentStr : ""),
- IS_PLAYER_GUID(aura->GetCasterGUID()) ? "player" : "creature", GUID_LOPART(aura->GetCasterGUID()));
- }
- else
- {
- PSendSysMessage(LANG_COMMAND_TARGET_AURADETAIL, aura->GetId(), aurApp->GetEffectMask(),
- aura->GetCharges(), aura->GetStackAmount(), aurApp->GetSlot(),
- aura->GetDuration(), aura->GetMaxDuration(),
- name,
- (aura->IsPassive() ? passiveStr : ""), (talent ? talentStr : ""),
- IS_PLAYER_GUID(aura->GetCasterGUID()) ? "player" : "creature", GUID_LOPART(aura->GetCasterGUID()));
- }
+ std::ostringstream ss_name;
+ ss_name << "|cffffffff|Hspell:" << aura->GetId() << "|h[" << name << "]|h|r";
+
+ PSendSysMessage(LANG_COMMAND_TARGET_AURADETAIL, aura->GetId(), (m_session ? ss_name.str().c_str() : name),
+ aurApp->GetEffectMask(), aura->GetCharges(), aura->GetStackAmount(), aurApp->GetSlot(),
+ aura->GetDuration(), aura->GetMaxDuration(), (aura->IsPassive() ? passiveStr : ""),
+ (talent ? talentStr : ""), IS_PLAYER_GUID(aura->GetCasterGUID()) ? "player" : "creature",
+ GUID_LOPART(aura->GetCasterGUID()));
}
for (uint16 i = 0; i < TOTAL_AURAS; ++i)
{
@@ -2438,13 +2425,6 @@ bool ChatHandler::HandleListAurasCommand (const char * /*args*/)
PSendSysMessage(LANG_COMMAND_TARGET_LISTAURATYPE, uAuraList.size(), i);
for (Unit::AuraEffectList::const_iterator itr = uAuraList.begin(); itr != uAuraList.end(); ++itr)
{
- //bool talent = GetTalentSpellCost((*itr)->GetId()) > 0;
-
- char const* name = (*itr)->GetSpellProto()->SpellName[GetSessionDbcLocale()];
-
- std::ostringstream ss_name;
- ss_name << "|cffffffff|Hspell:" << (*itr)->GetId() << "|h[" << name << "]|h|r";
-
PSendSysMessage(LANG_COMMAND_TARGET_AURASIMPLE, (*itr)->GetId(), (*itr)->GetEffIndex(),
(*itr)->GetAmount());
}