Search Unity

Edit Mode, unable to reference the prefab under edit's game object outside the prefab

Discussion in 'Prefabs' started by greyhoundgames, Apr 25, 2019.

  1. greyhoundgames

    greyhoundgames

    Joined:
    Jan 24, 2014
    Posts:
    32
    I have a prefab with some script helper tools on it. The prefab has a reference to a scriptable object in the project. I am doing scriptable.someGameObject = gameObject;
    So I am trying to link the scriptable object to the prefab that is being edited. It links it, however as soon as I leave prefab edit mode the value reverts back to none.