Renamed PickRandom to SelectRandom
This commit is contained in:
@@ -1040,7 +1040,7 @@ namespace Scripts.Spells.Druid
|
||||
return;
|
||||
}
|
||||
|
||||
Unit target = tempTargets.PickRandom();
|
||||
Unit target = tempTargets.SelectRandom();
|
||||
targets.Clear();
|
||||
targets.Add(target);
|
||||
}
|
||||
|
||||
@@ -734,7 +734,7 @@ namespace Scripts.Spells.Items
|
||||
|
||||
PreventDefaultAction();
|
||||
Unit caster = eventInfo.GetActor();
|
||||
uint spellId = triggeredSpells[(int)caster.GetClass()].PickRandom();
|
||||
uint spellId = triggeredSpells[(int)caster.GetClass()].SelectRandom();
|
||||
caster.CastSpell(caster, spellId, true);
|
||||
|
||||
if (RandomHelper.randChance(10))
|
||||
@@ -960,7 +960,7 @@ namespace Scripts.Spells.Items
|
||||
if (randomSpells.Empty())
|
||||
return;
|
||||
|
||||
uint spellId = randomSpells.PickRandom();
|
||||
uint spellId = randomSpells.SelectRandom();
|
||||
caster.CastSpell(caster, spellId, true);
|
||||
}
|
||||
|
||||
@@ -1293,7 +1293,7 @@ namespace Scripts.Spells.Items
|
||||
return;
|
||||
}
|
||||
|
||||
caster.CastSpell(caster, possibleSpells.PickRandom(), true);
|
||||
caster.CastSpell(caster, possibleSpells.SelectRandom(), true);
|
||||
}
|
||||
|
||||
public override void Register()
|
||||
@@ -2357,7 +2357,7 @@ namespace Scripts.Spells.Items
|
||||
void HandleTeleport(uint effIndex)
|
||||
{
|
||||
PreventHitDefaultEffect(effIndex);
|
||||
uint spellId = SpellIds.WormholeTargetLocations.PickRandom();
|
||||
uint spellId = SpellIds.WormholeTargetLocations.SelectRandom();
|
||||
GetCaster().CastSpell(GetHitUnit(), spellId, true);
|
||||
}
|
||||
|
||||
|
||||
@@ -94,7 +94,7 @@ namespace Scripts.Spells.Rogue
|
||||
{
|
||||
while (!_targets.Empty())
|
||||
{
|
||||
ObjectGuid guid = _targets.PickRandom();
|
||||
ObjectGuid guid = _targets.SelectRandom();
|
||||
Unit target = Global.ObjAccessor.GetUnit(GetTarget(), guid);
|
||||
if (target)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user