[quake2] CVS: Mouse still a bit bad
Asfand Yar Qazi
email at asfandyar.cjb.net
Mon Sep 27 05:16:34 EDT 2004
Asfand Yar Qazi wrote:
> I'm still playing Q2 using quake2forge 0.3, where glx mouse is fine....
> but in icculus-quake2, its still fudged.
>
> Could someone tell me which file(s) I should look at to compare the
> quake2forge to icculus-quake2 glx mouse code?
>
>
That was easy!
After applying this patch, it seems to work. I'll be a monkey's
auntie if I now why though...
Obviously the '<<4' is equiv to '*2', but the rest of the stuff I
have no clue about.
p.s. I was wondering why the y-axis movement was slower than the
x-axis movement..... '<<2' !
Index: linux/gl_glx.c
===================================================================
RCS file: /cvs/cvsroot/quake2/src/linux/gl_glx.c,v
retrieving revision 1.20
diff -C3 -r1.20 gl_glx.c
*** linux/gl_glx.c 20 Sep 2004 22:55:49 -0000 1.20
--- linux/gl_glx.c 27 Sep 2004 09:10:21 -0000
***************
*** 440,448 ****
if (mouse_active) {
if (dgamouse) {
if (abs(event.xmotion.x_root) > 1)
! mx += (event.xmotion.x_root )<<4;
if (abs(event.xmotion.y_root) > 1)
! my += (event.xmotion.y_root )<<2;
//mwx = event.xmotion.x;
//mwy = event.xmotion.y;
}
--- 440,450 ----
if (mouse_active) {
if (dgamouse) {
if (abs(event.xmotion.x_root) > 1)
! // mx += (event.xmotion.x_root )<<4;
! mx += (event.xmotion.x + win_x) * 2;
if (abs(event.xmotion.y_root) > 1)
! // my += (event.xmotion.y_root )<<2;
! my += (event.xmotion.y + win_y) * 2;
//mwx = event.xmotion.x;
//mwy = event.xmotion.y;
}
More information about the quake2
mailing list