Transform.LocalEulerAngle, how to measure speed of rotational body- Unity 3D
You have to know the difference when you switch the languages ! When you start writing to code for your game you either start with the C# or java-script or any other available language. I would like to share a small difference between these two languages syntax when you are required or like to deal with both languages. I like to code in C# but some how have to deal with java-script. Where is found some thing about a scripting API Transform.LocalEulerAngle. First lets see what these API do. Lets discuss some other Api too. Transform.LocalEulerAngle : When you have to rotate something you use this api it rotate an object around an axis. When you write this in Javascript. Then transform.LocalEulerAngle.y= 10f. But you can n't write the same for C#. As it's a vector3 in C#. Whereas Vector3 is a struct, whereas Eulerangle will return a copy. By assigning the value 10 means that you are making a temporary change in the copy. That does not happen. So in C# you can write