O'Reilly logo

Unity 3D Game Development by Example by Ryan Henson Creighton

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Pick a word (almost) any word

We're going to put the Language Reference through some serious stress testing here. We're going to arm ourselves with every synonym for "mouse" we can think of. Here's a list that I painstakingly brainstormed: mouse, screen position, cursor, pointer, input device, small rodent, two-button, aim, point. One of those has to do the trick. And, if we come up empty-handed, we're going to hit those online tutorials hard until we find our answer.

Go ahead, fire up the Unity Language Reference and type mouse into the Search field. Scour the resulting list. We will not back down. We will not take "no" for an… oh, hello, what's this?

Midway down the list, there's this entry:

Input.mousePosition

The current mouse position in ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required