Core/Spells: Implemented SummonPropertiesFlags: UseSummonerFaction & IgnoreSummonerPhase (#27273)

This commit is contained in:
Meji
2021-11-16 11:51:05 +01:00
committed by GitHub
parent 9451f80583
commit a832435b97
7 changed files with 66 additions and 52 deletions
+2 -3
View File
@@ -1703,7 +1703,7 @@ TempSummon* Map::SummonCreature(uint32 entry, Position const& pos, SummonPropert
mask = UNIT_MASK_MINION;
break;
default:
if (properties->Flags & 512) // Mirror Image, Summon Gargoyle
if (properties->GetFlags().HasFlag(SummonPropertiesFlags::JoinSummonerSpawnGroup))
mask = UNIT_MASK_GUARDIAN;
break;
}
@@ -1740,8 +1740,7 @@ TempSummon* Map::SummonCreature(uint32 entry, Position const& pos, SummonPropert
return nullptr;
}
// Set the summon to the summoner's phase
if (summoner)
if (summoner && !(properties && properties->GetFlags().HasFlag(SummonPropertiesFlags::IgnoreSummonerPhase)))
PhasingHandler::InheritPhaseShift(summon, summoner);
summon->SetCreatedBySpell(spellId);