All keyboard and joystick events can be mapped to any Amiga keyboard and joystick action, overriding default settings and (and the setup resulting from using the joystick_port_n options). A few examples of what you can do:
- Do you want the key ‘S’ on your keyboard to press the ‘R’ key on the Amiga keyboard? You can do this with custom input mapping.
- Do you want to create a setup where you can play Pinball Dreams with a game pad? You can map game pad buttons to the Amiga keyboard F1, F2, F3, F4, cursor down, left shift and right shift keys.
To map an action, you add a line like this to your configuration file:
devicename_eventname = actionname
Here is a specific example, mapping the keyboard key q to the fire button on the primary Amiga joystick (joy_1 is the joystick in joystick port 1):
keyboard_key_q = action_joy_1_fire_button
Examples of input actions are:
action_joy_1_fire_button (fire button on joystick in port 1) action_key_z (press amiga keyboard key Z) action_drive_0_insert_floppy_0 (insert disk from floppy image list)
I have put the list of available actions on its own page due to the large number of actions.
Mapping Joystick Events
Here are the different types of event names you can use. joystick_0 is the first joystick connected, joystick_1 is the second, etc. Similarly, you can use button_0 (first button), button_1 (second button) and so on:
joystick_0_button_0 joystick_0_axis_0_neg joystick_0_axis_0_pos joystick_0_hat_0_up joystick_0_hat_0_down joystick_0_hat_0_left joystick_0_hat_0_right
For most game pads with a proper universal configuration, you can use universal event names instead and make the configuration work identically even with different types of game pads connected. The above configuration is not suited for this, because button numbers have generally no relation to the physical placement of the game pad buttons.
Universal Event Names
With universal event names, you can map these events instead:
joystick_0_dpad_left joystick_0_dpad_right joystick_0_dpad_up joystick_0_dpad_down joystick_0_lstick_left joystick_0_lstick_right joystick_0_lstick_up joystick_0_lstick_down joystick_0_lstick_button joystick_0_rstick_left joystick_0_rstick_right joystick_0_rstick_up joystick_0_rstick_down joystick_0_rstick_button joystick_0_south_button joystick_0_west_button joystick_0_north_button joystick_0_east_button joystick_0_start_button joystick_0_select_button joystick_0_left_shoulder joystick_0_right_shoulder joystick_0_left_trigger joystick_0_right_trigger
Matching a Joystick Device
To match a specific joystick device, you can either (as in the above examples) match joystick by number:
joystick_0 joystick_1 joystick_2 etc...
Or you can match devices by name:
The device name is the name of the device as it appears in your operating system, converted to lower case and all characters other than letters and numbers converted to underscores. Adjacent underscores are merged into one, and trailing underscores are stripped.
For instance, a device named:
Controller (Xbox 360 Wireless Receiver)
will be matched by:
If you have more than game pad of the same model connected, you can match the other ones with:
logitech_dual_action_usb_2 (the second connected of this model) logitech_dual_action_usb_3 (the third connected of this model) etc...
If you want to play Pinball Dreams with the first connected game pad, instead of using keyboard controls, you might want to map something like this:
joystick_0_left_shoulder = action_key_shift_left joystick_0_right_shoulder = action_key_shift_right joystick_0_north_button = action_key_f1 joystick_0_dpad_down = action_key_cursor_down
Along with a few more actions, such as mappings for amiga keys F2, F3, F4 and Space.
Mapping Keyboard Keys
Here are the names of all the keyboard events you can trigger on. Please note that not all events are valid for all keyboards. Also, keys are named after the corresponding physical key on English keyboard layouts!
keyboard_key_backspace keyboard_key_tab keyboard_key_clear keyboard_key_return keyboard_key_pause keyboard_key_escape keyboard_key_space keyboard_key_exclaim keyboard_key_quotedbl keyboard_key_hash keyboard_key_dollar keyboard_key_ampersand keyboard_key_quote keyboard_key_leftparen keyboard_key_rightparen keyboard_key_asterisk keyboard_key_plus keyboard_key_comma keyboard_key_minus keyboard_key_period keyboard_key_slash
keyboard_key_0 keyboard_key_1 keyboard_key_2 keyboard_key_3 keyboard_key_4 keyboard_key_5 keyboard_key_6 keyboard_key_7 keyboard_key_8 keyboard_key_9
keyboard_key_colon keyboard_key_semicolon keyboard_key_less keyboard_key_equals keyboard_key_greater keyboard_key_question keyboard_key_at keyboard_key_leftbracket keyboard_key_backslash keyboard_key_rightbracket keyboard_key_caret keyboard_key_underscore keyboard_key_backquote
keyboard_key_a keyboard_key_b keyboard_key_c keyboard_key_d keyboard_key_e keyboard_key_f keyboard_key_g keyboard_key_h keyboard_key_i keyboard_key_j keyboard_key_k keyboard_key_l keyboard_key_m keyboard_key_n keyboard_key_o keyboard_key_p keyboard_key_q keyboard_key_r keyboard_key_s keyboard_key_t keyboard_key_u keyboard_key_v keyboard_key_w keyboard_key_x keyboard_key_y keyboard_key_z
keyboard_key_kp0 keyboard_key_kp1 keyboard_key_kp2 keyboard_key_kp3 keyboard_key_kp4 keyboard_key_kp5 keyboard_key_kp6 keyboard_key_kp7 keyboard_key_kp8 keyboard_key_kp9 keyboard_key_kp_period keyboard_key_kp_divide keyboard_key_kp_multiply keyboard_key_kp_minus keyboard_key_kp_plus keyboard_key_kp_enter keyboard_key_kp_equals
keyboard_key_up keyboard_key_down keyboard_key_right keyboard_key_left keyboard_key_insert keyboard_key_delete keyboard_key_home keyboard_key_end keyboard_key_pageup keyboard_key_pagedown
keyboard_key_f1 keyboard_key_f2 keyboard_key_f3 keyboard_key_f4 keyboard_key_f5 keyboard_key_f6 keyboard_key_f7 keyboard_key_f8 keyboard_key_f9 keyboard_key_f10 keyboard_key_f11 keyboard_key_f12 keyboard_key_f13 keyboard_key_f14 keyboard_key_f15
keyboard_key_numlock keyboard_key_capslock keyboard_key_scrollock keyboard_key_rshift keyboard_key_lshift keyboard_key_rctrl keyboard_key_lctrl keyboard_key_ralt keyboard_key_lalt keyboard_key_lsuper keyboard_key_rsuper keyboard_key_help keyboard_key_print keyboard_key_sysreq keyboard_key_break keyboard_key_menu keyboard_key_power keyboard_key_euro keyboard_key_undo