Re: [AD] mouse mickeys problem

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


On Sun, 2004-04-11 at 16:17, Evert Glebbeek wrote:
> On Sunday 11 April 2004 16:05, Elias Pschernig wrote:
> > Use position_mouse to set the mouse to the middle of the screen
> > continuously. That way, you can even use mouse_x, mouse_y to get
> > mickeys. Of course, you need to track the cursor position and draw it
> > yourself in that case. And it works better in fullscreen than in
> > windowed mode.
> 
> Note that doing this doesn't work if you try to run the program through 
> Wine (useful if you're in Linux and people insist on releasing only 
> Windows binaries): the mouse cursor stays fixed very close to the screen 
> centre and you can't use the mouse at all.
> So I would generally recommend against this. It's basically a dirty hack 
> that may cause other problems later on.
> 

Another idea would be to use set_mouse_range, to a one-pixel range in
the middle of the screen. Then use get_mouse_mickeys. Or, a mouse range
excluding a few border pixels, so mouse_mickeys maybe will keep working?

I have no idea how good that works in wine.. but it would be better to
send a bug report to wine than work around this in programs (But I get
neither keyboard nor mouse input at all in wine for example.. so don't
know much about it).

Of course, a solution inside Allegro would be best for this, and even
better if it also works in wine :)

-- 
Elias Pschernig <elias@xxxxxxxxxx>





Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/