Search Unity

(Case 1086978) Cannot remove object from Prefab

Discussion in 'Prefabs' started by Peter77, Oct 2, 2018.

  1. Peter77

    Peter77

    QA Jesus

    Joined:
    Jun 12, 2013
    Posts:
    6,618
    I was copying over an existing prefab from another project to prepare a bug-report for a different issue, when I ran into this one. The prefab that I copied into the provided project has various missing scripts, because I didn't copy them. Unfortunately, I'm unable to modify the prefab, because if I remove objects, it displays the following error message:

    ... leaving the prefab edit mode does not save the changes.


    Reproduce
    • Open user provided project
    • Select Assets/Prefabs/Prop_FloorLamp
    • Click "Open Prefab" in Inspector
    • Right-click the "Billboard" GameObject and choose "Delete"
    Actual
    Observe the editor outputs an error message continuously.

    Expected
    The object gets removed without error messages and those changes are saved.

    Side Note
    It would be very useful if the error message contains the name of the affected gameobject.
     
    Last edited: Oct 2, 2018
  2. CloudyVR

    CloudyVR

    Joined:
    Mar 26, 2017
    Posts:
    715
    In the past Unity was able to simply ignore missing scripts. But now there is an absurd requirement that "missing" scripts be eradicated completely from all prefabs.

    But I really would like to keep my "missing" scripts references around because I use them in different editors where the supporting libraries exist.

    I think Unity is changing things without considering any of the the impact on the flexibility or utility of their software.

    If they had just kept the behavior to simple ignore "missing" scripts would have saved me and others countless man hours. Instead Unity now screams fusses and throws temper tantrums like a child arguing about how it won't save a single prefab or build any assetbundles unless every single last stupid "missing" script is gone!!

    What were you thinking Unity???