I've yesterday added two debug messages for Nasal listeners. They are printed in --log-level={debug,bulk}. The first message is output by the setlistener() wrapper in globals.nas. Example:
setting listener #16 in /whatever/Nasal/dynamic_view.nas, line 414 People are therefore requested *not* to use the raw _setlistener() function, except in files in $FG_ROOT/Nasal/ when they are needed immediately. Only then the raw function is required, as it doesn't rely on props.nas. The second message reports listener calls by their listener id. (This is the integer number that a setlistener() call returns.) Example: trigger listener #16 To filter out the relevant messages, use a command line like $ fgfs --log-level=debug 2|grep listener What is it good for? Using listeners on properties that change one or more times per frame doesn't make sense. Listeners are only efficient when the property is only occasionally written to. Otherwise a simple loop is preferable. By checking the listener call messages one can see if there are listeners triggered in every frame. m. ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel