Core Function Require
From Sputnik Wiki
(Difference between revisions)
UberFoX (Talk | contribs)
(Created page with "<pre> Require( <file>, <flag> ) </pre> === Description === Add all functions etc from a file for use but does not execute any expressions. ==== file ==== The file to include....")
Newer edit →
(Created page with "<pre> Require( <file>, <flag> ) </pre> === Description === Add all functions etc from a file for use but does not execute any expressions. ==== file ==== The file to include....")
Newer edit →
Revision as of 06:01, 28 November 2011
Require( <file>, <flag> )
Contents |
Description
Add all functions etc from a file for use but does not execute any expressions.
file
The file to include.
flag
Optional;
- 0 = Allow this file to be included again
- 1 = Do not include this file again
Return Value
None.
Remarks
This function will NOT execute all statements it can when it includes a file so its good for including a file of Constant variables and what not.
Example
Require("Vec3.spk"); // Include it always Require("Vec3.spk", 1); // Include it only once