Podcast Summary: Software Engineering Daily – "WipEout with Dominic Szablewski"
Release Date: December 11, 2024
In this engaging episode of Software Engineering Daily, host Joe Nash interviews Dominic Zablowski, an accomplished engineer, game developer, and hacker known for projects like Voidcall, QuakeVR, and Q1K3—a minimalist 13KB JavaScript version of Quake. Dominic discusses his ambitious project: a nearly complete rewrite of the classic 1995 PlayStation racing game WipEout, leveraging a leaked source code to recreate the game for modern platforms including Windows, Linux, macOS, and WebAssembly (WASM).
1. Dominic’s Game Development Journey
Dominic begins by sharing his early forays into game development, starting with writing games in Quick Basic on a 486 PC. [01:26] He highlights the challenges of developing games for Windows in the early days due to complex compiler setups, which led him to explore alternative platforms. Dominic pivoted to web development, creating an HTML5 game engine in response to Steve Jobs’ announcement about the iPhone dropping Flash support. This engine facilitated his creation of casual and original games, merging his interest in retro gaming with modern technologies.
Dominic Zablowski [02:14]: "I've been always interested in retro gaming too."
2. Introduction to WipEout
Joe Nash steers the conversation toward WipEout, a seminal futuristic racing game that captivated players with its fast-paced gameplay, distinctive art direction, and licensed electronic music. Dominic recounts his first encounter with the game as a child when his family briefly owned a PlayStation, making WipEout a staple in his gaming experiences. His fascination deepened upon discovering the PC version, despite its shortcomings compared to the original PlayStation release.
Dominic Zablowski [02:45]: "Wipeout was one of the most formative games I would say."
3. The Rewriting Project: Genesis and Motivation
Dominic explains that his journey to rewrite WipEout began with reverse-engineering the game's data formats during his youth. [05:56] In 2016, he developed a JavaScript renderer for WipEout assets, further solidifying his understanding of the game's structure. The catalyst for the rewrite project was the leak of WipEout's source code in 2022, which Dominic found under a legally gray area without an accompanying license. Despite uncertainties, he embarked on the project to make the game accessible on modern platforms.
Dominic Zablowski [07:27]: "It's a complete rewrite, none of the lines of code are where they were and everything is different."
4. Legal Considerations: Fair Use and Source Code Licensing
The discussion delves into the complexities of source code licensing. Dominic acknowledges that while the original source code was likely protected under copyright, his approach—rewriting the game from scratch without directly copying lines of code—could be argued as Fair Use. However, he admits that the resemblance to the original code places the project in a gray legal area.
Dominic Zablowski [07:27]: "It's kind of gray area, I guess."
Joe highlights practices like clean-room implementations, where one team describes the algorithm while another, unaware of the original code, implements it, to avoid copyright infringement.
5. Choosing C Over JavaScript for the Rewrite
Despite Dominic’s extensive background in web development and JavaScript, he opted to rewrite WipEout in C. [09:12] This choice was driven by his desire to engage with lower-level programming, which offers greater control and clarity over system operations compared to high-level languages like JavaScript, PHP, Kotlin, and Swift that dominate his professional work. Writing in C allows Dominic to enter a “Zen state,” focusing on intricate details and solving complex programming puzzles inherent to lower-level development.
Dominic Zablowski [09:12]: "With C, you really have to be careful what you do and that's kind of the appeal to me."
6. State of the Rewrite: Progress and Future Enhancements
As of the interview, Dominic’s WipEout rewrite is nearly complete, with the game being playable across multiple platforms. He notes that while the core functionalities are intact, minor details and physics bugs remain. Dominic expresses a lack of motivation to continue polishing the project unless approached by a major stakeholder like Sony, especially around the game’s anniversaries when remastering is popular.
Dominic Zablowski [10:24]: "It's pretty close to being done. There's still some minor details that are missing."
Potential enhancements include:
- Backporting mechanics from newer WipEout titles to improve collision responses.
- Graphical improvements, such as dynamic lighting and enhanced ship effects.
- Frame rate independence to fix physics inconsistencies.
7. Dealing with the Original Source Code: Challenges and Insights
Dominic critiques the leaked WipEout source code as “abysmal” due to its spaghetti-like structure, with numerous conditional compilations (ifdevs) scattered throughout. This disorganized codebase resulted from porting the game across multiple platforms and regions, leading to redundant and tangled code segments.
Dominic Zablowski [12:16]: "It's all over the place."
He contrasts the poor code quality with the game's successful and stable performance on the PlayStation, highlighting the paradox of functional software obscured by messy code.
8. Technical Deep Dive: NTSC vs. PAL and PlayStation Architecture
Dominic explains the technical differences between NTSC and PAL regions, primarily their frame rates (60Hz vs. 50Hz). This discrepancy posed significant challenges for game developers, who often resorted to hardcoding frame rates due to the hardware limitations of the time.
Dominic Zablowski [16:40]: "The main difference for Wipeout was that NTSC was 60 hertz and PAL is 50 hertz."
He elaborates on the absence of Z-buffering in PlayStation hardware, necessitating developers to render polygons in a back-to-front order manually. This limitation led to visual artifacts and meticulous rendering order management within the source code.
Dominic Zablowski [21:01]: "The PlayStation doesn't have a Z buffer."
9. Memory Management: Implementing a Bump Allocator
One of the standout aspects of Dominic's rewrite is his implementation of a bump allocator for memory management. This strategy involves preallocating a fixed block of memory and managing allocations in a linear fashion, resetting the pointer upon completing tasks or changing game scenes. This approach eliminates the need for dynamic memory allocation and deallocation, reducing complexity and the potential for memory leaks—crucial considerations given the constrained memory environment of the original PlayStation.
Dominic Zablowski [38:39]: "It's actually a pretty standard approach in a lot of game development that you have a bump allocator."
He further refines this by incorporating a temporary allocator for short-lived objects during tasks like loading race tracks, efficiently managing memory within a fixed 16MB space.
10. Architectural Refactoring: Modernizing the Renderer and Game Loop
Dominic details his efforts to modernize the game's architecture by abstracting platform-specific code and reworking the rendering pipeline. He moved away from the original PlayStation's ad-hoc rendering methods to implement a more flexible triangle function, allowing for the integration of various rendering backends like OpenGL, Metal, and WebGL.
Dominic Zablowski [26:12]: "I exchanged that. Like how it goes through the ordering table and gets it to the display."
Additionally, he restructured the game loop to accommodate modern environments like the web, where infinite loops are incompatible. Instead, he adapted the game to use requestAnimationFrame callbacks for rendering frames, ensuring compatibility with browsers and enabling WebAssembly compilation.
11. Implementation Across Platforms: STL2 and SoCalled
The rewrite supports multiple platforms through modular backend systems. Initially developed for STL2 on Linux with OpenGL, Dominic extended support to SoCalled, facilitating compilation to web platforms via Emscripten. This modularity allows users to swap renderers and platform backends seamlessly, enhancing the game's adaptability across diverse systems.
Dominic Zablowski [31:59]: "So-called is actually very cool... and I just have to switch out the compiler from the usual GCC to emscripten and it compiled the web version."
12. Future Plans and Community Engagement
Looking ahead, Dominic aims to address remaining physics bugs, enhance graphical features, and possibly collaborate with Sony for an official remaster. Beyond WipEout, he is involved in projects like rewriting Impact JS into C and developing a new C-based game engine, showcased in his game Bialab Disaster. He intends to open-source these projects, fostering community contributions and further innovations.
Dominic Zablowski [46:35]: "My dream would be to be paid to make a very polished version of that would be very cool if Sony says like, hey, Wipeout is the 38th anniversary."
13. Conclusion: Connecting with Dominic
Dominic encourages listeners to explore his work on GitHub under the handle Phobos Labs Everywhere, his blog, and Twitter. His projects offer valuable insights into low-level programming, game development, and innovative approaches to legacy game preservation.
Dominic Zablowski [48:42]: "Well, GitHub, the blog and Twitter mainly."
Joe Nash wraps up the episode by applauding Dominic's dedication and technical prowess, noting the potential impact of his WipEout rewrite on both gaming enthusiasts and software engineers.
Notable Quotes:
-
Dominic Zablowski [02:14]: "I've been always interested in retro gaming too."
-
Dominic Zablowski [07:27]: "It's kind of gray area, I guess."
-
Dominic Zablowski [09:12]: "With C, you really have to be careful what you do and that's kind of the appeal to me."
-
Dominic Zablowski [21:01]: "The PlayStation doesn't have a Z buffer."
-
Dominic Zablowski [38:39]: "It's actually a pretty standard approach in a lot of game development that you have a bump allocator."
Resources Mentioned:
- GitHub: Phobos Labs Everywhere
- Blog: Dominic's Blog (Exact URL to be included in show notes)
- Twitter: @PhobosLabs
- WipEout Rewrite on GitHub: WipEout Rewrite Repository
- Bialab Disaster: Play Bialab Disaster (Exact URL to be included in show notes)
This detailed summary encapsulates Dominic Zablowski's expertise and passion for game development, particularly in the realm of retro game preservation and modernization. His WipEout rewrite stands as a testament to the intersection of deep technical knowledge and nostalgic reverence, offering both a playable homage and a learning platform for aspiring developers.
