Hello guys
I'm just practising with unity and creating very easy scripts. I have created a Camera.. named MyCamera. So I want to move it.. once I clicked a button in my GUI. So I created... my js script... declared my button in my OnGUI function. now: in the OnGUI I declared:
theCamera = GetComponent("MyCamera");
and to change it I thought to use:
theCamera.transform.Translate(Vector3(0,10,0)); but... Unity returns me a message that It's not possible to access an object in this way...so... any suggestion? :)
Many thanks. Giancarlo