2,561
edits
m (→Intro) |
|||
Line 72: | Line 72: | ||
So, this is basically the boilerplate that you'll need to use in order to expose a new function (i.e. you can just copy & paste this into the NasalSys.cxx file). | So, this is basically the boilerplate that you'll need to use in order to expose a new function (i.e. you can just copy & paste this into the NasalSys.cxx file). | ||
If you don't have anything else to return, you can just return naNil(), so that | If you don't have anything else to return, you can just return naNil(), so that a function named "f_cool" looks like this: | ||
static naRef f_cool (naContext c, naRef me, int argc, naRef* args) | static naRef f_cool (naContext c, naRef me, int argc, naRef* args) | ||
{ | { | ||
SG_LOG(SG_GENERAL, SG_ALERT, "Nasal:cool() got executed!"); | |||
return naNil(); | return naNil(); | ||
} | } |
edits