Game Development Community

Chapter 4 - problem with mouse

by Chris · in Torque Game Engine · 06/08/2006 (12:26 pm) · 2 replies

Everything is working for me in emaga4 except mouse interaction. When I run tge, I can't use the mouse to turn the character, nor can I look around in free camera mode.

I'm using an optical mouse, if that makes a difference.

The code binds mouse, xaxis (or yaxis) to a command.

I noticed that in the fps template, it uses mouse0 instead of mouse, and uses "xaxis" (with quotes) instead of simply xaxis.

Any help? Thanks!

#1
06/08/2006 (1:13 pm)
Delete the .DSO's - Confirm mouse binds are correct
#2
06/08/2006 (5:51 pm)
Thanks, Surge.

I found the problem.

I had typed myPitch instead of mvPitch (y instead of v), and didn't catch the error because the v and y look really similar. Same with mvYaw.

I spent a lot of time staring at the binds, and the problem was elsewhere (in the functions) all along.

Also (if anyone's curious), I tried switching mouse and mouse0 in the keymap binds, and "xaxis" instead of xaxis, and it seems to work either way.