/*------------------------------------------------------------------------------ Super Meat Boy - Wiimote Script By: Bighead - http://bhemuhelp.co.nf/ - bighead.0@gmail.com Supports: Wiimote, Wiimote + Nunchuk, Classic Controller Maps To: Keyboard -------------------------------------------------------------------------------- NOTE: DO NOT PLUG or UNPLUG EXTENSIONS WHILE THE SCRIPT IS RUNNING or KEYBOARD ARROW KEY INPUTS WILL GET STUCK. THIS WILL MAKE IT HARDER TO STOP THE SCRIPT. -------------------------------------------------------------------------------- Wiimote Controls: +------------------+--------------------+-------------------------+ | Action | Button | Mapped From | +------------------+--------------------+-------------------------+ | Movement | D-Pad | Keyboard Arrow Keys | | Jump/Confirm | 2 | Keyboard Space | | Special (Run) | 1 | Keyboard Left Shift | | Menu/Back | + | Keyboard Escape | | Replay Level | A | Keyboard W | | Save Replay | -/1 | Keyboard Right Shift | | Leaderboards | A | Keyboard W | | World Swap | -/1 | Keyboard Right Shift | | Delete | A | Keyboard W | +------------------+--------------------+-------------------------+ Wiimote + Nunchuk Controls: +------------------+--------------------+-------------------------+ | Action | Button | Mapped From | +------------------+--------------------+-------------------------+ | Movement | Analog | Keyboard Arrow Keys | | Jump/Confirm | A | Keyboard Space | | Special (Run) | Z, B | Keyboard Left Shift | | Menu/Back | +, - | Keyboard Escape | | Replay Level | 1 | Keyboard W | | Save Replay | 2, B, Z | Keyboard Right Shift | | Leaderboards | 1 | Keyboard W | | World Swap | 2, B, Z | Keyboard Right Shift | | Delete | 1 | Keyboard W | +------------------+--------------------+-------------------------+ Classic Controller Controls: +------------------+--------------------+-------------------------+ | Action | Button | Mapped From | +------------------+--------------------+-------------------------+ | Movement | D-Pad/L Analog | Keyboard Arrow Keys | | Jump/Confirm | b | Keyboard Space | | Special (Run) | ZL, ZR | Keyboard Left Shift | | Menu/Back | +, a | Keyboard Escape | | Replay Level | y | Keyboard W | | Save Replay | x, ZR | Keyboard Right Shift | | Leaderboards | y | Keyboard W | | World Swap | x, ZR | Keyboard Right Shift | | Delete | y | Keyboard W | +------------------+--------------------+-------------------------+ ------------------------------------------------------------------------------*/ if (Wiimote.Classic.Exists) then // Movement Keyboard.Up = (-2 < Wiimote.Classic.Joy1Y < -0.4) or Wiimote.Classic.Up Keyboard.Down = (2 > Wiimote.Classic.Joy1Y > 0.4) or Wiimote.Classic.Down Keyboard.Left = (-2 < Wiimote.Classic.Joy1X < -0.4) or Wiimote.Classic.Left Keyboard.Right = (2 > Wiimote.Classic.Joy1X > 0.4) or Wiimote.Classic.Right // Jump Keyboard.Space = Wiimote.Classic.B // Special Keyboard.LeftShift = Wiimote.Classic.ZR or Wiimote.Classic.ZL // Menu/Back Keyboard.Escape = Wiimote.Classic.A or Wiimote.Classic.Plus // Replay Level (Game), Leaderboards (Map), Delete Replay (Replay Menu) Keyboard.W = Wiimote.Classic.Y // Save Replay (Game), Light/Dark World (Map) Keyboard.RightShift = Wiimote.Classic.X elseif (Wiimote.Nunchuk.Exists) then // Movement Keyboard.Up = (-2 < Wiimote.Nunchuk.JoyY < -0.4) Keyboard.Down = (2 > Wiimote.Nunchuk.JoyY > 0.4) Keyboard.Left = (-2 < Wiimote.Nunchuk.JoyX < -0.4) Keyboard.Right = (2 > Wiimote.Nunchuk.JoyX > 0.4) // Jump Keyboard.Space = Wiimote.A // Special Keyboard.LeftShift = Wiimote.Nunchuk.Z or Wiimote.B // Menu/Back Keyboard.Escape = Wiimote.Plus or Wiimote.Minus // Replay Level (Game), Leaderboards (Map), Delete Replay (Replay Menu) Keyboard.W = Wiimote.One // Save Replay (Game), Light/Dark World (Map) Keyboard.RightShift = Wiimote.Two else // Movement Keyboard.Up = Wiimote.Right Keyboard.Down = Wiimote.Left Keyboard.Left = Wiimote.Up Keyboard.Right = Wiimote.Down // Jump Keyboard.Space = Wiimote.Two // Special Keyboard.LeftShift = Wiimote.One // Menu/Back Keyboard.Escape = Wiimote.Plus // Replay Level (Game), Leaderboards (Map), Delete Replay (Replay Menu) Keyboard.W = Wiimote.A // Save Replay (Game), Light/Dark World (Map) Keyboard.RightShift = Wiimote.Minus endif