20,741
edits
m (replace old CVS withs, and link to gitorious now) |
|||
Line 19: | Line 19: | ||
All Nasal related articles can be found in the [http://wiki.flightgear.org/index.php/Category:Nasal Nasal category]. | All Nasal related articles can be found in the [http://wiki.flightgear.org/index.php/Category:Nasal Nasal category]. | ||
'''Note:''' FlightGear's version of the Nasal interpreter is maintained in the [http://www.simgear.org SimGear] | '''Note:''' FlightGear's version of the Nasal interpreter is maintained in the [http://www.simgear.org SimGear] git repository, inside the [gitorious.org/fg/simgear/trees/next/simgear/nasal] folder, the most important header file detailing the internal Nasal API is "[http://simgear.org/doxygen/nasal_8h-source.html nasal.h]", you will want to check this out for the latest changes and information. | ||
You will probably also want to check out the [ | You will probably also want to check out the [gitorious.org/fg/simgear/trees/next/simgear/nasal] folder for specific examples on using the various Nasal APIs that are not yet covered here completely. | ||
'''Important:''' As of 05/2009, this article is work in progress, and none of the examples have so far been tested/compiled. | '''Important:''' As of 05/2009, this article is work in progress, and none of the examples have so far been tested/compiled. | ||
Line 27: | Line 27: | ||
= Intro = | = Intro = | ||
In FlightGear, the simplest way to add new extension functions is to look at the existing functions in [http:// | In FlightGear, the simplest way to add new extension functions is to look at the existing functions in [http://gitorious.org/fg/flightgear/blobs/next/src/Scripting/NasalSys.cxx $FG_SRC/Scripting]/NasalSys.cxx (src/Scripting/NasalSys.cxx). | ||
There is a static table of function pointers (named funcs[]) referencing extension functions, along with their corresponding names in Nasal. | There is a static table of function pointers (named funcs[]) referencing extension functions, along with their corresponding names in Nasal. |