- Home /
Inspector And Variable Inconvenience?
Hello everyone, I like to have an idea about the problem that I've faced. Actually it is not a huge problem but still I think that needs to be added into editor features. (Unless there is something that I don't know, thats why I'm asking) Now I have a lot of interactable objects on my scene, and they all have the same interaction script. This script has a value, and it's a type of a class called _InventoryCanvas. I have only one Inventory Canvas object on my scene, which has _InventoryCanvas script attached. Now, when I changed the folder of the _InventoryCanvas script, and pressed play, I got thrown lots of errors from those interaction objects. Since the place of the _InteractionCanvas script has changed, it has gone missing over the Interaction Canvas object, so all Interaction scripts had _InventoryCanvas variable as null. Considering the fact that I have like 100 interactables on the scene, it was a huge waste of time to drag & drop _InteractionCanvas variable all over again to Interaction scripts. Is there any easy way to make the scripts recognize a variable which has changed it's directory? Thanks :)