[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-108956":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":16,"forks30d":16,"starsTrendScore":16,"compositeScore":19,"rankGlobal":10,"rankLanguage":10,"license":20,"archived":21,"fork":21,"defaultBranch":22,"hasWiki":23,"hasPages":23,"topics":24,"createdAt":10,"pushedAt":30,"updatedAt":31,"readmeContent":32,"aiSummary":33,"trendingCount":16,"starSnapshotCount":16,"syncStatus":13,"lastSyncTime":34,"discoverSource":35},108956,"DarkSoulsPS2","nekomancer01\u002FDarkSoulsPS2","nekomancer01","Homebrew PS2 port of Dark Souls Remastered: C\u002FVU1 engine plus exporters that read your own copy of the game (no game data included)","",null,"C",106,2,1,4,0,6,39,48.33,"GNU General Public License v3.0",false,"main",true,[25,26,27,28,29],"decompilation","game","playstation-2","port","recompilation","2026-11-23 13:32:39","2026-11-21 02:03:08","\u003Cp align=\"center\">\u003Cimg src=\"docs\u002Flogo.png\" alt=\"Dark Souls PS2\" width=\"600\">\u003C\u002Fp>\n\nA homebrew port of **Dark Souls Remastered** to the PlayStation 2. It's a C engine for the PS2 (`ps2\u002Fproto`, built\nwith ps2dev and gsKit, with hand-written VU1 microprograms), plus Python tools (`tools\u002F`) that read **your own copy**\nof the PC game and convert its maps, characters, animations, collision, AI scripts and menus into PS2-sized files.\n\nYou build it yourself from your own copy of the game, and it runs in the PCSX2 emulator. Running it on a real PS2 is\nset up but hasn't been tested.\n\n> [!WARNING]\n> **This is a heavy work in progress.** It is an early prototype, not a playable game: only the first few areas load,\n> most of the game's systems are missing or partly done, and things change (and break) from one day to the next.\n> Expect bugs, crashes, missing sounds and visuals that don't match DSR yet. The in-browser converter on the project\n> page is especially experimental (see [Quick start](#quick-start)).\n\n## What works today\n\n| Works (partly, see `notes\u002FPLAYTHROUGH.md`) | Not yet |\n|---|---|\n| Firelink Shrine, Undead Burg and the Undead Asylum as one world, with seamless walking between them (no loading screen). Each area's scenery streams from the disc cell by cell, nearest first | Every other area; some scenery still pops in late when read from the disc |\n| The Warrior: walking, running, rolling, dashing, R1 attacks, falling | Lock-on, blocking, parries, magic, two-handing, levelling |\n| Enemies with their own AI scripts and navmesh routes, taking and dealing damage, ragdoll deaths | Line of sight, guarding, item drops, most enemy types |\n| Event scripts: chests, item pickups, fog walls, doors, levers and gates, event warps (the crow from the Asylum to Firelink), boss fog walls and health bar (tested on the Taurus Demon) | Boss fights as in DSR, NPC dialogue, shops, cutscenes |\n| Bonfires: lighting, resting (HP, Estus and enemies reset), kindling and Reverse Hollowing from the rest menu | Level up, attune and warp at bonfires |\n| Death: YOU DIED, the player turns Hollow and returns to the last bonfire, a bloodstain holds the lost souls and humanity | The Hollow look, a full area reload on death |\n| Souls and humanity from kills, humanity items, the HUD humanity counter (grey while Hollow) | Stats used by combat, rings and other SpEffects |\n| DSR's own Start menu screens: Equipment, Inventory (Use \u002F Discard), Status and System, with the game's item names, help text and icons. DSR's loading screen | Title screen, item pickup prompts, the other menus |\n| Saving and loading on the memory card | Saving in the background |\n| Sound effects, footsteps by floor, music, boss music and area ambience | Effects at a higher sample rate (8 kHz now), reverb, voices |\n| HUD (health, stamina, Estus, souls, humanity), 30 fps in PCSX2 | Testing on a real PS2 |\n\n### Screenshots\n\nThe port running in PCSX2:\n\n| Firelink Shrine bonfire | Firelink Shrine graveyard |\n|---|---|\n| ![The Warrior standing by the Firelink Shrine bonfire, with the HUD showing health, stamina and Estus Flasks](docs\u002Fscreenshots\u002Ffirelink-bonfire.jpg) | ![The Warrior in the Firelink Shrine graveyard among the gravestones](docs\u002Fscreenshots\u002Ffirelink-graveyard.jpg) |\n\n`notes\u002FPLAYTHROUGH.md` lists every system still needed for a full playthrough, with its status.\n`notes\u002FTECH_DEBT.md` lists every known way the port differs from the original game.\n\n## Legal note\n\nThis repository contains **no game data**: no textures, models, maps, sounds, text, scripts, params or executable\ncode from Dark Souls Remastered, and nothing derived from them, apart from the two screenshots above and the logo\nat the top (the Dark Souls logo recoloured, with \"PS2\" added). It contains no\ndecompiled code either. You need your own legally bought copy of Dark Souls Remastered for PC (Steam). The build\nreads that copy and writes every game-derived file into `build\u002F`, which is git-ignored. **Never share or commit\nanything in `build\u002F`.**\n\nDark Souls is a trademark of FromSoftware \u002F Bandai Namco. This project isn't affiliated with or endorsed by them.\n`notes\u002FEXE_FINDINGS.md` records only facts about the game's executable (addresses, offsets, field names, constants,\nformulas), each with its source.\n\n## Quick start\n\nThere are three ways to get a disc image (ISO) of the latest `main`. All of them read your own copy of the game, and\nthe ISO they make is yours only: never share it.\n\n| Way | What it takes | Notes |\n|---|---|---|\n| `.\u002Fbuild-iso.sh` in the repository root | A Linux shell; the steps below, or Docker \u002F Podman | The recommended way. One command exports the game data, builds the ELF and writes `build\u002Fproto.iso`. Without a ps2dev toolchain it pulls the official ps2dev image (`ps2dev\u002Fps2dev`) and builds in it with Docker \u002F Podman (`tools\u002Fbuild-iso.sh`). `.\u002Fbuild-iso.sh --help` lists the options |\n| The project page, https:\u002F\u002Fnekomancer01.github.io\u002FDarkSoulsPS2\u002F | A desktop browser (Chrome, Edge or Firefox) and plenty of memory | Converts your game folder into an ISO inside the browser tab; nothing is uploaded. **Very much a work in progress**, see below |\n| The full developer setup (steps 1 to 6 below) | Linux, ps2dev, Python, PCSX2 | For changing the code and running the tests |\n\n> [!CAUTION]\n> **The in-browser converter is a heavy work in progress.** It runs the port's own Python converter\n> (`tools\u002Fconvert.py`) in WebAssembly (Pyodide, with its C helpers built by `tools\u002Fnative\u002Fbuild-wasm.sh`) and packs the\n> game-free ELF from CI with `tools\u002Fiso9660.py`. It is slow (about 10 to 20 minutes), each worker needs up to about\n> 2.5 GB of memory and can fail on PCs with less, the ISO it makes has **no sound yet** (the game's MP3 sound banks\n> can't be decoded in the browser), and it may lag behind or break when the native build changes. If it fails or\n> the result misbehaves, use `.\u002Fbuild-iso.sh` instead and please report what happened.\n\nTested on Linux. The steps assume a Linux shell; Windows users should use WSL or a Linux VM.\n\n### 1. What you need\n\n| Need | Notes |\n|---|---|\n| Dark Souls Remastered, Steam PC version | Build 10943698 with English data is the one that's checked. `python3 tools\u002Fverify_game.py` lists supported versions. |\n| ps2dev toolchain with gsKit | Get a ps2dev release from https:\u002F\u002Fgithub.com\u002Fps2dev\u002Fps2dev. `ps2\u002Fenv.sh` looks for it in `~\u002Ftools\u002Fps2dev-2.0.0\u002Fps2dev`; set `PS2DEV=\u002Fyour\u002Fpath` if it's elsewhere. |\n| Python 3.10 or newer | The tools need Pillow and numpy (step 3). |\n| gcc, g++ | Compile a few small native helpers on first use (g++: meshoptimizer's simplifier for the far horizon level). |\n| libmpg123 | Decodes the game's MP3 sound banks for the sound packs (Debian\u002FUbuntu `libmpg123-0`, Fedora\u002FArch `mpg123`). |\n| PCSX2 2.x | The Flatpak `net.pcsx2.PCSX2` is what the run scripts use. |\n| RAM | The first full export needs several GB. |\n\n### 2. Tell the build where your game is\n\nThe game folder is the one that holds `DarkSoulsRemastered.exe`. Usually you don't need to do anything:\n`tools\u002Fgamepath.py` searches the usual Steam libraries (native, Flatpak and Snap Steam, and every library in\n`libraryfolders.vdf`). If yours is somewhere else, use one of these:\n\n```bash\nexport DSR_GAME=\"$HOME\u002F.local\u002Fshare\u002FSteam\u002Fsteamapps\u002Fcommon\u002FDARK SOULS REMASTERED\"\n```\n\nor put `DSR_GAME = \u002Fpath\u002Fto\u002FDARK SOULS REMASTERED` in `config.local.mk` at the repo root (git-ignored), or pass\n`make DSR_GAME=...`.\n\nThen check your copy:\n\n```bash\npython3 tools\u002Fverify_game.py\n```\n\nIt hashes the exe and the data files the exporters need. An unknown version stops the build with a message;\n`DSR_ALLOW_UNSUPPORTED=1` builds anyway, for trying a newer patch.\n\n### 3. Install the Python packages\n\n```bash\npython3 -m venv .venv && .venv\u002Fbin\u002Fpip install -r tools\u002Frequirements.txt\n```\n\nThe build uses `.venv` automatically. To use a different Python, put `PY = \u002Fpath\u002Fto\u002Fpython` in `config.local.mk`.\n\n### 4. Turn on HostFs in PCSX2\n\nThe game loads its files from your disk through PCSX2's `host:` device. In PCSX2's `PCSX2.ini` (Flatpak:\n`~\u002F.var\u002Fapp\u002Fnet.pcsx2.PCSX2\u002Fconfig\u002FPCSX2\u002Finis\u002FPCSX2.ini`), set:\n\n```ini\n[EmuCore]\nHostFs = true\n```\n\nYou can skip this if you only play the ISO build (step 6).\n\n### 5. Build\n\n```bash\nsource ps2\u002Fenv.sh\nmake -C ps2\u002Fproto\n```\n\nThe first build converts the game data. It takes several minutes and several GB of RAM. Later builds only redo what\nchanged. `make` uses every CPU core by default; `make -j4` (or `JOBS=4`) limits it. The result is `build\u002Fproto.elf`, which starts at the Firelink Shrine bonfire.\n\n### 6. Play\n\n```bash\ntools\u002Fpcsx2-run.sh build\u002Fproto.elf\n```\n\nOr build a disc image and open it in PCSX2 like any game (HostFs isn't needed for this):\n\n```bash\nmake -C ps2\u002Fproto iso      # writes build\u002Fproto.iso\n```\n\n`.\u002Fbuild-iso.sh` in the repository root does steps 5 and 6 in one command: it exports the game data, builds the ELF\nand writes `build\u002Fproto.iso`. `-i DIR` picks the game folder, `-o FILE` also copies the ISO elsewhere, `-c N` sets\nhow many CPU threads it uses; `--help` lists every option. Without a ps2dev toolchain on the host it pulls the official\nps2dev image (`ps2dev\u002Fps2dev:v2.0.0`) and builds in a container on it with Docker or Podman (`tools\u002Fbuild-iso.sh`).\n\nTo report a problem, play with `.\u002Fplay-report.sh` instead of opening the ISO yourself. It starts PCSX2 with\n`build\u002Fproto.iso` and your own settings and memory cards, records PCSX2's log with the game's, and takes a screenshot of\nthe window every 2 seconds. Type a note in its terminal and press Enter to mark the moment something goes wrong (it also\nsaves a savestate there). When you close PCSX2 it writes one zip to `build\u002Fplay-reports\u002F` (a summary, the log, the\nscreenshots, your marks): attach that file to the report. `--help` lists the options. It needs `python3`, and for the\nscreenshots ImageMagick and `xprop`.\n\n### Controls (DualShock 2)\n\n| Button | Action |\n|---|---|\n| Left stick or d-pad | Move (a light tilt walks) |\n| Right stick | Camera |\n| Circle | Tap to roll, hold to dash |\n| R1 | Attack |\n| Cross | Action: open chests, pick up items, go through fog walls |\n| Start | Menu |\n| Select | Debug HUD (fps, timings, free memory) |\n| L3 | Debug: helmet off \u002F on |\n\nThe player is always under your control. The old idle demo walk is kept for testing only: build with\n`make EE_DBGINFOFLAGS=-DIDLE_DEMO` (or put `option demo` in a test script) and it starts after 5 seconds without input;\npress any button to take over.\n\n## Troubleshooting\n\n| Problem | Cause and fix |\n|---|---|\n| `make` stops at once with a message about the game | It can't find your game folder, or the version isn't supported. See step 2. |\n| PCSX2 shows a black screen or loads nothing | HostFs is off (step 4), or you started PCSX2 yourself without the run script. Use `tools\u002Fpcsx2-run.sh`. |\n| The picture goes black while the game keeps running | Video memory ran out. PCSX2's log (`emulog.txt`) says `ERROR: Not enough VRAM`. Please report it with the spot. |\n| `OUT OF RAM: ...` in the PCSX2 log | The PS2 has 32 MB of RAM and the port runs close to it. Please report it with the spot. |\n| The build is killed or the PC slows down | The export needs a lot of RAM. Close other programs and run it again; heavy jobs go through `tools\u002Fq`, which waits for free RAM. |\n\nFor a report, `.\u002Fplay-report.sh` collects all of this for you (see step 6). The PCSX2 log is `emulog.txt` in PCSX2's `logs` folder (Flatpak: `~\u002F.var\u002Fapp\u002Fnet.pcsx2.PCSX2\u002Fconfig\u002FPCSX2\u002Flogs\u002F`).\n\n## More build options\n\n```bash\nmake -C ps2\u002Fproto MAP=m10_01_00_00   # start in Undead Burg: build\u002Fproto_m10_01_00_00.elf\nmake -C ps2\u002Fproto clean              # remove compiled code only\nmake -C ps2\u002Fproto distclean          # also remove everything exported from the game\ntools\u002Fpcsx2-run.sh build\u002Fproto.elf 8 shot.png   # headless test: run 8 s, save a screenshot\ntools\u002Ftest-all.sh                    # full test suite: builds, smoke tests, render and perf checks\n```\n\n`build\u002F` holds `gen\u002F` (exported data and generated headers), `obj\u002F`, `data\u002F` (the compressed packs the game loads)\nand the `proto*.elf` files. `ps2\u002Fproto\u002Fproto.elf` and `ps2\u002Fproto\u002Fdata` are links into `build\u002F`.\n\n## Where to read next\n\n| If you want to… | Read |\n|---|---|\n| See what's missing before the whole game plays | `notes\u002FPLAYTHROUGH.md` |\n| See the plan by priority | `notes\u002FROADMAP.md` |\n| Know how the port differs from the original | `notes\u002FTECH_DEBT.md` |\n| Find a tool or script | `notes\u002FTOOLS.md` |\n| Understand file formats and engine decisions | `notes\u002FPORTING.md` |\n| Look up values found in the game's exe | `notes\u002FEXE_FINDINGS.md` |\n| Contribute (people and AI agents) | `AGENTS.md` |\n\n## Repository layout\n\n| Path | What |\n|---|---|\n| `ps2\u002Fproto\u002F` | The PS2 engine (C99; the VU1 `.vsm` programs are generated by `tools\u002Fvu1\u002Fgen.py`) |\n| `tools\u002F` | Exporters (`export_*.py`), file readers (`souls.py`, `havok_*.py`, `esd.py`, `lua50.py`), test and reference tools |\n| `config.mk`, `tools\u002Fgamepath.py`, `tools\u002Fverify_game.py` | Finding and checking your game folder |\n| `ghidra\u002Fscripts\u002F`, `fndb\u002F` | Scripts for studying the game's exe (no exe data included) |\n| `notes\u002F` | Design notes, plans and status |\n| `AGENTS.md` | Rules for contributors, people and AI agents alike (the legal rules are in section 1) |\n\n## Optional development dependencies\n\nYou don't need these to build or play. Some cross-check and research tools use them. Fetch them yourself into `ext\u002F`\nor `tools\u002Fext\u002F` (git-ignored), and check each project's licence before sharing anything built with them.\n\n| Dependency | Used by | Licence |\n|---|---|---|\n| soulstruct 2.3.2, soulstruct-havok 1.2.2 (PyPI) + data files from the soulstruct git repo (`ext\u002Fsoulstruct`) | `tools\u002Fxcheck.py` etc. (format cross-checks) | GPL-3.0-or-later |\n| SoulsFormatsNEXT, DSAnimStudio (`ext\u002F`) | Reference for file layouts | GPL-3.0 |\n| Paramdex, DarkScript3 (`ext\u002F`) | Param \u002F EMEVD names | See upstream |\n| meshoptimizer (`tools\u002Fext\u002F`) | Mesh experiments | MIT |\n| lz4, lz4ultra (`tools\u002Fext\u002F`) | Compressor experiments | BSD-2 (lib) \u002F zlib |\n| libimagequant (`tools\u002Fext\u002F`) | Palette quantisation experiments | GPL-3.0-or-later or commercial |\n| Node.js 18+, clang + wasm-ld (LLVM 17+); pyodide (npm, fetched into `build\u002Fcache\u002Fpyodide-node` on first use) | `tools\u002Fpages\u002Fconvert-node.mjs` (the in-browser converter run outside a browser, to compare its packs with a native build) | Node: MIT; Pyodide: MPL-2.0 |\n| vgmstream (`tools\u002Fext\u002F`) | Audio experiments | ISC-style |\n| PCSX2 source (`tools\u002Fext\u002Fpcsx2-src`) | Emulator debugging | GPL-3.0 |\n| Ghidra | Exe research (`ghidra\u002Fscripts`) | Apache-2.0 |\n\nThe name and layout references are read from fixed paths under `ext\u002F` (or the environment variable, if set). Without\nthem the tools still run: param rows keep their Japanese names, TAE events stay raw words, and EMEVD instructions keep\ntheir Japanese names (106 instruction uses that DSR's own `common.emedf` lacks don't decode). To fetch them:\n\n```sh\ngit clone --depth 1 https:\u002F\u002Fgithub.com\u002Fsoulsmods\u002FParamdex ext\u002FParamdex          # tools\u002Fparams.py: DS1R\u002FNames, DS1R\u002FDefs ($PARAMDEX)\ngit clone --depth 1 https:\u002F\u002Fgithub.com\u002FAinTunez\u002FDarkScript3 ext\u002FDarkScript3     # tools\u002Femevd.py: DarkScript3\u002FResources\u002Fds1-common.emedf.json ($DARKSCRIPT3)\ngit clone --depth 1 https:\u002F\u002Fgithub.com\u002FMeowmaritus\u002FDSAnimStudio ext\u002FDSAnimStudio # souls.tae_template, xcheck.py tae: DSAnimStudioNETCore\u002FRes\u002FTAE.Template.DS1*.xml\n```\n\n`tools\u002Fxcheck.py` also needs soulstruct in `.venv-tools`: the install steps are at the top of\n`tools\u002Frequirements-xcheck.txt` (the PyPI wheel lacks soulstruct's data files, so they come from a clone in\n`ext\u002Fsoulstruct`). Checked 2026-11-01 against Paramdex ff7245e, DarkScript3 733f024, DSAnimStudio f1bff06.\n\n`tools\u002Fnative\u002Fbcdec.h` (BC texture decoder, MIT \u002F Unlicense) is included with its licence header.\n`tools\u002Fnative\u002Fmeshopt\u002F` holds meshoptimizer 1.3's simplifier (https:\u002F\u002Fgithub.com\u002Fzeux\u002Fmeshoptimizer, MIT, `LICENSE.md`\nbeside it), used by `tools\u002Fhorizon.py`; built into `tools\u002Fnative\u002Flibmeshopt.so` on first use.\n\n## Licence\n\nGPL-3.0-or-later (`LICENSE`). It covers only the original code and docs in this repository. No game files are\nincluded, and it grants no rights to FromSoftware \u002F Bandai Namco material. You need your own copy of Dark Souls\nRemastered.\n","这是一个将《黑暗之魂：重制版》移植到PlayStation 2平台的自制开源项目，基于C语言开发PS2原生引擎（含手写VU1微程序），并提供Python工具链，用于从用户本地PC版游戏文件中提取并转换地图、角色、动画、碰撞、AI脚本等资源为PS2兼容格式。项目依赖ps2dev和gsKit构建，仅支持在PCSX2模拟器中运行，尚未实机测试；当前为早期原型，仅部分区域与基础玩法可运行。适用于游戏逆向研究、主机移植技术学习及PS2平台复古开发实验场景。","2026-11-24 04:35:25","CREATED_QUERY"]