Error Syntax Code
position = rotation * Vector3(0, 0, -distance) + target.position;
Error Word
BCE0051:Operation’*’ cannot be use with left hand side of type ‘Object’ and right hand side of type UnityEngine.Vector3
I just buy unity3D Basic iOS Basic. it return this error. Before I used unity Pro iOS pro.It’s no error.
Is it litmit of unity Basic iOS basic ?
rotation = Quaternion.Euler(y, x, 0);
I think you need to declare the rotation as a quaternion when you create the variable.
i.e.
var rotation: Quaternion;
not just
var rotation;
Thanks
It’s work.Before I used 3.3 it’s not error.
Yes but before Unity 3.4 the compiler also had a few more bugs than now
the new handling saves you from many errors later on that are hard if not impossible to debug (especially if you use unityscript and not C#)
Post the full code.
rotation = Quaternion.Euler(y, x, 0); should actually be: rotation = Vector3(y, x, 0);
And then you apply like so: obj.transform.rotation = Quaternion.Euler(rotation);