Line 125:
Line 125:
== Tips ==
== Tips ==
−
* SDL_Init must include the SDL_INIT_JOYSTICK flag set for any input events to work, and SDL_JoystickOpen(0) must be called. Wiimote events come as SDL_MOUSBUTTON* and SDL_MOUSEMOTION as well as SDL_JOYBUTTON* events.
+
* SDL_Init must include the SDL_INIT_JOYSTICK flag set for any input events to work, and SDL_JoystickOpen(0) must be called. Wiimote events come as SDL_MOUSBUTTON* and SDL_MOUSEMOTION as well as SDL_JOYBUTTON* events. To enable this, for all the wiimote events (both joystick and mouse), you must set the joystick event processing state with SDL_JoystickEventState. If you are not handling the wiimote via the event queue then you must explicitly request a joystick update by calling SDL_JoystickUpdate.
* If you're going to be doing file I/O operations, call fatInitDefault() before any calls to SDL. Lockups can occur if you call that after SDL and do some big writes to the SD card.
* If you're going to be doing file I/O operations, call fatInitDefault() before any calls to SDL. Lockups can occur if you call that after SDL and do some big writes to the SD card.