Originally Posted By: preacherX
In Unity you can only read the single vectors like " if(Go.transform.position.x > 10)" but you cannot write the single vector like "Go.transform.position.x = 10.0f;" !

You would have to use something like this: "Go.transform.position = new Vector3(10.0f,Go.transform.position.y,Go.transform.position.z)"


Yes, because Go.transform.position.x is just a float attribute and not a vector. So you need to call the constructor to create a complete Vector3 instance.

The game object in Unity obviously uses a component pattern to decouple code. This adds a lot of flexibility but makes the code more complex which makes it harder to understand for beginners. But the larger your projects gets the more you will benefit from such patterns because if your requirements change late in development you will spend a lot less time to modify your code.