aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/AI/SmartScripts
diff options
context:
space:
mode:
authorKinzcool <kinzzcool@hotmail.com>2014-04-27 18:13:55 -0400
committerKinzcool <kinzzcool@hotmail.com>2014-04-27 18:13:55 -0400
commitc536305e3a3c4f41e94d14fae73ba7a2d8d13be2 (patch)
treecfbaa50362191e8a8edb11f7c360643730e3d688 /src/server/game/AI/SmartScripts
parenta1e8cad70351ead7e98707587a4fb68e79a364c8 (diff)
Core: Droped `faction_H` field -- only one faction table is necessary
Diffstat (limited to 'src/server/game/AI/SmartScripts')
-rw-r--r--src/server/game/AI/SmartScripts/SmartAI.cpp2
-rw-r--r--src/server/game/AI/SmartScripts/SmartScript.cpp6
2 files changed, 4 insertions, 4 deletions
diff --git a/src/server/game/AI/SmartScripts/SmartAI.cpp b/src/server/game/AI/SmartScripts/SmartAI.cpp
index 521f39171af..098f3130fed 100644
--- a/src/server/game/AI/SmartScripts/SmartAI.cpp
+++ b/src/server/game/AI/SmartScripts/SmartAI.cpp
@@ -532,7 +532,7 @@ void SmartAI::JustRespawned()
mDespawnState = 0;
mEscortState = SMART_ESCORT_NONE;
me->SetVisible(true);
- if (me->getFaction() != me->GetCreatureTemplate()->faction_A)
+ if (me->getFaction() != me->GetCreatureTemplate()->faction)
me->RestoreFaction();
GetScript()->ProcessEventsFor(SMART_EVENT_RESPAWN);
mJustReset = true;
diff --git a/src/server/game/AI/SmartScripts/SmartScript.cpp b/src/server/game/AI/SmartScripts/SmartScript.cpp
index a0e516ca819..1032af57460 100644
--- a/src/server/game/AI/SmartScripts/SmartScript.cpp
+++ b/src/server/game/AI/SmartScripts/SmartScript.cpp
@@ -261,11 +261,11 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
{
if (CreatureTemplate const* ci = sObjectMgr->GetCreatureTemplate((*itr)->ToCreature()->GetEntry()))
{
- if ((*itr)->ToCreature()->getFaction() != ci->faction_A)
+ if ((*itr)->ToCreature()->getFaction() != ci->faction)
{
- (*itr)->ToCreature()->setFaction(ci->faction_A);
+ (*itr)->ToCreature()->setFaction(ci->faction);
TC_LOG_DEBUG("scripts.ai", "SmartScript::ProcessAction:: SMART_ACTION_SET_FACTION: Creature entry %u, GuidLow %u set faction to %u",
- (*itr)->GetEntry(), (*itr)->GetGUIDLow(), ci->faction_A);
+ (*itr)->GetEntry(), (*itr)->GetGUIDLow(), ci->faction);
}
}
}