5.4 GB of RAM used by editor.

So I’m making a 2D game with C# in 64 bit Unity version 5.3 (the same thing happens in 5.4), and Windows task manager is telling me that the editor is using basically all of my free memory (5.4 GB). The editor itself is usable but when I try to test the game it always freezes and crashes everything. Are there any common causes for problems like this?

This only happens with one specific project.

Edit: I’ve also tried to comment out any scripts that I thought might be causing issues; this solves the issue but I don’t know how to fix it. The script contains some large arrays but I’m still surprised that this is enough to fill up all of my memory just by opening the editor.

Hey, I have solved this by writing an small function which calls Resources.UnloadUnusedAssets() and then call it using a ContextMenu or a MenuItem attribute, using that function clears all unused assets from the RAM and may speed up your Editor a little bit

#if UNITY_EDITOR

    [UnityEditor.MenuItem("Assets/Unload Assets")]
   static void UnloadAssets()
    {
        Resources.UnloadUnusedAssets();
    }

#endif

Hope it helps.