SA-MP Forums Archive
RCON Command - 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: RCON Command (/showthread.php?tid=526769)



RCON Command - babecka - 19.07.2014

I'm using a map loading system in which I load the maps by a RCON command, because the maps are filterscripts. I use the SendRconCommand in my script, however, I'd like the map to be in random order. Is it possible to random the loading of the maps?


Re: RCON Command - xVIP3Rx - 19.07.2014

yes, using random
pawn Код:
new rndm = random(2);

switch(rndm)
{
    case 0: //load map
    case 1: //load map 2
}
Or, if you have a stock or something similar
pawn Код:
new rndm = random(2);

LoadMap(rndm);



Re: RCON Command - babecka - 19.07.2014

Thank you, I'll try to do that.