random mumber help - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: random mumber help (
/showthread.php?tid=223323)
random mumber help -
YungGee - 09.02.2011
Код:
new Rand;
Rand = random(100);
I want this to be random 10-100 not random 0-100 can someone show me i cant find a good wiki link on it:S
plz help
Re: random mumber help -
Retardedwolf - 09.02.2011
rand = random( 90 ) + 10;
Re: random mumber help -
YungGee - 09.02.2011
That dont look right can u like explain it
EDIT: i want it to pick a number from 10 to 100..
Re: random mumber help -
iggy1 - 09.02.2011
I think there might be a function for this in usefull functions topic. I wrote a crude way to do it but there are probably much better ways to do it.
pawn Код:
new
rand = random(90) + 1;
if(rand < 10) rand += 10;