SA-MP Forums Archive
How would i do this? - 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: How would i do this? (/showthread.php?tid=132973)



How would i do this? - Torran - 10.03.2010

How would i do this

If i added at the top of my script

pawn Код:
new Torran;
And then in OnGameModeInit put something like Torran[1]
So like i dont have to use new laods of times,
How would i do this?


Re: How would i do this? - RSC_Quicker - 10.03.2010

new torran[1];
or new torran[9]; if you want to have 10 torrans.
If this is what you mean.


Re: How would i do this? - gotenks918 - 10.03.2010

What are you declaring it for? Do you want to hold a string or an int or what?


Re: How would i do this? - Jakku - 10.03.2010

If you want to eg. add vehicles with that variable, use:

pawn Код:
new Torran[9]; //10 Pieces of Torrans

Torran[1] = AddStaticVehicle(.......);
Torran[2] = AddStaticVehicle(.......);