Quantcast
Channel: Questions in topic: "invert y"
Viewing all articles
Browse latest Browse all 14

How to Invert my Camera Controls

$
0
0
Currently I am using the following script to be able to rotate an object around as if it were being displayed (like a portfolio piece in real-time). My problem is that up goes down, and down goes up, when my mouse gives input on the Y axis. I realize this is probably a super simple fix. I've looked around and cannot figure this out. Thanks for your help! var speed : float = 100.0; function Update(){ if (Input.GetMouseButton(0)) { transform.Rotate(Vector3(Input.GetAxis("Mouse Y"), Input.GetAxis("Mouse X"), 0) * Time.deltaTime * speed); } }

Viewing all articles
Browse latest Browse all 14

Latest Images

Trending Articles





Latest Images