Differences From Artifact [da9bf57bcb]:
- File
src/test/OTAppDelegate.m
— part of check-in
[a0f4283e81]
at
2024-05-05 18:59:50
on branch gamecontroller
— Add OFGameController
Only supports Nintendo 3DS so far. (user: js, size: 16672) [annotate] [blame] [check-ins using]
To Artifact [2b12d71a47]:
- File src/test/OTAppDelegate.m — part of check-in [a7a6705d90] at 2024-05-05 19:22:25 on branch gamecontroller — OFGameController: Add support for Nintendo DS (user: js, size: 16567) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
319 320 321 322 323 324 325 | WPAD_ScanPads(); if (WPAD_ButtonsDown(0) & WPAD_BUTTON_A) break; VIDEO_WaitVSync(); } | | < < < < < < < < < < < > > > > | 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 | WPAD_ScanPads(); if (WPAD_ButtonsDown(0) & WPAD_BUTTON_A) break; VIDEO_WaitVSync(); } #elif defined(OF_NINTENDO_DS) || defined(OF_NINTENDO_3DS) [OFStdOut setForegroundColor: [OFColor silver]]; [OFStdOut writeLine: @"Press A to continue"]; for (;;) { void *pool = objc_autoreleasePoolPush(); OFGameController *controller = [OFGameController controllerWithIndex: 0]; if ([controller.pressedButtons containsObject: @"A"]) break; # if defined(OF_NINTENDO_DS) swiWaitForVBlank(); # elif defined(OF_NINTENDO_3DS) gspWaitForVBlank(); # endif objc_autoreleasePoolPop(pool); } #elif defined(OF_NINTENDO_SWITCH) [OFStdOut setForegroundColor: [OFColor silver]]; [OFStdOut writeLine: @"Press A to continue"]; while (appletMainLoop()) { |
︙ | ︙ |