musee
Joined: 28 Aug 2008 Posts: 1
Digg It |
Posted: Thu Aug 28, 2008 5:53 am Post subject: Racedriver GRID Wii Wheel Script [1.0] |
|
|
Collating other scripts and adding some of my own scripting; I've made a GlovePIE script enabling you to use the Wii Wheel as you would in Mario Kart Wii in the popular racing game; GRID.
It might not work perfectly; but do try it.
//Wii Wheel GRID controls by Mus.
// Show wiimote forces
debug = "X="+Wiimote.RawForceX+' Y='+Wiimote.RawForceY+' Z='+Wiimote.RawForceZ
//LEDs setup
While Wiimote.RawForceZ < -10 and > -20
Keyboard.Left = 0
Keyboard.Right = 0
endif
While Wiimote.RawForceZ < -10 and > -20
Wiimote.Led1 = 0
Wiimote.Led2 = 0
Wiimote.Led3 = 0
Wiimote.Led4 = 0
endif
While Wiimote.RawForceZ > -10 and < -5
Wiimote.Led1 = 1
Wiimote.Led2 = 0
Wiimote.Led3 = 0
Wiimote.Led4 = 0
wait 500 ms
endif
While Wiimote.RawForceZ > -5 and < 0
Wiimote.Led1 = 1
Wiimote.Led2 = 1
Wiimote.Led3 = 0
Wiimote.Led4 = 0
wait 500 ms
endif
While Wiimote.RawForceZ > 0 and < 5
Wiimote.Led1 = 1
Wiimote.Led2 = 1
Wiimote.Led3 = 1
Wiimote.Led4 = 0
wait 500 ms
endif
While Wiimote.RawForceZ > 5
Wiimote.Led1 = 1
Wiimote.Led2 = 1
Wiimote.Led3 = 1
Wiimote.Led4 = 1
wait 500 ms
endif
While Wiimote.RawForceZ < -20 and > -25
Wiimote.Led1 = 1
Wiimote.Led2 = 0
Wiimote.Led3 = 0
Wiimote.Led4 = 0
wait 500 ms
endif
While Wiimote.RawForceZ < -25 and > -30
Wiimote.Led1 = 1
Wiimote.Led2 = 1
Wiimote.Led3 = 0
Wiimote.Led4 = 0
wait 500 ms
endif
While Wiimote.RawForceZ < -30 AND > -35
Wiimote.Led1 = 1
Wiimote.Led2 = 1
Wiimote.Led3 = 1
Wiimote.Led4 = 0
wait 500 ms
endif
While Wiimote.RawForceZ < -35
Wiimote.Led1 = 1
Wiimote.Led2 = 1
Wiimote.Led3 = 1
Wiimote.Led4 = 1
wait 500 ms
endif
//Racing Mode:
Keyboard.Up = Wiimote.Two
Keyboard.Down = Wiimote.One
If Wiimote.One or Wiimote.Two
Wiimote.Rumble = 1
Else
Wiimote.Rumble = 0
endif
if Wiimote.RawForceZ > 0
Keyboard.Right = 1
endif
if Wiimote.RawForceZ < -30
Keyboard.Left = 1
endif
if Wiimote.RawForceZ > -30 and < 0
Keyboard.Left = 0
Keyboard.Right = 0
endif
//Other.
Key.Enter = Wiimote1.Minus
Key.C = Wiimote1.A
Key.Space = Wiimote1.B
Key.F12 = Wiimote1.Plus
Key.Left = Wiimote1.Left
Key.Right = Wiimote1.Right
Key.Up = Wiimote1.Two
Key.Down = Wiimote1.One
Key.Escape = Wiimote1.Home
Key.Up = Wiimote1.Up
Key.Down = Wiimote1.Down
_________________ Try out my Scripts! |
|