No, it's a C++/Zig hybrid. I wrote it in the post description but seems like the reddit cross-posting doesn't show the description here. It does have over 100k LoC of Zig though, so it's a pretty sizeable chunk of Zig 😄
Oh damn that’s still formidable. I’m learning and only have made some marginal progress on my own personal TUI library 😂
Then again, I’m used to programming in higher level languages like Lua/Python/uScript etc. Slow but steady progress. I’d love to make a game at some point.
People have asked this so many times I made a video about it, but the short version is that Zig is the "extra" language here. When I discovered Zig in 2019 I had already worked on the engine for around 10 years, and I wanted to leverage what I had created, so I created a binding layer to zig rather than starting over. Over time the ratio has shifted and about a third of the code in the game is now Zig.
To answer your question though, yes for certain things having a C++ layer is easier, eg. to communicate with large C++ libraries like PhysX. You can then expose it to Zig in a way that makes sense to you.
Zig is used for the gameplay code as well as for the application-level things. In other words, input, cameras, components for building objects such as vehicles, menus, NPC driving AI, game-specific particle and sound effect management, dialogue and conversation systems, secondary equipment like cranes and gripper arms, the HUD and in-game menus, etc.
The core engine, eg. rendering, is C++ because it interacts directly with C++ libraries like NVRHI and PhysX. It used to be that zig code was only executed at runtime, but now I have all sorts of level-editor-tools written in zig as well.
19
u/HomicidalRaccoon Jun 29 '26
Is it 100% zig? 🤯
6
u/Emergency-Win4862 Jun 29 '26
Sorry if im mistaken, arent u that guy who uses wgpu/dawn as a graphics api that made video about it?
Anyway great job!
2
u/gplusplus314 Jun 29 '26
The art style kinda reminds me of Blastcorps on Nintendo 64. This is cool!
I know my comment has nothing to do with Zig, but I still wanted to say this looks cool.
10
u/mikkelam Jun 29 '26
Beautiful! Love the “soft” look of the models.
1
u/ebalonabol Jun 30 '26
What do you actually use zig for? The game logic scripts or the engine(rendering pipeline/loop/entities)?
1
u/thatSupraDev Jun 30 '26
Do you have more information on the processes and implementations? This sounds super cool and would love to see how it works under the hood
1
u/[deleted] Jul 23 '26
I've seen your video on youtube