Fix error and warning on freelookcamera.js's OnScriptDestroyed when script run in headless mode.