vrchat-community / UdonSharp

A compiler for compiling C# to Udon assembly
https://udonsharp.docs.vrchat.com
MIT License
463 stars 50 forks source link

Migration of prefab with UdonSharp 0.20.3 project to 1.x is broken #58

Closed anatawa12 closed 1 year ago

anatawa12 commented 1 year ago

Describe the bug in detail:

Migrating prefab made with UdonSharp 0.20.3 to 1.x is broken in some case. In similar case, prefab with UdonGraph will not be broken so I think this is bug of UdonSharp.

Provide steps/code to reproduce the bug:

  1. create/open project with UdonSharp 1.x.
  2. import UdonSharpTest.unitypackage in UdonSharpTest.unitypackage.zip

Expected behavior:

In 1.OuterObject/2.InnerObject of UdonSharpTest/1.OuterObject.prefab, the value of Test Color is black (as if we imported to project with old SDK).

Actual behavior:

In 1.OuterObject/2.InnerObject of UdonSharpTest/1.OuterObject.prefab, the value of Test Color is white, the color specified in 2.InnerObject.prefab.

Additional Information:

In 3.InnerObject.prefab, Test Color is black, as we imported to old SDK.

MerlinVR commented 1 year ago

Nested prefabs and prefab variants do not have an automatic upgrade path and will need to be fixed manually if they break. This is because having support for upgrading them would complicate the upgrade process significantly which could cause the supported cases to break and they weren't supported prior to 1.0.