crash_bash_decomp

crash_bash_decomp is a native PC port and decompilation of Crash Bash for PlayStation that supports higher resolutions and frame rates.

README

crash_bash_decomp

Crash Bash (USA, SCUS_945.70) for the PlayStation, decompiled to C. It gives you two things:

  • A native port: a 64-bit game for Windows, Linux and Android, with widescreen, mods, extra heroes and online play. Not an emulator.
  • A matching decomp: C that rebuilds the retail disc byte for byte.

You need your own copy of the game for either. None of its files are included.

Native port

  1. Download the zip for Windows or the .tar.gz for Linux from the latest release and unpack it.
  2. Put the disc image of your legal copy of Crash Bash (USA) (a .cue with its .bin, a raw .bin or an .iso) next to crashbash.exe (crashbash on Linux), or copy CRASHBSH.DAT from the CRASHBSH folder on it there.
  3. Run crashbash.exe (crashbash on Linux).

On Android, install the .apk from the same release, and the first time it asks for your disc image (the .bin, or an .iso). It has on-screen touch buttons, or takes a controller.

FeatureDetails
Game modesAll of them: Adventure, Battle and Tournament
ResolutionAny window size and render resolution
FullscreenOr a window, whichever you like
VsyncOn or off
Frame rate30, 60 or 120 FPS
WidescreenShows more of the world, with extra scenery where needed
Anti-aliasing2x, 4x or 8x
FilteringSmooth textures, or the original's square texels
UpscalingTextures at 2x or 4x
IconsCrisp hero and boss pictures, or the original's
ModsTextures, game files and patches from zips, on a Mods page
Extra heroesRipper Roo and Pinstripe, from your own Crash Bandicoot (USA), in every game
Online playUp to four players on their own machines, with no servers: by your network, a join code or a virtual network
ControllersUp to four players on one machine, with a screen to put the controllers in order; analog sticks, with a deadzone of your choosing, and rumble, or the keyboard; every key and button can be changed; the menus work with the mouse too
TouchOn Android, faint buttons over the picture, or a controller
SavesKept in a file, with no memory card to set up
Quick startSkip the logos and the loading screens
Cheat menuThe original's hidden cheats, in the pause menu

It needs 64-bit Windows 10 or 11 and Direct3D 12, 64-bit Linux with glibc 2.34 or newer (Ubuntu 22.04, Debian 12, Fedora 35 and later) and Vulkan, or Android 8.0 or newer with Vulkan. The Linux version hasn't been played on a real Linux PC with a graphics card yet, only in software. There's no Mac version. Only the USA version's data is supported. Playing with several controllers at once, and online play between two homes, haven't been tested by people yet.

Playing online

ONLINE, in the menu the game opens with, has HOST GAME and JOIN GAME. Everyone needs the same version and their own copy of the game.

  • On the same network, a hosted game shows up in JOIN GAME by itself.
  • Anywhere else, the game asks the host's router to open a port (UPnP or NAT-PMP), and the host's screen shows an eight-character join code for the others to type in.
  • Where that can't work, as on a phone's hotspot or with UPnP turned off, everyone can join the same virtual network (Hamachi, Radmin VPN, ZeroTier or Tailscale). The host's screen shows the address to join at there.

Every machine runs the whole game and only the button presses travel, so nothing goes through a server. Each player has a small tag over their picture, its dot green, orange or red with their connection, and the sound and picture settings stay each player's own. The release's README.txt says more, and docs/PORT.md (Online play) has how it works.

Build the port yourself

You need CMake, Ninja and llvm-mingw on your PATH.

git clone https://github.com/jake-r-r-w/crash_bash_decomp.git
cd crash_bash_decomp/port
cmake --preset windows-clang -DBASH_FETCH_SDL3=ON
cmake --build --preset windows-clang

That makes build/port/windows-clang/crashbash.exe. Configuring it downloads miniupnpc and libnatpmp, which online play uses, at one version each checked by hash (and SDL3, with -DBASH_FETCH_SDL3=ON). More in docs/PORT.md.

On Linux it's the same with the linux-clang preset, which makes build/port/linux-clang/crashbash: it needs Clang, CMake, Ninja, zlib's headers and SDL3's build dependencies, and Vulkan to run. Or build it in Docker with tools/dl (docs/PORT.md, Linux).

Android's .apk builds in Docker too: tools/da sh port/android/build.sh (docs/PORT.md, Android).

PS1 decomp (disk 2 disk)

You need Docker (running) and git. On Windows, use Git Bash, or tools\dk.ps1 in PowerShell.

  1. Clone the repo as above, then make a disc folder in it and put your Crash Bash (USA) .bin and .cue in there.

  2. Add PsyQ, Sony's SDK (this downloads and checks it):

    tools/get_psyq.sh
    
  3. Build it (the first time takes about 10 minutes):

    tools/dk make disc
    

build/CrashBash.cue is your rebuilt game, for any PlayStation emulator. tools/dk make disc-check checks it equals retail.

To keep game files out of your commits: git config core.hooksPath tools/hooks.

Docs

DocWhat's in it
PORT.mdThe port: its design, building, running and testing it, and online play
MODDING.mdMaking mods for the port
EXTRA_HEROES.mdThe port's extra heroes, and adding one
ARCHITECTURE.mdHow the game works
PLAYING.mdPlaying a disc build, editing the game data
ASSETS.mdThe game's file formats
MATCHING.mdHow functions were matched
PROTOTYPES.mdWhat the prototype and demo discs gave
ROADMAP-B.mdWhat's left (ROADMAP-A.md: what's done)
CONTRIBUTING.mdThe rules for changes

Notice

A preservation and research project, not affiliated with or endorsed by Eurocom, Sony Interactive Entertainment or Activision. Crash Bash and Crash Bandicoot are trademarks of their owners.

No game files, Sony SDK files or compilers are included. The only text from the game's own files is four headers recovered from its archive (include/bash/arkenoid.h, pogo.h, polar.h, tank.h). Issues and pull requests with game or SDK files, or links to them, are refused.

Credits

The decomp: splat, maspsx, old-gcc, m2c, decomp-permuter, objdiff, mkpsxiso, GCC and binutils, the converted PsyQ 4.7 libraries (psx.arthus.net), CTR-tools, Pillow, RetroArch and PCSX ReARMed.

The port: SDL3, zlib, miniupnpc and libnatpmp, LLVM and Clang (and its libFuzzer), llvm-mingw, CMake, Ninja, Node.js, the Android SDK and NDK, and Mesa's software Vulkan for testing on Linux.

Written with Claude by Anthropic. And Eurocom, who made Crash Bash.

License

The project's own tooling, PC port code, build files and docs are MIT (LICENSE). src/, include/ and port/game/ reconstruct the game and belong to its owners: nothing here grants any right to the game. tools/reference/ (GCC's source) and tools/cc1/patches/ are GPL.