Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Custom MouseMovement Example
#14
Cool, I thought I was stuck with only 5 rotations (desktop width of 1920 / 360 = 5.3) for my spinning ship, but with MasterGy's multiplier I can get many more rotations before hitting the end points. The mouse is more sensitive, but not by much. Thanks, MasterGy! Why didn't I think of that? EDIT: And then by reducing the mouse sensitivity with the OS this works much better for me...

Code: (Select All)
DO WHILE _MOUSEINPUT '  mouse controls
    IF _MOUSEMOVEMENTX THEN
        cX = cX - _MOUSEMOVEMENTX '
        ship.vector = ship.vector + cX * 1.6 '  << MasterGy concept, mouse movement multiplier
        IF ship.vector >= -1 THEN ship.vector = -1080 ' if vector goes positive avoid lockup
    END IF
    zX = zX + _MOUSEMOVEMENTX '   for the mouse range gauge
LOOP

gaugeVal = INT((zX / DTW) * _WIDTH) + 10 '   relative/corrected x value for mousemovement range
Reply


Messages In This Thread
Custom MouseMovement Example - by SMcNeill - 02-25-2024, 05:37 PM
RE: Custom MouseMovement Example - by NakedApe - 02-26-2024, 01:18 AM
RE: Custom MouseMovement Example - by SMcNeill - 02-26-2024, 03:29 AM
RE: Custom MouseMovement Example - by SMcNeill - 02-26-2024, 03:45 AM
RE: Custom MouseMovement Example - by NakedApe - 02-26-2024, 06:00 AM
RE: Custom MouseMovement Example - by NakedApe - 02-26-2024, 05:35 PM
RE: Custom MouseMovement Example - by SMcNeill - 02-27-2024, 07:15 AM
RE: Custom MouseMovement Example - by GareBear - 02-27-2024, 01:06 PM
RE: Custom MouseMovement Example - by SMcNeill - 02-27-2024, 01:28 PM
RE: Custom MouseMovement Example - by SMcNeill - 02-27-2024, 01:47 PM
RE: Custom MouseMovement Example - by NakedApe - 02-27-2024, 04:59 PM
RE: Custom MouseMovement Example - by SMcNeill - 02-27-2024, 05:06 PM
RE: Custom MouseMovement Example - by MasterGy - 02-27-2024, 05:18 PM
RE: Custom MouseMovement Example - by NakedApe - 02-27-2024, 07:17 PM
RE: Custom MouseMovement Example - by MasterGy - 02-27-2024, 08:53 PM
RE: Custom MouseMovement Example - by SMcNeill - 02-27-2024, 08:58 PM
RE: Custom MouseMovement Example - by MasterGy - 02-27-2024, 09:07 PM
RE: Custom MouseMovement Example - by NakedApe - 02-28-2024, 02:40 AM



Users browsing this thread: 1 Guest(s)