Playing nice with Unity, and cleanup