NBA Showtime Recomp

NBA Showtime Recomp is a native PC port of the arcade game NBA Showtime NBA on NBC with an OpenGL renderer and Hor+ widescreen.

README

NBA Showtime Recomp

A static recompilation of the arcade game NBA Showtime: NBA on NBC (Midway, 1999) for modern PCs. The game ran on Midway's Vegas hardware: a MIPS R5000 CPU, a 3dfx Voodoo Banshee and a DCS2 sound board. Its BIOS and game code are translated from MIPS machine code into C, then compiled into a native program that runs with a model of the original hardware.

No game data is included. You need your own copy of the ROM set. The recompiled code is produced from it on your machine.

Features

  • Native code with no CPU interpreter. Hardware models cover the IDE disk, the I/O ASIC, interrupts, timers, NVRAM and the DCS2 sound board.
  • An OpenGL renderer for the Banshee at any resolution.
  • Hor+ widescreen that matches the window's aspect ratio automatically (up to 32:9), or a fixed ratio (--aspect 16:9, 21:9, any ratio), with the 2D HUD kept at its original proportions.
  • Keyboard controls and up to four gamepads, with analog sticks mapped onto the original 49-way joysticks.
  • An in-game menu (Esc, or L3 + R3 on a gamepad) that pauses the game and changes gameplay (free play, 2- or 4-player cabinet, skipping the boot screen), graphics, audio and controls, with rebindable keys and buttons. Works with a keyboard, gamepad or mouse, and saves the settings.
  • The game's saved data (CMOS audits and adjustments, and the records it writes to its hard disk) is kept between sessions.
  • Online play for up to four machines (delay-based lockstep), where each player can bring their own saved player record.
  • A launcher that turns the ROM set into a playable build, so players need neither a compiler nor MAME, and a recomplauncher.json so RecompLauncher can set the game up in one click.

Playing

You need your own ROM set, ideally as one zip holding both parts:

NBA Showtime.zip
  nbashowt.zip              the BIOS and sound ROM (MAME's set)
  nbashowt/nbashowt.chd     the hard disk

Both must sit in the zip as they are: the CHD can't be inside another zip. A MAME rom folder, or any folder holding the files, works too. Files are recognised by their content, not their names.

With RecompLauncher

Install NBA Showtime Recomp, pick your ROM set zip on the setup screen, and press Play. The setup step builds the game from your zip (under a minute on most PCs). Settings are on the game's page and in Big Picture mode, where the game starts full screen.

On its own
  1. Download the release for your platform and unpack it anywhere.
  2. Run nbalauncher, choose your ROM set zip and press Build. It builds into the folder you unpacked (or pick another one).
  3. Press Play, or run nbashowtime from that folder.

On macOS (Apple Silicon) the programs are not notarized by Apple, so macOS refuses to open them straight from a download. After unpacking, clear the download flag on the folder once, in Terminal:

xattr -dr com.apple.quarantine ~/Downloads/NBAShowtime-Recomp-*-macOS-arm64

(use the folder you unpacked). Then run nbalauncher from Terminal or double-click it in Finder.

The ROM set must contain:

filecheck
BIOS showtime_mar15_1999.u27CRC32 ff5d620d
sound boot ROM vegassio.binCRC32 d1470e23
disk nbashowt.chdCHD v5, SHA-1 f7c56bc3dcbebc434de58034986179ae01127f87

Most updates replace only the engine: unpack the new release over the old folder and your build, settings and saves stay. If an update changes the recompiler's output, the game asks you to build again (RecompLauncher runs its setup step again by itself). See docs/launcher.md.

Controls
Player 1Player 2Players 3/4
StickarrowsI J K Lgamepad
A / B / TurboZ / X / CQ / W / Egamepad
Start / Coin1 / 52 / 63, 4 / 7, 8

Gamepads are assigned to players 1-4 in the order they are connected. Keys and buttons can be changed in the menu (Controls).

keyaction
Esc, or L3 + R3menu: pause, settings, quit
F11 or Alt+Enter (Option+Return on a Mac)toggle fullscreen
F2cycle aspect ratio: Auto (default), 4:3, 16:10, 16:9, 21:9, 32:9
- / =volume down / up
F9service credit
F10test switch: the operator menu (audits, adjustments, tests; move with the stick, select with a button)
Online play

One player opens a room and the others join it, from the menu (Esc → Online: Create Room, then Join Room with the code; the host starts the game when everyone is in) or the command line:

nbashowtime --host --wait-start        # a room, with a code from the built-in lobby
nbashowtime --join KQXRT --bring ALICE

The lobby server built into the game (tools/lobby/nbalobby.c) hands out the room codes, connects the machines directly through their routers when it can, and relays the game's packets when it can't, so nobody forwards a port. Connection on the Online page can pick your own lobby instead, or none: then the others join by the host's address (on the same network, over a VPN such as Tailscale, or with the host's port forwarded). Each player keeps their own display and controls, and the host's game adjustments apply to everyone. --bring adds one of your saved player records to the game. You enter it there with PIN 0000, and its new stats go back into your own save when you quit. See docs/netplay.md for all options and how it works.

Options
nbashowtime [--aspect auto|16:9] [--fullscreen] [--window WxH] [--scale S]
            [--vsync] [--volume PERCENT] [--no-sound] [--save-dir DIR] [--no-save] [--perf]
            [--record FILE | --replay FILE] [--hash-log FILE]
            [--host [PORT] | --join HOST[:PORT]] [--bring NAME[:PIN]] [--slot N] [--delay N]

The game starts in free play on a 4-player cabinet; both can be changed under Gameplay.

Settings changed in the menu are saved to settings.ini next to the executable if one is already there (RecompLauncher creates it), otherwise in your user data folder (~/.local/share/NBAShowtimeRecomp/ on Linux, %APPDATA%\NBAShowtimeRecomp\ on Windows, ~/Library/Application Support/NBAShowtimeRecomp/ on macOS). The game's own saved data goes in the same folder: nvram.bin and disk.bin (--save-dir DIR puts them elsewhere, --no-save keeps nothing). Options given on the command line apply to that run only. Without a terminal to print to, the game writes its messages to logs/nbashowtime.log in the same folder. --record saves the inputs of a session and --replay plays them back; see docs/netplay.md.

If the sound crackles, raise audio_buffer_ms under [audio] in settings.ini (default 60, up to 250): that much sound is kept queued ahead of the sound card, so a slow frame no longer runs it dry.

Platform status

platformstatus
Linuxworking, tested end to end
Windowsengine and launcher build with clang/MinGW; the launcher's command-line build and the game run; not yet played through
macOSApple Silicon: engine, launcher and the launcher's build run; boots to the attract mode and into a game with sound. Not yet played through. Intel Macs build from source
Androidplanned (game library cross-built on desktop)

Building from source

You need CMake, Ninja, a C/C++ compiler (clang recommended: the runtime is about 40% slower when built with gcc) and the SDL3 development files.

git clone --recursive https://github.com/PlayingKarrde/NBAShowtime-Recomp.git
cd NBAShowtime-Recomp
CC=clang CXX=clang++ cmake -S . -B build-clang -G Ninja
cmake --build build-clang

This builds the engine (nbashowtime) and the launcher (build-clang/launcher/nbalauncher). The launcher needs Zig 0.17, either unpacked into toolchain/zig/ or on PATH. Run the launcher from the build tree and it uses the engine you just built.

On macOS, install the tools with Homebrew (brew install cmake ninja zig sdl3) and use the system clang: cmake -S . -B build -G Ninja && cmake --build build.

If you cloned without --recursive, fetch the libchdr submodule with git submodule update --init.

Development workflow

Recompiler development works from a MAME dump of the game's entry state in work/. That folder, rom/ and generated/ are gitignored, because they hold copyrighted data or code derived from it.

./build-clang/tools/recomp/nbarecomp generate-vegas work/dumps/entry_ram.bin --out generated
cmake --build build-clang          # now also builds nbagame.so from generated/
./build-clang/nbashowtime          # reads work/ when there is no data/ folder

tools/mame/ has the Lua scripts used to dump and trace the game in MAME.

Repository layout

pathcontents
tools/recomp/nbarecomp: MIPS analysis, disassembly and C code generation
runtime/Vegas hardware models (CPU glue, IDE, I/O ASIC, Banshee, DCS2, timers)
src/host/the nbashowtime engine: SDL3 window, OpenGL renderer, audio and input
launcher/nbalauncher: ROM set detection, boot snapshot rebuild, Zig build of the game library
assets/boot/the boot snapshot recipe and entry register state
tests/smoke test and I/O ASIC replay test
tools/mame/, tools/bios/, tools/glide/, tools/recipe/research and data tools
docs/technical notes

Documentation

Legal

This project is not affiliated with or endorsed by Midway, Warner Bros., the NBA or NBC. NBA Showtime and all related names are trademarks of their respective owners. The repository contains no ROM data, disk images or recompiled game code. Use it only with a ROM set you own.