refactor(Core): update getFaction to GetFaction and setFaction to SetFaction (#8708)

This commit is contained in:
Malcrom
2021-11-01 13:04:32 -03:00
committed by GitHub
parent 3396a9da87
commit f106de8788
129 changed files with 418 additions and 444 deletions

View File

@@ -238,7 +238,7 @@ void BattlefieldWG::OnBattleStart()
if (Creature* creature = GetCreature(*itr))
{
ShowNpc(creature, true);
creature->setFaction(WintergraspFaction[GetDefenderTeam()]);
creature->SetFaction(WintergraspFaction[GetDefenderTeam()]);
}
}
@@ -348,7 +348,7 @@ void BattlefieldWG::OnBattleEnd(bool endByTimer)
if (Creature* creature = GetCreature(*itr))
{
if (!endByTimer)
creature->setFaction(WintergraspFaction[GetDefenderTeam()]);
creature->SetFaction(WintergraspFaction[GetDefenderTeam()]);
HideNpc(creature);
}
}
@@ -610,7 +610,7 @@ void BattlefieldWG::OnCreatureCreate(Creature* creature)
return;
if (Unit* owner = creature->ToTempSummon()->GetSummonerUnit())
creature->setFaction(owner->getFaction());
creature->SetFaction(owner->GetFaction());
break;
}
}
@@ -630,9 +630,9 @@ void BattlefieldWG::OnCreatureRemove(Creature* /*creature*/)
case NPC_WINTERGRASP_DEMOLISHER:
{
uint8 team;
if (creature->getFaction() == WintergraspFaction[TEAM_ALLIANCE])
if (creature->GetFaction() == WintergraspFaction[TEAM_ALLIANCE])
team = TEAM_ALLIANCE;
else if (creature->getFaction() == WintergraspFaction[TEAM_HORDE])
else if (creature->GetFaction() == WintergraspFaction[TEAM_HORDE])
team = TEAM_HORDE;
else
return;