15 ms·
Veloren – Open-source MMORPG written in Rust
- jarbus 6y agoBeen following this project for a while. Incredible community & devs, and it's getting better with each update. Surprised at how well it runs, too.
- rektide 6y agotwo years of weekly blog updates on the project! that's super impressive in open source, talking about the work is really as important as doing the work. a key catalyst in turning "free as in beer" to the kind of communal shared understanding anarcho-syndicalist working practicing healthy community. i want a "free as in ourselves" mantra or some such to trot out here. anyhow Veloren keeping their story of development alive is such a respectable powerful act, keeping users & developers & everyone in between engaged & interested & learning.
- moritonal 6y agoLooks neat. I'm struggling to get why Rust is important in this context? Is it a demo of Rust's features and a fun way to learn, or is it a major feature of the game which lets you do things that games like Miecraft (in Java) couldn't do? * I'd assume peformance was great, but is there metrics to show? * Is the client and server written in Rust, or just the server?
- emteycz 6y agoI think it's important piece of information for HN given it's open source. I wouldn't care if it was closed source.
- zelphirkalt 6y agoRust is probably mentioned for the more up to date language concepts and type safety, as in "Look, our code is probably more reliable than the code of many other games.", which in turn might mean, that the user experience will be better. Those things could be a huge deal for any game developer, especially, when you already know Rust.
- hctaw 6y agoI think Rust makes a compelling case for production code with a high degree of reliability without sacrificing too much performance. Something I think developers don't appreciate enough is that Rust helps you write code that doesn't crash nearly as much as something in C/C++, particularly with respect to how library authors express fallable code with option/result types and the lack of memory safety footguns like iterator invalidation. Consumer software is better without crashes. It's sad how rife software is these days with segfaults that can be prevented by design.
- musingsole 6y agoBut is Skyrim even worth it if you don't have mammoths walking in the sky and broken necks from overzealous head tracking?
- imbnwa 6y agoSuperficially speaking, I've seen a lot of comments around Rust's mismatch for assuming C++'s duties in game development so perhaps this is one of those "Rust in Production" signals
- hombre_fatal 6y agoMinecraft was written in Java, so that can't be it. Open-source + built in a slightly interesting language are the only reasons we'd be discussing an MMORPG. Good luck to the team. MMORPG that anyone wants to play is probably the hardest challenge in gamedev and game design.
- imbnwa 6y ago> Minecraft was written in Java Did not know that
- vlang1dot0 6y ago> Minecraft was written in Java, so that can't be it. What does that have to do with the parent comment? The usual argument I've seen is that game developers "move too fast", "don't have everything designed ahead of time", "have to iterate quickly" and Rust's insistence on writing correct code gets in the way of that during the prototype phase. Java doesn't really have that issue as it is quite a bit more forgiving than C++ and will happily let you hammer a square peg into a round hole at the expense of performance, as evidenced by Minecraft.
- pjmlp 6y agoThe only evidence is that school kids cannot write mods like AAA studios, it wouldn't be any different if those mods were written C++, or JavaScript (Bedrock)
- Macha 6y ago> Minecraft was written in Java, so that can't be it. And everyone who plays large modpacks, goes around large buildings, or just sets off a ton of TNT has seen how it has suffered for it. On the other side, anyone who has seen the selection of mods available for Java edition vs bedrock edition (the C++ rewrite) despite a modding API for bedrock being officially supported has seen how it has benefitted from this.
- zesterer 6y agoHi, I'm the founder of the project. We chose Rust because it's performant, memory-safe, and comes with a host of modern features that make writing code with the language very enjoyable. We could have chosen C++, but I'm very glad that we didn't. Memory safety is great: I've not needed to break out gdb even once throughout the history of this project, despite the size of the project. This safety means that code is easier to review because it 'does what it says on the tin' and is much less prone to UB and non-local behaviours. It also reduces the prevalence of bugs. I've been shocked by just how much easier it is to write reliable and bug-free code with Rust than it is with languages that I've used in the past (C, C++, Python, Vala, amongst others). The type system is also very powerful and it lets us encode a lot of useful invariants that can be checked by the compiler. Knowing that what you're doing is correct-by-nature is a great help and it frees your mind up to focus on the logic of what you're writing rather than getting distracted by irrelevant details like representation. Rust plays very well with data-oriented design. This works great for us. At its heart, Veloren uses a high-performance ECS that is extremely cache-coherent. There's still lots of optimisation work to do, but we're already seeing that servers that can handle hundreds of players and millions of entities without issue, despite the fact that terrain generation is done server-side (and, as such, we have similar performance constraints to games like Minecraft). The client, server and client/server frontends (frontends are logically independent and alternative frontends can be written for the game) are all written in Rust. In addition, the in-development plugin API will allow for plugins written in Rust and compiled to WASM. In addition, Rust is also very portable. Compiling the game on (and for) many platforms is incredibly easy. The game runs well on Windows, Mac OS, Linux, BSD, and community members have even gotten it running on the Raspberry Pi and a hacked Nintendo Switch! I hope this doesn't come across as being overly evangelical, but I think I speak for all of the developers when I say that we have no regrets in the slightest about choosing Rust! That doesn't mean it's the right choice for all projects, of course. The Rust gamedev ecosystem is still relatively immature. Although this is changing fast, don't expect to find any nuts-and-bolts game engines ready to go. However, if you're not afraid of diving down into low-level APIs here and there, Rust might be a great choice. Edit: At a second glance, I see you're asking more about why mentioning the language is important. As a community-driven project, we rely on encouraging new contributors to work on the game and the choice of language is something that developers usually care about a lot. Extensibility and open development is really important for us and so 'showing the innards' is a big part of what we do when interacting with the community. Unless it's security-sensitive, we'll always discuss development issues and ideas in a public forum where anybody can add their input.
- rowanG077 6y agoIn general in most modern languages there aren't really things you "cannot" do with one language that you could with another. It's more of a question of how easy it is to do something. And in general is should be much easier to create a performance sensitive game in Rust then in Java. Besides that Rust is much more ergonomic to use.
- moldavi 6y agoRust is more performant, but Java is actually much more ergonomic, since you dont need to worry about borrow checking concerns and its frequent refactoring. Still, the tradeoff is good for a game like this.
- rowanG077 6y agoI wouldn't say so. Rust borrow checker is really only an issue for novices. Whereas Javas NullPointerException is the bane of even the most experienced dev.
- mkl95 6y agoAs a part time game developer who uses mostly C++ and a bit of Python, I have considered writing a project with Rust a few times, but I've always struggled to find meaningful examples. This is game-changing.
- Kye 6y agoThe #1 problem in MMORPGs is people exploiting bugs for personal gain at the expense of the game's economy and competitiveness in PvP. Some of those bugs end up being in NPC scripts, but most are the kind Rust helps prevent.
- spijdar 6y agoWhich bugs? I wasn't under the impression that exploiting memory safety issues was the dominant type of bug to gain an advantage in multiplayer games, but usually logic errors or some kind of broken script, corner cases in nested control structures, that sort of thing. I can see an argument that Rust could also help prevent those as it is a higher-level language and has a few language features to prevent some of the logic problems, but not that many?
- Kye 6y agoMy knowledge is many years out of date, so I might be wrong.
- spijdar 6y agoI'm also not really that familiar with either Rust or modern multiplayer games, I'm just speculating. It seems like if you could buffer-overflow the server, there are more sinister things you could do besides game-the-game... (that said, I have personally found bugs in text-based MUDs that could have been prevented by Rust. They were all "just" DoS bugs though, instantly crash the server type things)
- gpm 6y agoHonestly, I think rust actually prevents a lot of logic problems, but it's hard to quantify and a subjective feeling that I'm not sure how I'd even go about trying to "prove". Order of magnitude I'd say 50% less logic bugs than a language like Java. Why? Just good language design. Things like "enums" (algebraic data types, not C-enums) making for type checked state machines, really strict typing, immutability by default, simple language semantics, good linters that people actually use, the borrow checker actually does usually lend itself to good design too, and so on.
- renewiltord 6y agoIt’s a dev community. The language is important as a hook for people interested in writing code in the language.
- Macha 6y agoFor certain classes of developers (of which I'd include myself), Rust is more accessible than C++. The tooling is more modern, the APIs feature functional constructs I'm used to for other languages, and it's not like C++ doesn't have its own feature explosion. If you're an open source game project, then it's signalling what developers might be most interested in the source in the hopes that some will then contribute, when addressing a forum of primarily developers.
- hinkley 6y agoAs a wannabe game designer who moved on quickly to other things: object lifetime problems are a bane of game design. They give you memory leaks, and in some situations are how item duplication bugs work. In particular if you do the engine as a collaborative piece, then running a game starts to look like any other volunteer group: a bimodal distribution where few old hands keep it on the rails, a lot of new people whose raw enthusiasm overpowers their lack of experience, who need to be given tasks they can not fuck up so badly. In between it’s a race between burnout and life balance for the people who have shown up for three years. They provide a lot of the leadership and competence, but they also tend to disappear. So you need to groom the newbs to replace them regularly. The old hands are the scribes who provide historical data when those transitions don’t go smoothly. They are continuity and influence, not productivity. Any system that provides some safety for people still working out how to contribute is going to fare much better than one that is alienating. Rust to me is a mix of both, therefore plausible but not a slam dunk.
- Shared404 6y agoI've been keeping an eye on this one, it's not quite there yet if you are looking for a game to play. However, it has a massive amount of potential, and I'm looking forward to seeing where it goes from here. I've also read the code looking for examples of how to do things in Rust, and found it quite pleasant.
- adamnemecek 6y agoIt’s like the first large scale game written in Rust.
- f430 6y agowhat would be the advantage of this vs established libraries written in C#? any thing Rust offers that other languages don't? website is short on details, would be great if they could display its features. There are other MMORPG/MMO frameworks that are quite mature but this looks promising too. edit: reply to one of the comments below regarding the argument Rust = good therefore great for gaming. This. Neither does a good engine. For me I stopped UE4 and went to Unity because of the sheer lack of documentation and community support behind C++ with UE4. C++ is a powerful language but man was it hard finding tutorials and documentation that was up to date.
- adamnemecek 6y agoThe goal is making these libraries in Rust. Rust is fundamentally a better language for game development than C#.
- Thaxll 6y ago0 games have shipped in Rust and there is no plan anytime soon in the future that it will. People think that a good language would make a good game, that's error #1. The ecosystem matters more than the language itself, basically using Rust is starting from scratch so you can't use all the good things that C++ / C# had for the last 15 years. Edit: I want to clarify that I know that Rust is a good language, but as of now in 2021 it's just not ready for games, and there is no sign of change. It's fine to say "I can make games in Rust, it's going to be hard and painful but I can get something, but saying it's better than C# is definitly wrong.
- protoman3000 6y agoI like how everything written in Rust gets upvoted here. Jokes aside thanks for sharing. It’s always interesting to read game source code and Rust beginners can learn a lot reading this code.
- bicx 6y agoThis comment was written in Rust
- goblinux 6y agoI'm out of the loop, what is the huge fascination with Rust? I see people getting excited about normal sounding projects that are written in rust - is it the new C? new python?
- swsieber 6y agoFor me personally: * It has the performance profile of C * A really good package manager * I don't have to worry about segfaults/runtime issues from manual memory management * I love the type system (yay expressive static types with pattern matching) * Also prevents data races and other things like iterator invalidation * Also, null safety, among other things leads to a lot fewer runtime issues I need to figure out
- __s 6y agoNew C since it's about zero cost abstractions (in the don't pay for what you don't use sense) It does this well, since at the same time I was able to write 10k lines of JS game code into 10k lines of Rust game code: https://www.reddit.com/r/rust/comments/k3jy5g/i_rewrote_10k_lines_of_js_into_rust_over_the_last/ https://www.reddit.com/r/rust/comments/k3jy5g/i_rewrote_10k_... Have since rewritten server from nodejs to Rust. There the line count grew. But async/await was splendid there, & serde made implementing the json server/client protocol straight forward
- mynameisash 6y agoOthers may give a better answer, but from my perspective -- a data engineer who started learning rust maybe 8-10 mo ago -- I find that I am enjoying Rust because: * It has algebraic data types, pattern matching, etc. - language features that just don't exist in most languages I've used. (I did play with F# for a bit and really loved its capabilities, but I've never had the occasion to get into F#, unfortunately.) Once I start using these features, I suddenly find that all these other languages are sorely lacking. * Its safety guarantees mean that I spend more time in the IDE fixing compiler errors and less time in the running exe finding my problem. I often find that when my program compiles, it is generally correct. This has given me a lot of confidence in the quality of my releases (borne out in actual production code, not just toy projects) * Speed of execution is (in my experience), better than an order of magnitude faster than in other languages for a similar implementation. YMMV, and there may be some of that New Relationship Energy here, but I can absolutely see why it's been on SO's most loved languages for five years in a row[0]. [0] https://insights.stackoverflow.com/survey/2020#technology-most-loved-dreaded-and-wanted-languages-loved https://insights.stackoverflow.com/survey/2020#technology-mo...
- pling87 6y agoContext: For those of you who still remember it, CubeWorld was a Minecraft-like RPG game that had a wildly popular Alpha, was eventually abandoned by its developer, was later revived, and was then universally vilified by the masses because the developers "ruined" the game. Veloren is the spiritual successor to CubeWorld, made by disappointed fans wanting something better.
- Quot 6y agoJust a small correction to that (because I don't like the hate that the Cube World devs get): They never abandoned the game. It was a two person team (husband and wife), and both devs worked full time jobs while making CW. After the initial alpha release, CW got a ton of attention and became a DDoS target, which triggered some mental issues in the lead dev.[1] They went dark after that for a long time (probably because everything new was usually posted by this lead dev). The silent mystery with the game just built up even more hype over six years until the full game finally released, and the massive attention and disaster seemed to happen all over again. Every post about the game complained about the new design decisions with leveling. The lead dev seemed to think this was the best version of the game (based on his comments in his blog) and he seems to not have taken the criticism well, leading to him going dark again. I wish he would have taken the hits and continued with the game, but if it's affecting his mental health in this way, he is probably better off abandoning it. I hope he gets better and I am still looking forward to anything he and his wife make in the future. [1] https://web.archive.org/web/20190910123212/http://wollay.blogspot.com/ https://web.archive.org/web/20190910123212/http://wollay.blo...
- zesterer 6y agoYep, this is correct. All of us Veloren developers very much appreciate the work the Cube World developer put into the game: it's great fun. Veloren isn't trying out outright compete with the game: increasingly, the project is adopting goals that differ. Over time, I'd like to see Dwarf Fortress be the game Veloren is most frequently compared to instead, since that seems to be the direction of momentum.
- pling87 6y ago
- protoman3000 6y agoAnybody looking for the actual source code, it’s here: https://gitlab.com/veloren/veloren https://gitlab.com/veloren/veloren
- Karsteski 6y agoI've been hearing about this game for a while now, I'm very glad it's making progress. I'm going to start following the blog as I'd like to try it out myself. I'm also glad that it's written in Rust, as I would very much like Rust to succeed as a high performance programming language :)
- timwaagh 6y agoWould have been better to do the game on a commercial basis and release the engine open source if they wanted to demonstrate the viability of game dev in rust, but otherwise it looks promising
- Grimm1 6y agoThis is super neat, I've been looking for an experience just like this recently. I think I'll be spinning up a server!
- Kiro 6y agoWhat is the gameplay like?
- zesterer 6y agoWe're aiming for something that plays a bit like Legend of Zelda but allows you to interact with the world in a manner closer to Dwarf Fortress. We're also trying to keep movement fluid and dynamic with lots of opportunity to use the environment around you as you move throughout the world. All of this is a work in progress (hence the pre-alpha versioning), but we already have a few hours of gameplay with dungeons and caves to explore, lots of items to craft and find, and several skill trees to upgrade. In the long-term, we're aiming for more procedural interaction with elements of the world.
- mepian 6y agoIs it possible for players to modify the world's landscape, like in Minecraft? If not, is this planned for the future?
- zesterer 6y agoYes, but only via the admin-only /build command. It's not an ordinary part of gameplay, aside from the limited destruction you can do with some of the weapons. We're considering adding some sort of building system, but we've not reached a consensus on how to best implement it yet.
- MauranKilom 6y agoI read all the HN comments and it wasn't until I saw the logo on the site that I noticed the game isn't actually called "verloren" ("lost" in German). That makes me wonder: How did you come up with this choice of name?
- Karsteski 6y agoI still pronounce it as "Verloren" as that was my initial impression as well lol
- antidocker 6y agoRust is like Bitcoin. Hyped. I would always choose Mercedes of Programming world which is C++
- aidenn0 6y agoIs it me, or are the voxels way bigger than in 90s novalogic games? It's hard to say for sure because it's rendered at a much higher resolution, but it sure looks that way. I know the depth-of-field was crappy in those, but this just seems like not even as good as 25 year old technology.
- yrgulator 6y agoDude puts time and sweat to make this available for free, sacrifices weekends and family time to keep the project alive, and here comes this nobody and complains about their work and reduces it to not worth it. Leeches lime you are the reason open source should be paid. Go bitch somewhere else.
- lwansbrough 6y agoSize isn’t really the focus. It’s a stylistic choice. These days if you built something with the limitations that Delta Force had, you’d probably be able to render scenes in the quadrillions of voxels. The largest scene I’ve seen is 1,000,000^3 voxels at < 1mm/voxel.
- aidenn0 6y agoOkay, that makes sense. I'd probably get it if I'd ever played minecraft.
- pabs3 6y agoThere was an interesting talk about how Veloren is structured at the Debian gaming mini-conf: https://peertube.debian.social/videos/watch/2670c322-0bcb-474b-95b3-d77b65ca62e5 https://peertube.debian.social/videos/watch/2670c322-0bcb-47...
- xyzzy_plugh 6y agoThis game looks a lot like Cube World -- is this just a Cube World clone?
- buzzerbetrayed 6y agoAs someone who has never played cube world, why compare this game to cube world rather than to Minecraft? Looks very Minecrafty to me. Does cube world have something that makes it significantly different than Minecraft?
- xyzzy_plugh 6y agoIt doesn't look like minecraft, though. The character design, scale of the player to the world, design of the world (trees, houses, even mountains) looks identical to Cube World. The skill bar at the bottom looks like Cube World. I encourage you to bring up a screenshot of Cube World side by side and see if you can tell the difference between this game. Looks nothing like Minecraft, except for it being blocky.