x = the x coordinate on the screen to move the mouse y = the y coordinate on the screen to move the mouse |
Although the mouse isn't visible on the screen, the mouse location is still being tracked and you can attach a graphic to it. However, there are times when you want to put the pointer to a specific location on the screen. Use this command to move the mouse to a designated location. |
Graphics 640,480 dxSetBuffer dxBackBuffer() Repeat dxCls dxText 320,0,"Click to reset mouse",True dxText 0,0,"Mouse X:"+dxMouseX() dxText 0,10,"Mouse Y:"+dxMouseY() If dxMouseDown(1) Or dxMouseDown(2) Then dxMoveMouse 320,240 dxText dxMouseX(),dxMouseY(),"X",True,True dxFlip Until dxKeyHit(1) End |