MCPcopy Create free account
hub / github.com/BlitterStudio/amiberry / setjoyinputs

Function setjoyinputs

src/inputdevice.cpp:7517–7550  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

7515}
7516
7517static void setjoyinputs (struct uae_prefs *prefs, int port)
7518{
7519 joyinputs[port] = NULL;
7520 switch (joymodes[port])
7521 {
7522 case JSEM_MODE_JOYSTICK:
7523 if (port >= 2)
7524 joyinputs[port] = port == 3 ? ip_parjoy2 : ip_parjoy1;
7525 else
7526 joyinputs[port] = port == 1 ? ip_joy2 : ip_joy1;
7527 break;
7528 case JSEM_MODE_GAMEPAD:
7529 joyinputs[port] = port ? ip_joypad2 : ip_joypad1;
7530 break;
7531 case JSEM_MODE_JOYSTICK_CD32:
7532 joyinputs[port] = port ? ip_joycd322 : ip_joycd321;
7533 break;
7534 case JSEM_MODE_JOYSTICK_ANALOG:
7535 joyinputs[port] = port ? ip_analog2 : ip_analog1;
7536 break;
7537 case JSEM_MODE_WHEELMOUSE:
7538 case JSEM_MODE_MOUSE:
7539 joyinputs[port] = port ? ip_mouse2 : ip_mouse1;
7540 break;
7541 case JSEM_MODE_LIGHTPEN:
7542 joyinputs[port] = getlightpen(port, joysubmodes[port]);
7543 break;
7544 break;
7545 case JSEM_MODE_MOUSE_CDTV:
7546 joyinputs[port] = ip_mousecdtv;
7547 break;
7548 }
7549 //write_log (_T("joyinput %d = %p\n"), port, joyinputs[port]);
7550}
7551
7552static void setautofire (struct uae_input_device *uid, int port, int sub, int af, bool set)
7553{

Callers 1

compatibility_copyFunction · 0.85

Calls 1

getlightpenFunction · 0.85

Tested by

no test coverage detected