Randomize a Variable - 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)
+--- Thread: Randomize a Variable (
/showthread.php?tid=544533)
Randomize a Variable -
gurmani11 - 02.11.2014
Delete
Re: Randomize a Variable -
Sawalha - 02.11.2014
yes, example:
pawn Код:
new var[5];
new ran = random(5);
if(var[ran] == 1) return // etc....
or , you can do instead of
Do
Delete -
gurmani11 - 02.11.2014
Delete
Re: Randomize a Variable -
Dignity - 02.11.2014
pawn Код:
switch(variable)
{
case 1:
{
// code here
}
case 2:
{
// code here
}
}
Delete -
gurmani11 - 03.11.2014
Delete