Revision [744]

Last edited on 2010-06-17 23:03:03 by AdminSkyld [Aesthetic change]

No differences.

Revision [737]

Edited on 2010-06-04 09:33:24 by Tolnaftate2004 [small addition]
Additions:
~a) keep track of your joined classes (see ##[[joinedclasses]]## and ##[[isinclass]]##);
~a) allow you to get rid of joined classes (see ##[[leave]]##); and
~a) allow you to call a function in a specific joined class (see ##[[ClassOperator ::]]##).
It is generally considered good practice to always use the scope operator.
==Joins On [[TGraalVar]]s==
Deletions:
a) keep track of your joined classes (see ##[[joinedclasses]]## and ##[[isinclass]]##);
b) allow you to get rid of joined classes (see ##[[leave]]##); and
c) allow you to call a function in a specific joined class (see ##[[ClassOperator ::]]##).
==Joins On ##[[TGraalVar]]##s==


Revision [735]

Edited on 2010-06-03 04:28:56 by WhiteDragon [Added section / changes.]
Additions:
==Joins On ##[[TGraalVar]]##s==
Joins in their basic form are used only on weapons and NPCs to provide access to more functions; however, you can use ##join## on any variable. This means that the functions in the class, instead of being on ##[[this]]##, will be on the variable.
Deletions:
==##[[TGraalVar]]## Joins==
Joins in their basic form are used only on weapons and NPCs to provide access to more functions; however, you can use ##join## on any variable.


Revision [734]

Edited on 2010-06-03 04:26:11 by WhiteDragon [Minor changes & section added.]
Additions:
==Join Types==
A serverside ##join## is run on the server -- so if the join is put in the ##[[onCreated]]## block, it will run when the weapon/npc is created/updated. //If joined serverside, the script can access all serverside functions of that class on the server, and all clientside functions on the client.//
A clientside ##join## is run on the client. There can sometimes be a significant delay between when ##join## is called and when the script has access to the functions in the joined class. //If joined clientside, the script can access the clientside functions of that class on the client.//
**Example**
##example_class##
##Example Weapon##
==##[[TGraalVar]]## Joins==
Joins in their basic form are used only on weapons and NPCs to provide access to more functions; however, you can use ##join## on any variable.
& Warning: Joining on a ##[[player]]## object with clientside functions can sometimes glitch and require client restarts in order to update the class fully.
**Example**
##example_class##
this.something = 5;
##Example Weapon##
temp.myVar = new TStaticVar();
temp.myVar.join("example_class");
temp.myVar.example_function();
echo(temp.myVar.something);
... would ##[[echo]]## "5" on the server RC when the weapon is updated.
CategoryObjectFunction
Deletions:
==Join types==
A serverside join is run on the server -- so if it is put in the ##[[onCreated]]## block, it will run when the weapon/npc is created/updated. //Joining serverside will give access to both serverside and clientside functions.//
A clientside join is run on the client. There can sometimes be a significant delay between when ##join## is called and when the script has access to the functions in the joined class. //Joining clientside will only give access to clientside functions.//
==Example==
**example_class**
**Example Weapon**


Revision [732]

Edited on 2010-06-03 03:41:51 by WhiteDragon [Slight modifications.]
Additions:
Although you can think of ##join## as "copying and pasting" the class into your script, it does more than that. It will
==Join types==
A clientside join is run on the client. There can sometimes be a significant delay between when ##join## is called and when the script has access to the functions in the joined class. //Joining clientside will only give access to clientside functions.//
It is recommended to ##join## serverside because the lag created by a clientside join is often troublesome, as the calling function will keep running and may except certain functions to exist, even though they do not yet (see ##[[isclassloaded]]##).
Deletions:
While you can think ##join## as "copying and pasting" the class into your script, it does more than that. It will
A clientside join is run on the client. There can sometimes be a significant delay between when ##join## is called and when you actually have access to the functions in the joined class. Joining clientside will only give access to clientside functions.
It is recommended to ##join## serverside because the lag created by a clientside join is often troublesome, as the calling function will keep running and may except certain functions to exist, even though they do not yet (see ##isclassloaded##).


Revision [731]

The oldest known version of this page was created on 2010-06-03 03:38:42 by WhiteDragon [Created]
Valid XHTML 1.0 Transitional :: Valid CSS :: Powered by WikkaWiki