Game Player Control Edit Screen - cressie176/Load64 GitHub Wiki
Add or edit a control for a specific player in a game, including its system input and host input assignments.
When adding a new control:
┌──────────────────────────────────────────────────────────────────────────────┐
│ TOP BAR │
│ <Game Title> > Controls > Player <n> Controls > Add │
├──────────────────────────────────────────────────────────────────────────────┤
│ │
│ FORM │
│ ┌────────────────────────────────────────────────────────────────────────┐ │
│ │ ┌─────────────────────────────────────────────────┐ │ │
│ │ Description │ _ │ │ │
│ │ └─────────────────────────────────────────────────┘ │ │
│ │ │ │
│ │ ┌─────────────────────────────────────────────────┐ │ │
│ │ System Input │ — \/ │ │ │
│ │ └─────────────────────────────────────────────────┘ │ │
│ │ │ │
│ │ ┌──────────────────────────────────┐ │ │
│ │ Host Inputs │ — │ [Capture] [X] │ │
│ │ └──────────────────────────────────┘ │ │
│ │ │ │
│ │ [Save] [Cancel] │ │
│ └────────────────────────────────────────────────────────────────────────┘ │
│ │
├──────────────────────────────────────────────────────────────────────────────┤
│ BOTTOM BAR │
└──────────────────────────────────────────────────────────────────────────────┘
When editing an existing control:
┌──────────────────────────────────────────────────────────────────────────────┐
│ TOP BAR │
│ <Game Title> > Controls > Player <n> Controls > <Description> │
├──────────────────────────────────────────────────────────────────────────────┤
│ │
│ FORM │
│ ┌────────────────────────────────────────────────────────────────────────┐ │
│ │ ┌─────────────────────────────────────────────────┐ │ │
│ │ Description │ Attack_ │ │ │
│ │ └─────────────────────────────────────────────────┘ │ │
│ │ │ │
│ │ ┌─────────────────────────────────────────────────┐ │ │
│ │ System Input │ Fire \/ │ │ │
│ │ └─────────────────────────────────────────────────┘ │ │
│ │ │ │
│ │ ┌──────────────────────────────────┐ │ │
│ │ Host Inputs │ Button South, Enter │ [Capture] [X] │ │
│ │ └──────────────────────────────────┘ │ │
│ │ │ │
│ │ [Save] [Cancel] │ │
│ └────────────────────────────────────────────────────────────────────────┘ │
│ │
├──────────────────────────────────────────────────────────────────────────────┤
│ BOTTOM BAR │
└──────────────────────────────────────────────────────────────────────────────┘
Focusable: No
Interactive: No
Purpose: Identify the game and player context for this control
Type: Form
Focusable: Yes (primary focus region)
Interactive: Yes
Purpose: Define the control description, system input, and host input assignments
Fields are pre-populated when editing an existing control, or empty when adding a new one.
Free-text label describing what this control does (e.g. Move Up, Attack). Shown to the user on the Game Controls screen.
Dropdown of all available inputs for this player, listed in groups:
-
Joystick actions —
Up,Down,Left,Right,Fire. Only actions not already used by another control for this player are shown. -
System keys — all system keys in human-readable form, sub-grouped as Special Keys, Function Keys, Letter Keys, Number Keys, Symbol Keys (e.g.
F1,RUN/STOP,.). Only keys not already used by another control for this player are shown.
Displays the currently assigned controller buttons and host keys as a comma-separated list (e.g. Button South, Enter). Shows — if none assigned.
[Capture] enters capture mode. While active, the entire form is non-interactive. LoadC64 detects the next controller button pressed or keyboard key pressed, resolves it to its canonical name or keyboard key, and adds it to the list if not already present. Any input is a valid capture target — including Escape — so there is no cancel mechanism; press [Cancel] (form footer) to discard the whole form, or use [X] after exiting capture mode to clear unwanted additions. If the detected input is a keyboard key and it is already mapped to any other control in this game — across all players and general controls — it is rejected. If the detected input is a controller button and it is already mapped to any other control for this player — it is rejected. In either case, the bottom bar shows the conflict message and capture mode remains active waiting for the next input. Capture mode exits automatically after each accepted capture, restoring normal form interaction.
[X] removes all host input assignments for this control.
- [Save] saves the control definition, updates all
GameControlAssignmentrows, and updatesKeyMappingrows on the launch configuration; then returns to the Game Player Control List screen. - [Cancel] discards changes and returns to the Game Player Control List screen.
Focusable: No
Interactive: No
Purpose: Display capture mode instructions, conflict errors, and validation errors
When capture mode is active:
├──────────────────────────────────────────────────────────────────────────────┤
│ BOTTOM BAR │
│ Press a button or key to capture. │
└──────────────────────────────────────────────────────────────────────────────┘
When a captured input is already mapped:
├──────────────────────────────────────────────────────────────────────────────┤
│ BOTTOM BAR │
│ <Input> is already mapped to <Control FQN> │
└──────────────────────────────────────────────────────────────────────────────┘
Where <Control FQN> is:
-
Player <n> – <Description>for a player control (e.g.Player 1 – Attack) -
<Description>for a general control (e.g.Start 1 Player)
After a validation error:
├──────────────────────────────────────────────────────────────────────────────┤
│ BOTTOM BAR │
│ <Error message> │
└──────────────────────────────────────────────────────────────────────────────┘
- When adding: all fields are empty on entry.
- When editing: all fields are pre-populated.
- If validation fails, the error is shown in the bottom bar and the form remains open.
| Name | Type | Required | Notes |
|---|---|---|---|
| Description | String | Yes | Must not be empty. |
| System Input | Dropdown | Yes | Must be selected. Must not duplicate an existing control for this player. |