Repository navigation
Structure of the whdload_db.json file
The whdload_db.json file is used by the Amiberry WHDLoad auto-booter (whdbooter) to identify supported game archives and configure emulator settings. It is built by the amiberry-game-db repository from HoraceAndTheSpider's Amiberry-XML-Builder XML, plus that repository's own snippets and per-game settings. It conforms to schema/whdload_db.schema.json.
Amiberry reads whdload_db.json when it exists. Only if the file is missing does it fall back to whdload_db.xml (see WHDLoad DB Structure (legacy XML)); a JSON file that fails to parse is not replaced by the XML.
The database is stored at:
<whdboot path>/game-data/whdload_db.json
The <whdboot path> directory is configured in the Paths panel.
The file can be updated through:
- Paths panel: The Update WHDBooter files button downloads the latest version.
-
Command line: Running
amiberry --download-whdbootdownloads the latest version. -
Automatic startup update: In versions after 8.4.1, Amiberry compares the top-level
generatedtimestamp of the bundled database with<whdboot path>/game-data/whdload_db.json. If the bundled copy is newer or if the user copy is missing, Amiberry copies the bundled file into place.
When an update occurs, Amiberry preserves the existing database as:
<whdboot path>/game-data/whdload_db.bak
Direct manual edits to whdload_db.json are overwritten on database updates.
To customize settings for a specific game:
- Load the game in Amiberry.
- Open the GUI (
F12). - Make the desired configuration changes in the emulator panels.
- Go to the Configurations panel and click Save.
This creates a <GameName>.uae file. On subsequent launches of that game, Amiberry loads <GameName>.uae instead of the database defaults. For more details, see Customizing Settings on the WHDLoad Auto-booting page.
To submit setting corrections to the shared database:
- Submit an entry via the game settings issue template.
- Read CONTRIBUTING.md.
When an archive is selected, Amiberry matches it against database entries:
- Amiberry computes the lowercase SHA1 checksum of the archive.
- It iterates through the
gamesarray inwhdload_db.json. - If an entry's
sha1field matches the archive checksum, that entry is selected immediately. - If no SHA1 match occurs, entries matching the archive
filename(excluding file extension) are checked. From the release after 8.4.1, the scan continues through the full array, so the last entry with matchingfilenameis selected. - In Amiberry 8.4.1 and earlier, the booter selected the first entry matching either filename or SHA1.
Releases after 8.4.1 write the archive's SHA1 to the log as WHDBooter - Archive SHA1: ... for every archive, including ones not in the database. Include it when asking for a game to be added.
The root object contains database metadata and the array of game entries.
| Field | Type | Description |
|---|---|---|
schema_version |
integer | Database schema version. Value is 2. |
source |
string | Source repository or upstream builder URL. |
generated |
string | ISO-8601 UTC timestamp of database generation (e.g. 2026-10-14T15:15:44Z). |
upstream_timestamp |
string | Generation timestamp from the upstream XML scanner (yyyy-mm-dd at hh:mm:ss). |
game_count |
integer | Number of game objects in the games array. |
games |
array | Array of game entry objects. |
Each entry in the games array contains identification, slave details, and emulator settings.
| Field | Type | Required | Description |
|---|---|---|---|
filename |
string | Yes | Archive filename without extension (e.g. Turrican2_v1.7_0029). Used for fallback matching. |
sha1 |
string | Yes | 40-character lowercase hexadecimal SHA1 checksum of the archive. Primary matching key. |
name |
string | No | Clean game title. |
subpath |
string | No | Subdirectory inside the archive containing game data and slave files. |
variant_uuid |
string | No | OpenRetro variant UUID used by external tools such as Skyscraper. |
slave_count |
integer | No | Total number of slave files in the archive. |
slave_default |
string | No | Filename of the default slave executed by the auto-booter. |
slave_libraries |
boolean | No | When true, enables extra system libraries (such as XPK) in LIBS:. Defaults to false. |
slaves |
array | No | Array of slave definition objects. |
hardware |
object | No | Hardware and display settings applied by the booter. |
custom_controls |
array | No | Array of configuration lines applied directly to emulator settings. |
The slaves array contains details for each .slave file in the archive.
| Field | Type | Required | Description |
|---|---|---|---|
filename |
string | Yes | Filename of the slave (e.g. Turrican2.Slave). |
datapath |
string | No | Subdirectory containing game data, read from the slave header. |
custom_fields |
array | No | Array of custom option objects defined by the slave header. |
WHDLoad slaves can declare custom options in their headers following the ws_config specification. Amiberry exposes these in the Custom Fields dialog in the WHDLoad panel.
| Field | Type | Required | Description |
|---|---|---|---|
slot |
integer | Yes | Custom slot number from 1 to 5, corresponding to WHDLoad options CUSTOM1 through CUSTOM5. |
type |
string | Yes | Field type: "bool", "bit", or "list". |
caption |
string | No | Label text for "bool" and "list" controls. |
label |
string | No | Label text for an individual flag entry in a "bit" control. |
bit |
integer | No | 0-based bit index toggled by an entry in a "bit" control. |
options |
array of strings | No | List of option strings for a "list" dropdown combo box. |
-
GUI Presentation:
-
"bool": Displayed as a checkbox labeled withcaption. Checking sets the slot value to1; unchecking sets it to0. -
"bit": Displayed as individual checkboxes labeled withlabel. Checking or unchecking toggles that specific bit (1 << bit) in the slot value. -
"list": Displayed as a dropdown combo box labeled withcaption. Selecting an option sets the slot value to the 0-based index of that option.
-
-
Boot Script: When launching, Amiberry inspects slots 1 through 5. For any slot with a non-zero value, WHDBooter appends
CUSTOM<slot>=<value>(for example,CUSTOM1=1orCUSTOM2=3) to the WHDLoad or JST execution command in the startup script. -
Saved Configurations: Custom field values are stored in
.uaefiles underwhdload_custom1throughwhdload_custom5.
The custom_controls array contains emulator configuration lines applied directly via Amiberry's configuration parser (parse_cfg_line).
These map controller buttons to eliminate keyboard dependencies for in-game actions.
Example:
"custom_controls": [
"joyport1_amiberry_custom_none_b=Joy2 Up",
"joyport1_amiberry_custom_none_start=Help",
"joyport0_amiberry_custom_none_b=Joy1 Up"
]The hardware object defines the emulated Amiga hardware and display settings applied by WHDBooter.
| Key | Type | Allowed Values | Effect in Amiberry |
|---|---|---|---|
port0 |
string |
"joy", "mouse", "cd32"
|
Sets control port 0 mode: 0 for joystick ("joy"), 2 for mouse ("mouse"), or 7 for CD32 gamepad ("cd32"). |
port1 |
string |
"joy", "mouse", "cd32"
|
Sets control port 1 mode: 0 for joystick ("joy"), 2 for mouse ("mouse"), or 7 for CD32 gamepad ("cd32"). |
primary_control |
string |
"joystick", "mouse"
|
Host device mapping. When set to "mouse", port 0 uses host default_mouse1 and port 1 uses default_mouse2. Otherwise, port 0 uses host default_controller2 (falling back to mouse) and port 1 uses default_controller1 (falling back to joy1). |
secondary_control |
string |
"joystick", "mouse"
|
Parsed into the internal hardware structure; not applied by Amiberry's input logic. |
cpu |
string |
"68000", "68010", "68020", "68030", "68040"
|
Sets the CPU model. "68020", "68030" and "68040" are always kept; a 68040 also gets its internal FPU, and a 68030 always uses 32-bit addressing. When AGA or CD32 is active, any other value becomes 68020; the same happens without an A600 ROM. When set to 68000 or 68010 on an A600 base model, also sets chipmem_size=4 (2 MB Chip RAM). In Amiberry 8.4.1 and earlier, AGA and CD32 games always use a 68020, and "68030" is not recognized: it becomes 68000 on the A600 preset and 68020 otherwise. |
blitter |
string |
"normal", "wait", "immediate"
|
"immediate" sets immediate_blits=true. "normal" sets waiting_blits=automatic. "wait" leaves waiting blits at default. |
clock |
string |
"7", "14", "25", "28", "max"
|
Sets CPU clock: "7" sets cpu_multiplier=2; "14" sets cpu_multiplier=4; "25" or "28" sets cpu_multiplier=8; "max" sets cpu_speed=max. |
chipset |
string |
"aga", "cd32" (compared case-insensitively; the database uses lowercase "aga") |
"aga" or "cd32" selects the A1200 preset with 8 MB Fast RAM and a 68020 CPU. Archive filenames containing AGA or CD32 do the same. Without either, the A600 preset is used when an A600 Kickstart ROM is available, otherwise the A1200 preset. |
jit |
boolean |
true, false
|
When true, sets cachesize=16384 to enable the JIT compiler with a 16 MB cache, and turns off CPU compatible mode and cycle-exact. JIT needs a 68020 or higher. |
cpu_24bitaddressing |
boolean |
true, false
|
When false, sets cpu_24bit_addressing=false to enable 32-bit addressing. Also disabled if z3_ram is set. |
cpu_compatible |
boolean |
true, false
|
Sets cpu_compatible=true or cpu_compatible=false. Since cycle-exact needs compatible mode, false also sets cycle_exact=false in Amiberry versions after 8.4.1; earlier versions leave cycle-exact on, which turns compatible mode back on. |
cpu_exact |
boolean |
true, false
|
The WHDLoad presets are already fully cycle-exact. true sets cpu_cycle_exact=true. false sets cycle_exact=false (CPU, memory and blitter) in Amiberry versions after 8.4.1; earlier versions ignore it. |
sprites |
string |
"none", "playfield", "sprites", "full"
|
Sets sprite collision level (collision_level=<sprites>). |
screen_autoheight |
boolean |
true, false
|
When true, sets gfx_auto_crop=true to crop display borders automatically. When false, sets gfx_auto_crop=false. |
screen_width |
integer | e.g. 640, 704, 720
|
Sets manual crop width (gfx_manual_crop_width) and centers the display horizontally when screen_autoheight is false. |
screen_height |
integer | e.g. 400, 432, 480, 512
|
Sets manual crop height (gfx_manual_crop_height) and centers the display vertically when screen_autoheight is false. |
screen_centerh |
string |
"smart", "none"
|
When "smart", sets smart horizontal centering (gfx_xcenter=2) if auto-crop is disabled, or disables centering (gfx_xcenter=0) if auto-crop is active. "none" sets gfx_xcenter=0. |
screen_centerv |
string |
"smart", "none"
|
When "smart", sets smart vertical centering (gfx_ycenter=2) if auto-crop is disabled, or disables centering (gfx_ycenter=0) if auto-crop is active. "none" sets gfx_ycenter=0. |
screen_offseth |
integer | e.g. -38
|
Sets manual horizontal offset (gfx_horizontal_offset) when screen_autoheight is false. |
screen_offsetv |
integer | e.g. 2, 12, 20
|
Sets manual vertical offset (gfx_vertical_offset) when screen_autoheight is false. |
ntsc |
boolean |
true, false
|
When true, sets ntsc=true to switch video refresh to NTSC 60Hz. |
fast_ram |
integer |
1, 2, 4, 8
|
Fast RAM size in megabytes; sets fastmem_size=<value>. |
z3_ram |
integer |
1 to 128 (MB; powers of two) |
Zorro III Fast RAM in megabytes; sets z3mem_size=<value> and disables 24-bit addressing (cpu_24bit_addressing=false). |
-
fast_copper: string ("true"). Present in upstream data for select AGA titles; not read or applied by Amiberry. -
chip_ram: integer. Present in the schema definition; not read by Amiberry. WHDBooter sets Chip RAM via base machine presets or assigns 2 MB (chipmem_size=4) when 68000/68010 CPU is selected.
{
"filename": "Turrican2_v1.7_0029",
"sha1": "356e70a42630afb9d5daa3fee9cf899b9a046508",
"name": "Turrican II - The Final Fight",
"subpath": "Turrican2",
"variant_uuid": "83abde99-009b-5169-83ff-a8f9b09790da",
"slave_count": 1,
"slave_default": "Turrican2.Slave",
"slave_libraries": false,
"slaves": [
{
"filename": "Turrican2.Slave",
"datapath": ""
}
],
"hardware": {
"primary_control": "joystick",
"port0": "cd32",
"port1": "cd32",
"screen_autoheight": false,
"screen_height": 432,
"screen_width": 720,
"screen_centerh": "smart",
"screen_centerv": "smart"
}
}{
"filename": "SuperOffRoad_v1.3a_NTSC",
"sha1": "8f0ea64bd198a7c529e8389b737a30f712bdd6a7",
"name": "Super Off Road (NTSC)",
"subpath": "SuperOffRoadNTSC",
"variant_uuid": "0164612d-36f8-5932-9c05-bffb2ca76596",
"slave_count": 1,
"slave_default": "SuperOffRoadNTSC.Slave",
"slave_libraries": true,
"slaves": [
{
"filename": "SuperOffRoadNTSC.Slave",
"datapath": ""
}
],
"hardware": {
"ntsc": true,
"primary_control": "joystick",
"port0": "joy",
"port1": "joy",
"screen_autoheight": false,
"screen_height": 400,
"screen_width": 720,
"screen_centerh": "smart",
"screen_centerv": "smart"
},
"custom_controls": [
"joyport1_amiberry_custom_none_b=Joy2 Up",
"joyport1_amiberry_custom_none_start=Help",
"joyport0_amiberry_custom_none_b=Joy1 Up"
]
}{
"filename": "3DBalls_v1.0_Avenger",
"sha1": "5f68a7c1c145af5b24c6e15f0cd7f58fb6d72f47",
"name": "3 DBalls",
"subpath": "3DBalls",
"variant_uuid": "90e68955-7402-5cb3-9885-baa4f2460c99",
"slave_count": 1,
"slave_default": "3DBalls.Slave",
"slave_libraries": false,
"slaves": [
{
"filename": "3DBalls.Slave",
"datapath": "",
"custom_fields": [
{
"slot": 1,
"type": "bool",
"caption": "Remove 'PatternBreak' support"
}
]
}
],
"hardware": {
"primary_control": "joystick",
"port0": "joy",
"port1": "joy",
"screen_autoheight": true,
"screen_centerh": "smart",
"screen_centerv": "smart"
}
}Bitmask (bit) and dropdown list (list) custom fields follow the structure below:
"custom_fields": [
{
"slot": 1,
"type": "bit",
"label": "Run secret part",
"bit": 0
},
{
"slot": 2,
"type": "list",
"caption": "Start with Tune",
"options": [
"Off",
"1",
"2",
"3",
"4",
"5",
"6"
]
}
]- Home
- Quick Start
- Android
- Troubleshooting
- Frequently Asked Questions
- Paths and Files
- Kickstart ROMs (BIOS)
- Amiberry Directories
- Compile from Source
- Using Amiberry with RetroPie
- How to Enable Integer Scaling
- RP9 Packages
- WHDLoad Auto-booting
- WHDLoad Workflow
- WHDLoad Booter FAQ
- WHDLoad DB Structure
- WHDLoad DB Structure (legacy XML)
- Start & Settings
- Hardware
- Media & Storage
- Display & Audio
- Input & Control
- System & Runtime
- Input Mapping Guide
- Setting up Input Controllers
- Setting up Keyboard Controllers
- Custom Events
- RetroArch Commands
- Mouse/Joystick Autoswitching