Hi,
I have some prefabs that have a number of attached scripts. These require to know the location of a GameObject, and I was using the inspector to select the required GameObject. For example:
var target : GameObject;
When the prefab is placed into the Scene, I can drag and drop the required GameObject onto the script no problem. However I cannot apply the selection to the prefab. Also I can drag the GameObject into the prefab in my resources folder.
Is this normal behaviour as it seems counter intuitive to me?
If it is normal behaviour, am I best to refer to my target GameObject using the find GameObject, etc commands, or is there a more efficient way to do this?
I ask as I dread to think how much typing would have to be done if I changed the name of the target component / gameobject etc.
All words of wisdom welcome!
Thanks
Paul