onFileClosing Event

Fires before a fly file is closed to notify that the file is being closed.

SGWorld.attachEvent(“onFileClosing”, myOnFileClosing);

function myOnFileClosing()

Remarks

This event must be handled before performing pre-close operations. For example, it may be desired to save the content of a node (see SGNode.save method) before the terrain is unloaded.