mouse.enabled = false;
mouse.pressed = false;
+#if CONF_ZEEMOTE
+ ZeeInit();
+#endif
+
if (Config.joypad1Enabled) {
joypads[0] = 0x80000000UL;
}
}
printf("\n");
-#if CONF_ZEEMOTE
- ZeeInit();
-#endif
-
- // TODO Non-awful mouse support, Superscope
+ // TODO Non-awful mouse & superscope support
S9xInputScreenChanged();
}
void S9xDeinitInputDevices()
{
+#if CONF_ZEEMOTE
+ ZeeQuit();
+#endif
joypads[0] = 0;
joypads[1] = 0;
mouse.enabled = false;
mouse.pressed = false;
-#if CONF_ZEEMOTE
- ZeeQuit();
-#endif
}
void S9xInputScreenChanged()
if (enabled[0] && scan_result->number_of_devices > 0) {
players[0].zeemote =
zeemote_connect(&scan_result->device[0].bdaddr);
- if (!players[0].zeemote) {
+ if (players[0].zeemote) {
+ Config.joypad1Enabled = true;
+ } else {
fprintf(stderr, "Zeemote: Failed to connect for player %d", 1);
}
}
if (enabled[1] && scan_result->number_of_devices > 1) {
players[1].zeemote =
zeemote_connect(&scan_result->device[1].bdaddr);
- if (!players[1].zeemote) {
+ if (players[1].zeemote) {
+ Config.joypad2Enabled = true;
+ } else {
fprintf(stderr, "Zeemote: Failed to connect for player %d", 2);
}
}