RE9500 - Resident Evil for the Nokia 9500 / 9300 (Series 80 v2.0)
Version 1.0, 2026-11-22. Package UID 0x01000A26.

Capcom's Resident Evil, the 1997 PC version, on the Nokia 9500 Communicator: the game with its
voices, sound effects, music and movies, on a 150 MHz ARM9 with no floating point. It is built
from the ecruells/resident-evil-pc-decomp decompilation.

Port: Sami Vuori, written together with Claude (Anthropic).


YOU NEED
  Your own copy of Resident Evil for PC. The game's data is not included and never will be.
  Tested with the 1997 US CD. The GOG release should have the same files, but is untested;
  the Japanese Biohazard hasn't been tried.
  A Windows 10 or 11 PC to prepare the data, and 320 to 470 MB free on the memory card.


INSTALL
  1. On the PC, run prepare.bat from the pc folder with your game:

       pc\prepare.bat E:\

     where E:\ is the CD's drive, or the folder your copy keeps the game's USA folder in. It
     makes a folder RE9500 next to prepare.bat, and doesn't change your game's own files:
       USA\...        the game's data without the MOVIE, SOUND and VOICE folders, 170 MB
       USA\SOUND.PAK  all 1110 sounds and voices in one file, 53 MB (made by sndpack.exe)
       USA\MOVIE      the movies. With Python 3 and ffmpeg installed they are shrunk to 95 MB
                      (shrink.py, about a quarter of an hour); without them the originals go
                      in as they are, 245 MB. Both play the same.
       background.bmp the picture around the game's on the wide screen (see IN THE GAME)
  2. Copy that RE9500 folder to the memory card's root, so that the card has
     \RE9500\USA\DATA\FONTUS.TIM.
  3. Install RE9500.sis to the memory card. It puts re9500.rbl, the game's code, in \RE9500\.
  4. Start RE9500 from the Desk.

  To save room, the endings and the staff roll can go: USA\MOVIE\ED*, EU*, STAF_R and STF*_R.
  A movie that isn't there is skipped.

  Without prepare.bat: copy the game's HORR\USA folder to \RE9500\USA on the card, leaving out
  MOVIE, SOUND and VOICE. Make the pack with "sndpack <the game's USA folder> SOUND.PAK" and put
  it in \RE9500\USA. Copy MOVIE there as it is, or shrink it first with
  "python shrink.py <the game's MOVIE folder> <out folder>".

  If nothing shows, look in re9500log.txt, in the folder that has re9500.rbl. Its first lines say
  where the game looked for its data. The game takes 6 to 12 MB of memory from what the phone has
  free: close other applications if the log's "heap:" line says under about 10 MB.


IN THE GAME
  A opens OPTIONS:
    SOUND        music and sound volumes, 0 to 100%. They are kept in \RE9500\config.ini, under
                 [Sound] as MusicVolume and SoundVolume
    SAVE GAME    save anywhere, in 16 slots, with no ink ribbon. These are the typewriter's own
                 files, \RE9500\SAVE\savedat1.dat to savedat16.dat, so either way sees the other's
                 saves. A load starts the room afresh, so save in free play rather than in the
                 middle of a cutscene
    LOAD GAME    the same slots, from anywhere in the game
    DISPLAY, INPUT, BACK TO TITLE: the decompilation's own (INPUT sets the keys)
  The title screen's LOAD GAME loads the same saves.

  Frame skip: when a scene takes longer than the game's 33 ms tick to draw, the ticks already due
  are worked out without being drawn, so the game keeps its speed and the voices stay with the
  people saying them. Busy scenes draw about 10 frames a second. To have them slow down instead,
  put FrameSkip=0 under [Display] in \RE9500\config.ini.

  Background: background.bmp in \RE9500\ fills the screen around the game's picture. The one in
  the pc folder, which prepare.bat puts there, was made by Sami with ChatGPT. Delete it for black
  borders, or put your own in its place: 640x200 fits exactly, other sizes are stretched;
  uncompressed 24-bit, 32-bit, 256-colour or 16-colour BMP, what Paint saves. prepare.bat
  doesn't copy over one that is already there.


KEYS
  Arrows, rocker                     move
  Rocker middle, Enter, Space, C     act, confirm
  X                                  aim
  V, Ctrl                            run, cancel
  Z                                  status screen: items, map, files
  A                                  options
  Chr+Q                              quit
  The keys are the game's own defaults, and OPTIONS - INPUT can change them.


KNOWN ISSUES
  - I haven't played it through. What I have played works, and an emulator walked all seven
    stages with random keys, 108 room loads without a fault, but that is not a playthrough.
  - Busy scenes draw about 10 frames a second.
  - The title screen has no OPTIONS entry: it needs a font file made by the decompilation's own
    tools. A in the game has everything.
  - Once, the phone's sound stopped for good in the middle of a session, its audio thread stuck in
    the media server, and the phone restarted on quitting. The game now carries on without sound
    if that happens. Quit and start it again to get the sound back, and if that doesn't help,
    restart the phone.
  - Tested on a Nokia 9500 only.


SOURCE
  game\src\        The decompilation (commit 0173055) with RE9500's changes. tools\port1.py and
                   tools\port2.py made the first of them; the rest are in the files, mostly
                   under #ifdef RE9500. The phone's side is game\src\platform\epoc:
                     main.cpp            the main loop, frame limiter and frame skip
                     marni_sw.cpp        a software renderer in place of Direct3D
                     tmd_fixed.inc       the 3D path in integers
                     audio.cpp           the mixer, and the watchdog for a stopped stream
                     soundpack.cpp       reads SOUND.PAK
                     movie.cpp, video.cpp  Cinepak AVIs, with IMA ADPCM or PCM sound
                     background.cpp      background.bmp
                     platform.cpp, runtime.cpp, crt.S  the C library's floor and the start-up
                     hostapi.h           the table of the phone's services the stub hands over
  game\blob.ld     The linker script for the blob.
  RE9500\          re9500.exe, the stub, built by the SDK: stub.cpp, epocaudio.cpp (the audio
                   thread), epocpace.cpp (keeps 140 ms of sound queued). Build files in epoc\.
  GameLauncher\    RE9500.app, which puts RE9500 on the Desk, starts re9500.exe and quits.
  pc\prepare.bat   The data preparation above.
  tools\           build_game.sh (the blob), mkblob.py (ELF to blob), make_game_project.py,
                   make_icons.py, make_release.py, armemu\ (an ARMv4 emulator that runs the blob
                   on the PC as strictly as the phone), sndpack\, movie\ (shrink.py and
                   movietest), pacesim\ (the audio pacing against model streams), crashdump.py,
                   pngdiff.py, port1.py, port2.py.
  notes.txt        The development notes: what was tried, measured and fixed, with the numbers.
  background.bmp   The picture around the game's, made with ChatGPT. prepare.bat finds it here
                   too, one folder up from itself.

  The unmodified decompilation is not in the source zip: it is on GitHub,
  github.com/ecruells/resident-evil-pc-decomp, commit 0173055.


BUILD
  The game, on the PC, with Git Bash and Python 3:
    Arm GNU Toolchain 14.2.Rel1 for Windows, arm-none-eabi, unpacked to tools\dl\arm-gcc
    (so that tools\dl\arm-gcc\bin\arm-none-eabi-g++.exe exists). Then:
      sh tools/build_game.sh             game\re9500.rbl
      python tools/make_game_project.py  copies it and hostapi.h next to the stub, writes
                                         RE9500\epoc\RE9500.pkg
  The stub, the launcher and the SIS, on a Win2000 VM with the Series 80 v2.0 SDK: copy RE9500
  and GameLauncher to \RE9500\ on the SDK's drive, then
      cd \RE9500\RE9500\epoc
      bldmake bldfiles
      abld build armi urel
      cd \RE9500\GameLauncher
      bldmake bldfiles
      abld build armi urel
      cd \RE9500\RE9500\epoc
      makesis RE9500.pkg
  A new blob alone needs no VM: copy game\re9500.rbl to \RE9500\ on the card.

  The Desk icons: "python tools\make_icons.py --release" draws the ones in this release, a red
  "RE". "python tools\make_icons.py <the game's MOVIE\DM3.AVI>" cuts the zombie's face from the
  game's movie instead, for your own phone: it's the game's picture, so not for giving out.
  Build the launcher again after either.

  armemu:  gcc -O2 -o armemu.exe tools\armemu\armemu.c   (how to use it: the top of armemu.c)
  sndpack: gcc -O2 -s -o sndpack.exe tools\sndpack\sndpack.c


LICENCE
  GNU GPL v3, as the decompilation: see COPYING. The third-party code compiled into the game is
  listed with its licences in THIRD_PARTY_NOTICES.txt.
  Resident Evil and everything in it belong to Capcom. This port is not affiliated with or
  endorsed by Capcom, and no game data is included.


THANKS
  ecruells and everyone behind the Resident Evil decompilation, without which none of this would
  exist; Capcom for the game; the ffmpeg developers for a Cinepak encoder.
