Case study
re-plants-vs-zombies: decompiling and modernizing Plants vs. Zombies GOTY
Reconstructs C++ source for Plants vs. Zombies on PopCap’s open-source SexyAppFramework, starting from an earlier community decompilation of version 0.9.9 and adding functionality reversed from the Game of the Year edition, with functions annotated by GOTY addresses. The project also modernizes the engine with current C++ and is replacing the DirectDraw and Direct3D 7 renderers with GLFW. It builds a fan executable that runs from an original game folder, aiming at a modernized, extensible game rather than an identical binary.
- Targets
- Game
- Category
- Independent reconstruction cases
- Relationship
- Independent reconstruction project
- Sources reviewed
Requirements & limits
- README describes decompiling the latest functionality of the first PvZ title and expanding the game and its engine, building on a since-deleted 0.9.9 decompilation by Miya (rspforhp) that it credits ruslan831 with archiving. Its roadmap marks x64 support and achievements as partial, the GLFW renderer and cross-platform replacements as in progress, and Zombatar and a modding API as not done. There are no releases; the last commit is dated 2026-07-11.
- Playing needs the original game files from a purchased copy; README links the Steam Game of the Year Edition but names no exact executable version. The built executable is run from that game folder, and the audio code loads bass.dll or fmod.dll at runtime instead of linking a committed copy. README says the repository includes no PopCap IP beyond the open-source engine; Resources.cpp/.h reconstruct the game’s generated resource-ID tables, data derived from the game as is usual for such projects.
- Builds use CMake 3.16+ and C++23. README documents Visual Studio Community, whose CMakeSettings.json has x86 and x64 MSVC configurations, or CMake with Ninja; toolchain.cmake cross-compiles with x86_64-w64-mingw32 Clang and windres. The reviewed build produces a Windows executable, and the repository has no CI workflow.
- The sources document no tests, CI or comparison with the original executable; contributors annotate reversed functions and class members with their GOTY addresses. Fidelity to the original game is not measured.
- LICENSE dedicates the repository under CC0 1.0. The SexyAppFramework code derives from the engine PopCap made public, but PopCap’s license text is not included; the ogg code keeps Xiph.org’s BSD-style notice, and the FMOD 3 (Firelight, 1999–2002) and BASS 2.4 (Un4seen, 1999–2022) API headers keep their vendors’ copyrights. The original game and its files keep their rights holders’ terms. README says the project does not condone piracy.
About this entry
The description was reviewed against primary sources.
Primary sources
- README.md GitHub · Patoke/re-plants-vs-zombies · Revision c469203
- CMakeLists.txt GitHub · Patoke/re-plants-vs-zombies · Revision c469203
- SexyAppFramework/CMakeLists.txt GitHub · Patoke/re-plants-vs-zombies · Revision c469203
- CMakeSettings.json GitHub · Patoke/re-plants-vs-zombies · Revision c469203
- toolchain.cmake GitHub · Patoke/re-plants-vs-zombies · Revision c469203
- LawnApp.cpp GitHub · Patoke/re-plants-vs-zombies · Revision c469203
- Resources.cpp GitHub · Patoke/re-plants-vs-zombies · Revision c469203
- SexyAppFramework/sound/BassLoader.cpp GitHub · Patoke/re-plants-vs-zombies · Revision c469203
- SexyAppFramework/sound/fmod.h GitHub · Patoke/re-plants-vs-zombies · Revision c469203
- SexyAppFramework/sound/bass.h GitHub · Patoke/re-plants-vs-zombies · Revision c469203
- SexyAppFramework/ogg/COPYING GitHub · Patoke/re-plants-vs-zombies · Revision c469203
- LICENSE GitHub · Patoke/re-plants-vs-zombies · Revision c469203
More in Games
- REDRIVER2: reconstructing Driver 2 through a PlayStation compatibility layer · Case study
- RSDKv3 Decompilation: Sonic CD (2011) on a reconstructed Retro Engine v3 · Case study
- RSDKv4 Decompilation: Retro Engine v4 and the Sonic 1 & 2 (2013) menus · Case study
- RSDKv5 Decompilation: reconstructing Retro Engine v5 and v5U · Case study
- Sonic Mania: a game-code decompilation for the RSDKv5 engine · Case study
- SpaceCadetPinball: decompiled game logic adapted to SDL2 · Case study