mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-22 02:04:52 +01:00
Core/Spells: Added helper function to select random injured healing spell targets
This commit is contained in:
@@ -324,12 +324,7 @@ class spell_sha_downpour : public SpellScript
|
||||
|
||||
void FilterTargets(std::list<WorldObject*>& targets)
|
||||
{
|
||||
uint32 const maxTargets = 6;
|
||||
if (targets.size() > maxTargets)
|
||||
{
|
||||
targets.sort(Trinity::HealthPctOrderPred());
|
||||
targets.resize(maxTargets);
|
||||
}
|
||||
Trinity::SelectRandomInjuredTargets(targets, 6, true);
|
||||
}
|
||||
|
||||
void CountEffectivelyHealedTarget()
|
||||
|
||||
Reference in New Issue
Block a user