a simple Palette Builder
#5
(02-02-2023, 11:11 AM)bplus Wrote:
Quote:
Code: (Select All)
'mouse sub from wiki with added check for mouse(2)
Sub Mouser (x, y, b)
    mi = _MouseInput
    b = _MouseButton(1)
    If _MouseButton(2) = -1 Then b = -2
    x = _MouseX
    y = _MouseY
End Sub

I am curious where in wiki this is? Might need to be fixed.

Your Mouser routine seems to work only because it's being used in a loop with _Limit 500

If you try that routine in a _Limit 60 or less loop you will want to change Mouser to:
Code: (Select All)
Sub Mouser (x, y, b)
    While _MouseInput: Wend
    b = _MouseButton(1)
    If _MouseButton(2) = -1 Then b = -2
    x = _MouseX
    y = _MouseY
End Sub


Example 4 under _mousebutton on the wiki has this subroutine:  
Code: (Select All)
SUB Mouser (x, y, b)
mi = _MOUSEINPUT
b = _MOUSEBUTTON(1)
x = _MOUSEX
y = _MOUSEY
END SUB
Reply


Messages In This Thread
a simple Palette Builder - by James D Jarvis - 02-01-2023, 04:42 PM
RE: a simple Palette Builder - by James D Jarvis - 02-02-2023, 01:50 AM
RE: a simple Palette Builder - by bplus - 02-02-2023, 11:11 AM
RE: a simple Palette Builder - by James D Jarvis - 02-02-2023, 02:09 PM
RE: a simple Palette Builder - by SMcNeill - 02-02-2023, 12:21 PM
RE: a simple Palette Builder - by James D Jarvis - 02-02-2023, 02:26 PM
RE: a simple Palette Builder - by James D Jarvis - 02-02-2023, 02:17 PM
RE: a simple Palette Builder - by mnrvovrfc - 02-02-2023, 06:21 PM



Users browsing this thread: 2 Guest(s)