Random jail system - 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: Random jail system (
/showthread.php?tid=484351)
Random jail system -
mrxqware - 30.12.2013
Hello Guys and Girls,
I was wondering if there is a jail-system somewhere to send players to random jails where they have to stay without others.
At the moment in my game mode all players are being sent to a single jail where they kill each other for fun. All players get teleported to the same jail.
Re : Random jail system -
[HRD]Mar1 - 30.12.2013
use random spawns.
Re: Random jail system -
Stereotype - 30.12.2013
pawn Код:
new Float:RandomSpawn[][4] =
{
// Positions, (X, Y, Z and Facing Angle)
{-2796.9854, 1224.8180, 20.5429, 192.0335},
{-2454.2170, 503.8759, 30.0790, 267.2932},
{-2669.7322, -6.0874, 6.1328, 89.8853}
};
pawn Код:
new rand = random(sizeof(RandomSpawn));
// SetPlayerPos to the random spawn data
SetPlayerPos(playerid, RandomSpawn[rand][0], RandomSpawn[rand][1],RandomSpawn[rand][2]);
// SetPlayerFacingAngle to the random facing angle data
SetPlayerFacingAngle(playerid, RandomSpawn[rand][3]);