- Home /
The file MemoryStream is corrupted! Remove it and launch unity again
Hi,
Ive updated Unity from 5.2 to 5.3.1f1 yesterday and was using it with no problem then saved my scene and project and now have just opened the project again and when I went to play it I got the following error ..
The file MemoryStream is corrupted! Remove it and launch unity again
How can I correct this please ?
Thanks.
Ok I find this
Delete the Library and Temp folder .. Great now Unity has to import assets and textures AGAIN! then it's set to Web player so now I have to change to iOS and import the assets and textures AGAIN!! and this is only a little project, I also have a BIG project throwing this error and thats going to be an over night rebuild ..
I read this error showed in Unity 4.X So why has Unity not sorted this by now Unity 5.3.1f1 ??
And in my project I have no references to missing scripts ..
Does no one know a fix to this as it's happened again :(
Answer by TheWarper · Jan 19, 2016 at 07:19 PM
This is the solution - it involves Unity's remote:
Set Editor->UnityRemote->Device->None->Exit Unity (To save this config)->reopen->play Once it plays successfully, you can reset the Unity Remote to the device you were using previously.
@Unity, when can we expect a patch for this?
Thank you I had the same problem and your solution fix it ! thanks!
Thanks! $$anonymous$$uch quicker than removing the Library folder
encountered this for the first time after upgrading from Unity 5.3.1 to 5.3.3 and running w/ an iPhone connected. following TheWarper's suggestion fixed it.
Answer by quankid1412dafsd · Jan 24, 2017 at 11:25 AM
remove folder /ProjectName/Library/metadata then restart unity
Answer by tfunk · May 18, 2016 at 04:31 AM
For me, it turned out that the issue was that I had Android selected under Build Settings, but had an iPhone connected via UnityRemote.
Same for me. After I selected iOS as Platform in the Build Settings, it worked.
Answer by unity_6_EkiNr9Kjm8VQ · Dec 10, 2018 at 07:47 AM
Prefab is broken. Reset it or Use the older one. It will solve the problem.
Answer by MGGDev · Jan 22, 2019 at 09:36 AM
Pinned down the problem to a corrupted prefab instance (thanks @unity_6_EkiNr9Kjm8VQ for the hint!). Here is how I solved it:
If you can't run the editor, delete the project's Library folder first.
Run Unity. It will start in a Sample Scene now. [Optional: Play the scene for a few seconds].
Open your scenes one by one. The one with the problem will crash the editor.
Copy all the files of all the prefabs used in this scene to a safe folder.
Run the editor again, and delete all the prefabs from Unity.
The scene should load now.
Delete all the instances of the prefabs from the scene hierarchy.
Save your scene.
Drag and drop the prefabs again (from the folder you copied them to earlier) into Unity.
Recreate the instances.