fix(Core/Creature): implement SUMMON_PROP_FLAG_USE_SUMMONER_FACTION (#24674)

This commit is contained in:
sogladev
2026-02-10 13:42:43 +01:00
committed by GitHub
parent c73cf6b019
commit a890f55b55
2 changed files with 6 additions and 1 deletions

View File

@@ -245,6 +245,11 @@ void TempSummon::InitStats(uint32 duration)
if (m_Properties->Faction)
SetFaction(m_Properties->Faction);
else if (m_Properties->Flags & SUMMON_PROP_FLAG_USE_SUMMONER_FACTION)
{
if (owner)
SetFaction(owner->GetFaction());
}
else if (IsVehicle() && owner) // properties should be vehicle
SetFaction(owner->GetFaction());
}

View File

@@ -433,7 +433,7 @@ enum SummonPropFlags
SUMMON_PROP_FLAG_JOIN_SUMMONER_SPAWN_GROUP = 0x00000200, /// @todo: NYI 51 spells in 3.0.3, something defensive
SUMMON_PROP_FLAG_DO_NOT_TOGGLE = 0x00000400, /// @todo: NYI 3 spells, requires something near?
SUMMON_PROP_FLAG_DESPAWN_WHEN_EXPIRED = 0x00000800, /// @todo: NYI 30 spells in 3.0.3, no idea
SUMMON_PROP_FLAG_USE_SUMMONER_FACTION = 0x00001000, /// @todo: NYI Lightwell, Jeeves, Gnomish Alarm-o-bot, Build vehicles(wintergrasp)
SUMMON_PROP_FLAG_USE_SUMMONER_FACTION = 0x00001000, /// Lightwell, Jeeves, Gnomish Alarm-o-bot, Build vehicles(wintergrasp)
SUMMON_PROP_FLAG_DO_NOT_FOLLOW_MOUNTED_SUMMONER = 0x00002000, /// @todo: NYI Guides, player follows
SUMMON_PROP_FLAG_SAVE_PET_AUTOCAST = 0x00004000, /// @todo: NYI Force of Nature, Shadowfiend, Feral Spirit, Summon Water Elemental
SUMMON_PROP_FLAG_IGNORE_SUMMONER_PHASE = 0x00008000, /// @todo: NYI Light/Dark Bullet, Soul/Fiery Consumption, Twisted Visage, Twilight Whelp. Phase related?