Mouse Wheel

Posted By: Lawrence

Mouse Wheel - 11/17/08 19:20

Hi,

I am wondering if there is a way to program the mouse wheel to use for forward and backward motion? I want motion only when you are rolling the wheel. I can't find it in the templates or searching the forums.

Thanks,

Lawrence
Posted By: Uhrwerk

Re: Mouse Wheel - 11/17/08 19:44

You can use mickey.z for that.
Posted By: Lawrence

Re: Mouse Wheel - 11/17/08 21:02

I am sorry. I am not sure what mickey.z is?
Posted By: Uhrwerk

Re: Mouse Wheel - 11/17/08 21:15

Why don't you ask the mighty manual?

http://www.conitec.net/beta/amickey.htm
Posted By: heinekenbottle

Re: Mouse Wheel - 11/18/08 03:16

Well, you should read the manual, but with that said, I just wanted to post an example of code:

Code:

		camera.z += (0.5 * mickey.z);	//allow the camera to zoom in on middle mouse
			if(camera.z < 1500) camera.z = 1500;	//don't exceed bounds
			if(camera.z > 4000) camera.z = 4000;	//don't exceed bounds
		wait(1);												//avoid endless loops



It works like mouse_force and key_force.
© 2024 lite-C Forums