|
get_mouse_mickeys(...) |
adamk kromm
Member #5,432
January 2005
|
what is the difference between int xoff, yoff; get_mouse_mickeys(&xoff, &yoff); and i ask cause the second way works how i want/expect but the mouse mickeys dont work how i want/expect. ---------- |
gnolam
Member #2,030
March 2002
|
Try putting a position_mouse(SCREEN_W/2, SCREEN_H/2) in there and you'll see a big difference. Or try moving the mouse past edge of the screen. Quote: i ask cause the second way works how i want/expect but the mouse mickeys dont work how i want/expect And how do you expect them to work? And for God's sake, use some capitalization. The shift key on your keyboard isn't just decorative. -- |
adamk kromm
Member #5,432
January 2005
|
I'm using it to rotate a camera in a OpenGL program. The second way the camera rotates fine, but the first way, the camera will move a few degrees then go back to where it started. EDIT:: nvm I found the error was in another part of my code. And that the two above work the same. ---------- |
Evert
Member #794
November 2000
|
They don't work the same cross platform. Not all platforms allow mose events once the mouse leaves the window (or hits the edge of the screen) - in which case mouse_x/y will no longer be updated but get_mouse_mickeys() will do something clever to fake continuous mouse movement. |
kazzmir
Member #1,786
December 2001
|
I cant seem to keep the mouse inside the screen on osx. Regardless of where I put position_mouse(320,240)( before or after get_mouse_mickeys ), the x,y output from get_mouse_mickeys is always 0. Any ideas? Allegro 4.2.1. |
|