mirror of
https://github.com/araxiaonline/TrinityCore.git
synced 2026-06-16 13:09:50 -04:00
Core/Misc: camelize GetFaction/SetFaction properly
This commit is contained in:
@@ -290,7 +290,7 @@ bool GameObject::Create(ObjectGuid::LowType guidlow, uint32 name_id, Map* map, u
|
||||
|
||||
if (m_goTemplateAddon)
|
||||
{
|
||||
SetUInt32Value(GAMEOBJECT_FACTION, m_goTemplateAddon->faction);
|
||||
SetFaction(m_goTemplateAddon->faction);
|
||||
SetUInt32Value(GAMEOBJECT_FLAGS, m_goTemplateAddon->flags);
|
||||
}
|
||||
|
||||
@@ -1886,7 +1886,7 @@ void GameObject::CastSpell(Unit* target, uint32 spellId, TriggerCastFlags trigge
|
||||
|
||||
if (Unit* owner = GetOwner())
|
||||
{
|
||||
trigger->setFaction(owner->getFaction());
|
||||
trigger->SetFaction(owner->GetFaction());
|
||||
if (owner->HasFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PVP_ATTACKABLE))
|
||||
trigger->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PVP_ATTACKABLE);
|
||||
// copy pvp state flags from owner
|
||||
@@ -1897,7 +1897,7 @@ void GameObject::CastSpell(Unit* target, uint32 spellId, TriggerCastFlags trigge
|
||||
}
|
||||
else
|
||||
{
|
||||
trigger->setFaction(spellInfo->IsPositive() ? 35 : 14);
|
||||
trigger->SetFaction(spellInfo->IsPositive() ? 35 : 14);
|
||||
// Set owner guid for target if no owner available - needed by trigger auras
|
||||
// - trigger gets despawned and there's no caster avalible (see AuraEffect::TriggerSpell())
|
||||
trigger->CastSpell(target ? target : trigger, spellInfo, triggered, nullptr, nullptr, target ? target->GetGUID() : ObjectGuid::Empty);
|
||||
|
||||
Reference in New Issue
Block a user