mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-17 16:10:49 +01:00
REPO: Code-style clean-ups
* Fixed pMap->map * Fixed pInstance->instance * Fixed pInsta->instance * Fixed pQuest->quest * Fixed pWho->who * Fixed pTarget->target * Fixed pGo->go ~DEVNOTES: Handlers/QuestHandler.cpp still needs to be cleaned...
This commit is contained in:
@@ -155,7 +155,7 @@ class ScriptRegistry
|
||||
if (!V) \
|
||||
return R;
|
||||
|
||||
void DoScriptText(int32 iTextEntry, WorldObject* pSource, Unit* pTarget)
|
||||
void DoScriptText(int32 iTextEntry, WorldObject* pSource, Unit* target)
|
||||
{
|
||||
if (!pSource)
|
||||
{
|
||||
@@ -198,21 +198,21 @@ void DoScriptText(int32 iTextEntry, WorldObject* pSource, Unit* pTarget)
|
||||
switch (pData->uiType)
|
||||
{
|
||||
case CHAT_TYPE_SAY:
|
||||
pSource->MonsterSay(iTextEntry, pData->uiLanguage, pTarget ? pTarget->GetGUID() : 0);
|
||||
pSource->MonsterSay(iTextEntry, pData->uiLanguage, target ? target->GetGUID() : 0);
|
||||
break;
|
||||
case CHAT_TYPE_YELL:
|
||||
pSource->MonsterYell(iTextEntry, pData->uiLanguage, pTarget ? pTarget->GetGUID() : 0);
|
||||
pSource->MonsterYell(iTextEntry, pData->uiLanguage, target ? target->GetGUID() : 0);
|
||||
break;
|
||||
case CHAT_TYPE_TEXT_EMOTE:
|
||||
pSource->MonsterTextEmote(iTextEntry, pTarget ? pTarget->GetGUID() : 0);
|
||||
pSource->MonsterTextEmote(iTextEntry, target ? target->GetGUID() : 0);
|
||||
break;
|
||||
case CHAT_TYPE_BOSS_EMOTE:
|
||||
pSource->MonsterTextEmote(iTextEntry, pTarget ? pTarget->GetGUID() : 0, true);
|
||||
pSource->MonsterTextEmote(iTextEntry, target ? target->GetGUID() : 0, true);
|
||||
break;
|
||||
case CHAT_TYPE_WHISPER:
|
||||
{
|
||||
if (pTarget && pTarget->GetTypeId() == TYPEID_PLAYER)
|
||||
pSource->MonsterWhisper(iTextEntry, pTarget->GetGUID());
|
||||
if (target && target->GetTypeId() == TYPEID_PLAYER)
|
||||
pSource->MonsterWhisper(iTextEntry, target->GetGUID());
|
||||
else
|
||||
sLog->outError("TSCR: DoScriptText entry %i cannot whisper without target unit (TYPEID_PLAYER).", iTextEntry);
|
||||
|
||||
@@ -220,15 +220,15 @@ void DoScriptText(int32 iTextEntry, WorldObject* pSource, Unit* pTarget)
|
||||
}
|
||||
case CHAT_TYPE_BOSS_WHISPER:
|
||||
{
|
||||
if (pTarget && pTarget->GetTypeId() == TYPEID_PLAYER)
|
||||
pSource->MonsterWhisper(iTextEntry, pTarget->GetGUID(), true);
|
||||
if (target && target->GetTypeId() == TYPEID_PLAYER)
|
||||
pSource->MonsterWhisper(iTextEntry, target->GetGUID(), true);
|
||||
else
|
||||
sLog->outError("TSCR: DoScriptText entry %i cannot whisper without target unit (TYPEID_PLAYER).", iTextEntry);
|
||||
|
||||
break;
|
||||
}
|
||||
case CHAT_TYPE_ZONE_YELL:
|
||||
pSource->MonsterYellToZone(iTextEntry, pData->uiLanguage, pTarget ? pTarget->GetGUID() : 0);
|
||||
pSource->MonsterYellToZone(iTextEntry, pData->uiLanguage, target ? target->GetGUID() : 0);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user