How to make Arrays (Sorry if wrong)
Well, now I want to show you how to make Arrays, even.. I am not sure if thats what we like to call them.
___________
Here we go.
First of all, we need to choose what it's gone be.
I will choose weapons for now. ( cuse most used and easy too )
First we start our line with:
Okey, that is the first line in our thread.
Then we gone add "sub arrays" that we will add our things to.
List:
Whats in read is just so you see what the difference here and the "main array" is.
then we make a long list of weps. ( or short )
Now I have a list of 6 Arrays. (Yes the 0 counts as 1 too)
Now we want to add it to a function/task.
Then I make a Press action thread to just see that this works:
As you see, I have marked more text.
The for(i=0; i<=5; i++) this will do so that the list will go up so we get our list to work as we want it to.
So when i = 0; menas that it will be Array 0.
And the i<=5; means that it will stop when it reach 5. (In this case it doesn't really mater that much but. We mostly like avoid lagg)
And the i++ means that we increase i that's 0 with 1 every time we press N.
Now I hope you learned how to make the Arrays.
You can also use this for threads and so on. (maps, models, visions, and more)
___________
Here we go.
First of all, we need to choose what it's gone be.
I will choose weapons for now. ( cuse most used and easy too )
First we start our line with:
self.wep = []
Then we gone add "sub arrays" that we will add our things to.
List:
self.wep[0] = "ak47_mp";
then we make a long list of weps. ( or short )
self.wep[0] = "ak47_mp";
self.wep[1] = "ump45_mp";
self.wep[2] = "usp_mp";
self.wep[3] = "tavor_mp";
self.wep[4] = "tmp_mp";
self.wep[5] = "rpg_mp";
self.wep[1] = "ump45_mp";
self.wep[2] = "usp_mp";
self.wep[3] = "tavor_mp";
self.wep[4] = "tmp_mp";
self.wep[5] = "rpg_mp";
Now we want to add it to a function/task.
Then I make a Press action thread to just see that this works:
weproll()
{
self endon("death");
self endon("disconnect");
for(i=0; i<=5; i++)
{
self notifyOnPlayerCommand("N", "+actionslot 1");
self waittill("N");
self giveweapon(self.wep[i]);
self switchtoweapon(self.wep[i]);
}
}
{
self endon("death");
self endon("disconnect");
for(i=0; i<=5; i++)
{
self notifyOnPlayerCommand("N", "+actionslot 1");
self waittill("N");
self giveweapon(self.wep[i]);
self switchtoweapon(self.wep[i]);
}
}
The for(i=0; i<=5; i++) this will do so that the list will go up so we get our list to work as we want it to.
So when i = 0; menas that it will be Array 0.
And the i<=5; means that it will stop when it reach 5. (In this case it doesn't really mater that much but. We mostly like avoid lagg)
And the i++ means that we increase i that's 0 with 1 every time we press N.
Now I hope you learned how to make the Arrays.
You can also use this for threads and so on. (maps, models, visions, and more)


