Howto:Exposing Subsystems to Nasal: Difference between revisions

m
Line 147: Line 147:


=== FlightGear ===
=== FlightGear ===
<syntaxhighlight lang="diff">
diff --git a/src/Scripting/NasalSys.cxx b/src/Scripting/NasalSys.cxx
index dcd9965..27eb4c8 100644
--- a/src/Scripting/NasalSys.cxx
+++ b/src/Scripting/NasalSys.cxx
@@ -1307,6 +1307,13 @@ void FGNasalSys::setTimer(naContext c, int argc, naRef* args)
    t->gcKey = gcSave(handler);
    t->nasal = this;
+    SG_LOG(SG_NASAL, SG_ALERT,
+ "Nasal timer registration via settimer():\n"
+ "\tfile: " << naStr_data(naGetSourceFile(c,0)) <<
+ "\tline: " << naGetLine(c,0) << std::endl
+
+    );
+
    globals->get_event_mgr()->addEvent("NasalTimer",
                                        t, &NasalTimer::timerExpired,
                                        delta.num, simtime);
</syntaxhighlight>
=== Base Package ===
=== Base Package ===