Cannot save any scenes in project

Hey all,

I have a very strange issue with my current Unity Project, whereby I can no longer save any scenes, even new ones.

Any attempt to save a scene results in the following error:

NullReferenceException: Object reference not set to an instance of an object

at UnityEditor.AssetModificationProcessorInternal.CheckArguments (System.Object[ ] args, System.Reflection.MethodInfo method) [0x00000] in :0

at UnityEditor.AssetModificationProcessorInternal.OnWillSaveAssets (System.String[ ] assets, System.String[ ]& assetsThatShouldBeSaved, System.String[ ]& assetsThatShouldBeReverted, Int32 explicitlySaveScene) [0x00000] in :0

(Filename: Line: -1)

If I create a new Unity project, I can then save a scene so it appears my project is corrupted.

I have tried rolling back using revision control and the same error occurs.
I have also restored from a good backup from 16th December and again I’m getting the same errors.

I have logged a bug report however if anyone has any ideas I would really appreciate any assistance in getting this resolved as I can no longer make any changes to my scenes in this project.

EDIT - RESOLVED - I have managed to track down the issue, it was being caused by an Editor Asset called “Prefab Evolution”. I have removed this from my project and saving is now working OK.

Thanks,
Andrew

Please follow-up to your bug report to let the QA team know you’ve worked this out.

Thanks Graham, I’ve told the QA team to close out the bug report. Cheers.

Hello,

Same issue here. When saving any scene (Unity 4.6.1f1), I get the following message.

NullReferenceException: Object reference not set to an instance of an object
at UnityEditor.AssetModificationProcessorInternal.CheckArguments (System.Object[ ] args, System.Reflection.MethodInfo method) [0x00000] in :0
at UnityEditor.AssetModificationProcessorInternal.OnWillSaveAssets (System.String[ ] assets, System.String[ ]& assetsThatShouldBeSaved, System.String[ ]& assetsThatShouldBeReverted, Int32 explicitlySaveScene) [0x00000] in :0

I’m not using “Prefab Evolution” in the project.
Thanks,

Paul.

Hi Paul,

Do a grep for any files for the string OnWillSaveAssets in your project and you will be able to identify any other Assets that might need an upgrade.

Prefab Evolution, uSequencer and uTomate all need to be upgraded in my project. uSequencer actually needed to be deleted and then reinstalled.

Cheers,
Andrew

Hi radimoto,

Thanks for the advice.

The latest Unity patch (4.6.1p2) has fixed the issue for me.

Cheers,
Paul.

Nice one, yes the release notes show the following fix:

  • (655225) - Asset Import: Restored previous behaviour of AssetModificationProcessor.OnWillSaveAssets to ignore null or void return values

Prefab Evolution got updated and the issue is fixed on my computer.