09-17-2023, 06:46 PM
Hi Qb64pe community
I'm in trouble with a fine couple of QB64 keywords: _MousemovementX & _MousemovementY
I think that the issue is raising from my bad code or bad knowledge about these two useful keywords...
here the first example taken from the wiki
mousemovementX wiki
mousemovementY wiki
as you can see my adds are:
- the 2 REM lines
- and the _MouseMove PX,PY line of code.
The issue, that I am not able to correct, comes out if you play moving the pointer of mouse some times along the horizonthal and vertical axis of the screen.
Can someone give me a feedback or an enlightment about this?
I'm in trouble with a fine couple of QB64 keywords: _MousemovementX & _MousemovementY
I think that the issue is raising from my bad code or bad knowledge about these two useful keywords...
here the first example taken from the wiki
mousemovementX wiki
mousemovementY wiki
Code: (Select All)
Rem _MOUSEMOVEMENTX / _MOUSEMOVEMENTY STUDY
Rem example 1 from wiki
Screen 12
PX = 320: PY = 240 'center position
_MouseMove PX, PY ' set center of screen, pointer of mouse and center of circle at the same position
Do: _Limit 200
Do While _MouseInput
PX = PX + _MouseMovementX
PY = PY + _MouseMovementY
Loop
Cls
Circle (PX, PY), 10, 10
Locate 1, 1: Print PX, PY
Loop Until InKey$ = Chr$(27) 'escape key exit
- the 2 REM lines
- and the _MouseMove PX,PY line of code.
The issue, that I am not able to correct, comes out if you play moving the pointer of mouse some times along the horizonthal and vertical axis of the screen.
Can someone give me a feedback or an enlightment about this?