MouseXSpeed() and MouseYSpeed()

BlitzMax Forums/BlitzMax Programming/MouseXSpeed() and MouseYSpeed()

kfprimm(Posted 2005) [#1]
Unlike BlitzPlus, these commands arent built into BlitzMax. How do I find the out the speed of the mouse?


tonyg(Posted 2005) [#2]
Mousexspeed+
movemouse example


Perturbatio(Posted 2005) [#3]
http://www.blitzbasic.com/Community/posts.php?topic=47133

*EDIT*
damn, beat me to it :)


tonyg(Posted 2005) [#4]

*EDIT*
damn, beat me to it :)


If you write 'em, I'll link to 'em. :)


kfprimm(Posted 2005) [#5]
alright, thank you very much.


ImaginaryHuman(Posted 2005) [#6]
The mouse speed is just the position in the current frame minus the position in the previous frame.


FlameDuck(Posted 2005) [#7]
The "problem" with the Perturbatios code is that if moving the mouse really fast, MouseX and MouseY may change values between reads, which might give erratic mouse movements. Instead you chould just add your newly found speed to your "old" accumlation position.


Hotcakes(Posted 2005) [#8]
What's wrong with the MouseXSpeed and MouseYSpeed example in the MouseX/MouseY BRL docs? ;]


Perturbatio(Posted 2005) [#9]
What's wrong with the MouseXSpeed and MouseYSpeed example in the MouseX/MouseY BRL docs? ;]


There isn't one. The only thing I can find is an example under movemouse which locks the mouse to the centre of the screen and determines the offset from there.


Hotcakes(Posted 2005) [#10]
Oh yeh. Wrong command I was thinking of. Still, same thing. =]