1
0
Fork 0

let Nasal's fgcommand() return C++ return value (0 -> failure, 1 -> success)

This commit is contained in:
mfranz 2007-01-13 19:18:03 +00:00
parent 747b1e11cc
commit b1fad7d98e

View file

@ -260,9 +260,7 @@ static naRef f_fgcommand(naContext c, naRef me, int argc, naRef* args)
naRuntimeError(c, "bad arguments to fgcommand()"); naRuntimeError(c, "bad arguments to fgcommand()");
naRef cmd = args[0], props = args[1]; naRef cmd = args[0], props = args[1];
SGPropertyNode_ptr* node = (SGPropertyNode_ptr*)naGhost_ptr(props); SGPropertyNode_ptr* node = (SGPropertyNode_ptr*)naGhost_ptr(props);
globals->get_commands()->execute(naStr_data(cmd), *node); return naNum(globals->get_commands()->execute(naStr_data(cmd), *node));
return naNil();
} }
// settimer(func, dt, simtime) extension function. Falls through to // settimer(func, dt, simtime) extension function. Falls through to