I feel extra typey today :D. Now, in the last Tutorial you learned to use arguments. Now, I will teach you variables.
1. Variables. Variables can used for many things in fact there used a lot! a variable can have many prefixes as well as custom prefixes.
a. A variable specify's something to equal something or set something to true or false. Example
Code:
 self.variable = 12345;
Now, I just gave you a variable and will explain everything later.
1a. True and False. A variable can be used to set something to true or false. Now, you can set it to the actual word true or false. example:
Code:
 self.example = true;
self.example = false;
Another way to set true or false is by using 1 or 0. if a variable is equal to 1 it is true or a(n) actual number set to the variable. If a variable is equal to 0 it is false or a(n) actual number set to the variable. Example:
Code:
 self.example = 1;
self.example = 0;
2a. Prefixes. The prefix is what becomes before the period, self.variable = 1;. The prefix a variable can affect who it is assigned to or when its ran. ( level, player, self ) are all prebuilt prefixes.
2b. Custom Prefixes. the custom prefix can be anything you want it to be as long as you assign it to something. for instance:
Code:
 isHost() = host;
host.example = 1;
Now, we can also assign it to are input if you need it.. Like this
Code:
 self thread Example( self );
Example( inputVar )
{
      inputVar.example = 123;
}
syntax's of variable's are:
1. Prefix
2. Period
3. Name of variable
4. Equal
5. Value
6. Semi-colon to close.
Hope this helped +rep and thank me if you enjoy these.