Random playerid
#1

Title says it all, I have been trying a few different methodes by making a normale stock to get a Random playerid, but it seems alot more complicated than it actually looks like.

pawn Код:
new rPlayerid = random(10);
This code choses a random number from 0 to 10.

But what I want is to get a random number from the connected players, heres an example:
List of 4 connected players.
Код:
0. Debby
2. Mike
3. Kyle
5. Jack
And my question is: How would it be possible to get a random number from 0, 2, 3 or 5?
Reply


Messages In This Thread
Random playerid - by Improvement™ - 11.09.2011, 18:34
Re: Random playerid - by Sasino97 - 11.09.2011, 18:36
Re: Random playerid - by Babul - 11.09.2011, 19:34
Re: Random playerid - by =WoR=Varth - 11.09.2011, 19:36
Re: Random playerid - by admantis - 11.09.2011, 23:22
Re: Random playerid - by [M]onsieur - 11.09.2011, 23:24
Re: Random playerid - by [L3th4l] - 11.09.2011, 23:35
Re: Random playerid - by [M]onsieur - 11.09.2011, 23:51
Re: Random playerid - by admantis - 12.09.2011, 00:44

Forum Jump:


Users browsing this thread: 1 Guest(s)