|
@@ -99,7 +99,8 @@ Here an example of how to register a function::
|
|
|
{
|
|
{
|
|
|
sq_pushroottable(v);
|
|
sq_pushroottable(v);
|
|
|
sq_pushstring(v,fname,-1);
|
|
sq_pushstring(v,fname,-1);
|
|
|
- sq_newclosure(v,f,0,0); //create a new function
|
|
|
|
|
|
|
+ sq_newclosure(v,f,0); //create a new function
|
|
|
sq_newslot(v,-3,SQFalse);
|
|
sq_newslot(v,-3,SQFalse);
|
|
|
sq_pop(v,1); //pops the root table
|
|
sq_pop(v,1); //pops the root table
|
|
|
|
|
+ return 0;
|
|
|
}
|
|
}
|