Ok, so I got a script attached to a gameObject, lets say the name is objectProperties, then I have another script on the mainCamera called theGUI, which also creates my gui that should fetch the variable in an array from the gameobject tagged with 'selected'. So I got the following:
Now I want it to take the variable from the script objectProperties, attached to the current gameObject with the tag selected, to the script theGUI, attached to the mainCamera. While, I could set the variables from objectProperties, within the GUI, so that's no problem.
asked May 23 '11 at 07:51 PM
You're code variable at objectProperties must be public to be visible from the other script.
answered May 23 '11 at 07:59 PM