The world of Veloren is rife with friends, foes, and voxels! It's a community-developed multiplayer RPG built with Rust. According to “The Book,” it draws inspiration "from Cube World, Legend of Zelda: Breath of the Wild, Dwarf Fortress and Minecraft."
We want to turn Veloren into a shining example of what Rust can do in the game development space.
This user, the alter ego of Joshua Barretto, founder of Veloren, also mentioned that the game was undergoing a rewrite “to move to a multi-threaded ECS architecture.” Said rewrite has since been completed and Veloren is the shining example, not only of what Rust can do, but also of what multi-threaded ECS architecture can do. I am a proponent of the emerging multi-threaded entity-component-system paradigm. I maintain packages demonstrating its supremacy over the traditional object-oriented approach, albeit with Unity and C#. Not only that, but I'm using these ECS-based packages to build a game!
That is to say the Veloren developers and I must be peas from the same pod.
An Extended Aside on ECS
If you're wondering what makes up-and-coming ECS paradigms so great, and how this makes Veloren great, then ask yourself this: What do you lose with the object-oriented approach?
You lose a great deal of processing to garbage collection, which is notoriously rough in games and simulations as opposed to other software applications. That is because it often causes terrible frame stuttering. To avoid this outcome, the object-oriented programmer must then incorporate what I call hacks, because they prevent language features from operating as intended. One such example is object pooling, where the main thrust of its purpose is in pre-instantiating a set number of objects on initialization (which are not used until the game logic calls for them).
You gotta do what you gotta do, but if the right tools for the job are on your doorstep, then why not bring them into the house?
Rust, for instance, has an affine type system, meaning that it knows when memory must be freed at compile-time, which is the software analogue to a philosopher's a priori knowledge. I stress compile-time rather than runtime, because determining which memory can be freed is a given—there is no intensive deliberation to ascertain what garbage need be collected periodically, nor incrementally. So does that mean Rust is ideal for games, and for Veloren?
Yep, and here are other tools ideal for games, especially runtime-heavy games common to the management and RTS genres:
- Low-level APIs that run Veloren, such as SPECS for ECS
- Unity DOTS which combines ECS, work-stealing jobs and the Burst compiler
- Game engines such as Amethyst (which switched from SPECS to Legion—we'll see how that works out)
There is a critical mass of game developers achieving wonderful things with these tools. Much of the apprehension regarding these tools is a rejection of a new pollution, but in truth an imagined one. The new pollution is in fact object-oriented spaghetti code.
Yet the key ingredient to Veloren's success is not ECS. It is instead…
There are few open source projects rivaling Veloren's collaborative spirit. Veloren has countless collaborators on GitLab, and it's brimming with commits every day as of this writing. That's not just counting programmers, but artists and designers as well. Engaged players, who diligently scribe bug reports and suggestions, ought to be called what they are too: collaborators! Veloren's accessible contribution pipeline is astounding, an infectious comradery that should replicate throughout the open source world at large.
The game's extensive devlog, found on the homepage, chronicles contributions and their originators. The exploration of implementation details cements the effort put forth, unveiling just how involved the simplest features truly are. These writings also teach many interesting things about game development, providing high-level explanations for otherwise mystifying algorithms and code.
So, what's Veloren play like? Is it fun?
It is! There are dark dungeons and caves to explore, so don't forget to use your lantern. You can easily join groups in town when playing multiplayer, which is free! Crafting, of course, plays a major role. Plus, you have a glider, meaning you can glide from mountain to mountain!
One usability enhancement of this game is that, if something is only one voxel higher than your character, then your character will automatically step onto it. You don't have to constantly mash the space bar to trek a moderate incline, which goes to show how much thought went into the finer details of the game.
Veloren is a great game with great architecture, which is only made possible by a great community. I recommend that you download the game, so you can try it out! I also stress reading the manual. If you like the game, consider getting involved. It's an outstanding way to get your feet wet with Rust, ECS, game development, and voxels, among other things.