diff --git a/com.unity.render-pipelines.high-definition/CHANGELOG.md b/com.unity.render-pipelines.high-definition/CHANGELOG.md index dab0e09396a..a61acb8e92f 100644 --- a/com.unity.render-pipelines.high-definition/CHANGELOG.md +++ b/com.unity.render-pipelines.high-definition/CHANGELOG.md @@ -111,6 +111,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. - Fixed preview camera updating the skybox material triggering GI baking (case 1314361/1314373). - The default LookDev volume profile is now copied and referened in the Asset folder instead of the package folder. - Fixed SSS on console platforms. +- Assets going through the migration system are now dirtied. ### Changed - Changed Window/Render Pipeline/HD Render Pipeline Wizard to Window/Rendering/HDRP Wizard diff --git a/com.unity.render-pipelines.high-definition/Runtime/Core/Migration/MigrationDescription.cs b/com.unity.render-pipelines.high-definition/Runtime/Core/Migration/MigrationDescription.cs index 5502236453f..7cb54df3647 100644 --- a/com.unity.render-pipelines.high-definition/Runtime/Core/Migration/MigrationDescription.cs +++ b/com.unity.render-pipelines.high-definition/Runtime/Core/Migration/MigrationDescription.cs @@ -104,10 +104,16 @@ public bool Migrate(TTarget target) } #if UNITY_EDITOR - // Special in prefab case - if (target is UnityEngine.Object && UnityEditor.PrefabUtility.IsPartOfNonAssetPrefabInstance(target as UnityEngine.Object)) + UnityEngine.Object targetObject = target as UnityEngine.Object; + if (targetObject != null) { - UnityEditor.PrefabUtility.RecordPrefabInstancePropertyModifications(target as UnityEngine.Object); + // Special in prefab case + if (UnityEditor.PrefabUtility.IsPartOfNonAssetPrefabInstance(targetObject)) + { + UnityEditor.PrefabUtility.RecordPrefabInstancePropertyModifications(targetObject); + } + + UnityEditor.EditorUtility.SetDirty(targetObject); } #endif return true;