
-----------------------------------
Raknarg
Fri Jan 20, 2012 4:31 pm

Mouse wheel
-----------------------------------
Is there a way to detect mouse wheel scrolling?

-----------------------------------
Zren
Fri Jan 20, 2012 5:52 pm

RE:Mouse wheel
-----------------------------------
There's nothing in the Mouse module, and the GUI module doesn't use it, so nope.

-----------------------------------
Alex C.
Fri Jan 20, 2012 6:05 pm

RE:Mouse wheel
-----------------------------------
actually, someone who made forces (windsurfer) incorporated the mouse wheel (as well as the right button) into their game.

im not sure how but it's possible (and the source code for forces is out there)

-----------------------------------
Raknarg
Fri Jan 20, 2012 6:51 pm

RE:Mouse wheel
-----------------------------------
Yeah, theres probs a way to do it.. I know for a fact that someone made a module to use a joypad, so it has o be possible

-----------------------------------
Alex C.
Fri Jan 20, 2012 7:42 pm

RE:Mouse wheel
-----------------------------------
also, do you mean scrolling or clicking with the wheel?

-----------------------------------
Raknarg
Fri Jan 20, 2012 7:49 pm

RE:Mouse wheel
-----------------------------------
scrolling, like my first post said

-----------------------------------
Alex C.
Fri Jan 20, 2012 7:49 pm

RE:Mouse wheel
-----------------------------------
by the way, "Retro Shooter" might have mouse scrolling in it's code somewhere...
http://compsci.ca/v3/viewtopic.php?t=21371

-----------------------------------
copthesaint
Sat Jan 21, 2012 10:06 am

Re: Mouse wheel
-----------------------------------
 Mouse.ButtonChoose ("multibutton")
        var x, y, button, left, middle, right : int
        Mouse.Where (x, y, button)
        left := button mod 10           % left = 0 or 1
        middle := (button - left) mod 100   % middle = 0 or 10
        right := button - middle - left     % right = 0 or 100
        if left = 1 then
            put "left button down"
        end if
        if middle = 10 then
            put "middle button down"
        end if
        if right = 100 then
            put "right button down"
        end if


There's nothing in the Mouse module, and the GUI module doesn't use it, so nope.

You know is your heart that you should have searched for it ;)

-----------------------------------
Alex C.
Sat Jan 21, 2012 2:31 pm

RE:Mouse wheel
-----------------------------------
huh, that's actually pretty useful! :D

-----------------------------------
Dreadnought
Sat Jan 21, 2012 2:37 pm

Re: Mouse wheel
-----------------------------------
Well, actually the functionality is bugged. You can't detect more than one button click on the mouse at a time. See scrolling not clicking. Zren is correct Turing does not provide a way of detecting mouse wheel scrolling.
