| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657 |
- <html>
- <head>
- <title>Blitz3D Docs</title>
- <link rel=stylesheet href=../css/commands.css type=text/css>
- </head>
- <body>
- <h1>MoveMouse x,y</h1>
- <h1>Parameters</h1>
- <table>
- <tr>
- <td>
- x = the x coordinate on the screen to move the mouse
<br />
- y = the y coordinate on the screen to move the mouse
- </td>
- </tr>
- </table>
- <h1>Description</h1>
- <table>
- <tr>
- <td>
- 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.
- </td>
- </tr>
- </table>
- <h1><a href=../2d_examples/MoveMouse.bb>Example</a></h1>
- <table>
- <tr>
- <td>
- Graphics 640,480
<br />
-
<br />
- SetBuffer BackBuffer()
<br />
-
<br />
- Repeat
<br />
- Cls
<br />
-
<br />
- Text 320,0,"Click to reset mouse",True
<br />
-
<br />
- Text 0,0,"Mouse X:"+MouseX()
<br />
- Text 0,10,"Mouse Y:"+MouseY()
<br />
-
<br />
- If MouseDown(1) Or MouseDown(2) Then MoveMouse 320,240
<br />
-
<br />
- Text MouseX(),MouseY(),"X",True,True
<br />
-
<br />
- Flip
<br />
-
<br />
- Until KeyHit(1)
<br />
-
<br />
- End
- </td>
- </tr>
- </table>
- <br>
- <a target=_top href=../index.htm>Index</a><br>
- <br>
- Click <a href=http://www.blitzbasic.co.nz/b3ddocs/command.php?name=MoveMouse&ref=comments target=_blank>here</a> to view the latest version of this page online</body>
- </html>
|