Just a simple question , is the pUnit:GetRandomPlayer(0)) command really working? cuz i didnt notice it was working :P I'll +Rep for awser
Just a simple question , is the pUnit:GetRandomPlayer(0)) command really working? cuz i didnt notice it was working :P I'll +Rep for awser
pUnit:GetRandomPlayer()
its actually really working or not?
Not sure, but if that doesn't work, then the command is bugged.
ok ty +Rep x2
Edit: Must spread ; (
There can also be flags in the (), like these:
Code:- GetRandomPlayer(0) = Random Player - GetRandomPlayer(1) = Random in Short-Range - GetRandomPlayer(2) = Random in Mid-Range - GetRandomPlayer(3) = Random in Long-Range - GetRandomPlayer(4) = Random with Mana - GetRandomPlayer(5) = Random with Rage - GetRandomPlayer(6) = Random With Energy - GetRandomPlayer(7) = Random NOT Main-Tank
with your script do this
Code:function blablabla(bla bla) local plr = pUnit:GetRandomPlayer() pUnit:CastSpell(ID, plr)
Last edited by mager1794; 07-10-2008 at 12:04 AM.
Lunar Gaming - Reaching For The Stars
You should use it this way:
On target should be there to make sure the boss knows to find a target based on what you input.Code:function random_lol(pUnit,event) pUnit:CastSpellOnTarget(SPELLID,pUnit:GetRandomPlayer(FLAGS)