Live data from Hacker News

Migrating away from Rust

deadmoney.gg

31–40 of 799 posts

Re: Migrating away from Rust

#31

Rust is not good for video game gameplay logic. The ownership model of Rust can not represent the vast majority of allocations. I love Rust. It’s not for shipping video games. No Tiny Glade doesn’t count. Edit: don’t know why you’re downvoting. I love Rust. I use it at my job and look for ways to use it more. I’ve also shipped a lot of games. And if you look at Steam there are simply zero Rust made games in the top 2…

> Rust can not represent the vast majority of allocations

Do you mean cyclic types?

Rust being low-level, nobody prevents one from implementing garbage-collected types, and I've been looking into this myself: https://github.com/Manishearth/rust-gc

It's "Simple tracing (mark and sweep) garbage collector for Rust", which allows cyclic allocations with simple `Gc` syntax. Can't vouch for that implementation, but something like this would be good for many cases.

Re: Migrating away from Rust

#32

It’s incredible how many projects and articles have been written around ECS with very little results. Quake 1-3 uses a single array of structs, with sometimes unused properties. Is your game more complex than quake 3? The “ECS” upgrade to that is having an array for each component type but just letting there be gaps: transform[eid].position += … physics[eid].velocity = …

Quake 1-3 were written for computers where memory was not much slower than the CPU as is the situation today.

But yeah, probably you don't need an ECS for 90% of the games.

Re: Migrating away from Rust

#33

Earlier quoted context omitted.

More surprising part for me is not migrating from Rust/Bevy, but migrating _to_ C#/Unity. Although points mentioned in the post are quite valid.

Where would you migrate to?

Maybe godot? The unity scandal recently is not great for developers.

Re: Migrating away from Rust

#34
post #14

The article title is half-true. It wasn't so much they migrated away from Rust, but that they migrated away from Bevy, which is an alpha quality game engine. I wouldn't have read the article if it'd been labeled that, so kudos to the blog writer, I guess.

They mentioned ABI and the ability to create mods, which are Rust things.

Here's a thought experiment: Would Minecraft have been as popular if it had been written in Rust instead of Java?

Re: Migrating away from Rust

#35

Rust is not good for video game gameplay logic. The ownership model of Rust can not represent the vast majority of allocations. I love Rust. It’s not for shipping video games. No Tiny Glade doesn’t count. Edit: don’t know why you’re downvoting. I love Rust. I use it at my job and look for ways to use it more. I’ve also shipped a lot of games. And if you look at Steam there are simply zero Rust made games in the top 2…

> No Tiny Glade doesn’t count.

Tiny Glade is also the buggiest Steam game I've ever encountered (bugs from disappearing cursor to not launching at all). Incredibly poor performance as well for a low poly game, even if it has fancy lighting...

Re: Migrating away from Rust

#36
post #14

The article title is half-true. It wasn't so much they migrated away from Rust, but that they migrated away from Bevy, which is an alpha quality game engine. I wouldn't have read the article if it'd been labeled that, so kudos to the blog writer, I guess.

The problem with Rust is that almost everything is still at an alpha stage. The vast majority of crates are at version 0.x and are eventually abandoned, replaced, or subject to constant breaking changes While the language itself is great and stable, the ecosystem is not, and reverting to more conservative options is often the most reasonable choice, especially for long-term projects.

I really don’t think Rust is a good match for game dev. Both because of the borrow checker which requires a lot of handles instead of pointers and because compile times are just not great.

But outside of games the situation looks very different. “Almost everything” is just not at all accurate. There are tons of very stable and productive ecosystems in Rust.

Re: Migrating away from Rust

#37

This seems like the right call. When it comes to projects like these, efficiency is almost everything. Speaking about my own experiences, when I hit a snag in productivity in a project like this, it's almost always a death-knell. I too have a hobby-level interest in Rust, but doing things in Rust is, in my experience, almost always just harder. I mean no slight to the language, but this has universally been my experi…

The advantages of correctness, memory safety, and a rich type system are worth something, but I expect it's a lot less when you're up against the value of a whole game design ecosystem with tools, assets, modules, examples, documentation, and ChatGPT right there to tell you how it all fits together.

Perhaps someday there will be a comparable game engine written in Rust, but it would probably take a major commercial sponsor to make it happen.

Re: Migrating away from Rust

#38
post #14

The article title is half-true. It wasn't so much they migrated away from Rust, but that they migrated away from Bevy, which is an alpha quality game engine. I wouldn't have read the article if it'd been labeled that, so kudos to the blog writer, I guess.

The problem with Rust is that almost everything is still at an alpha stage. The vast majority of crates are at version 0.x and are eventually abandoned, replaced, or subject to constant breaking changes While the language itself is great and stable, the ecosystem is not, and reverting to more conservative options is often the most reasonable choice, especially for long-term projects.

> The problem with Rust is that almost everything is still at an alpha stage.

Replace Rust with Bevy and language with framework, you might have a point. Bevy is still in alpha, it's lacking plenty of things, mainly UI and an easy way to have mods.

As for almost everything is at an alpha stage, yeah. Welcome to OSS + SemVer. Moving to 1.x makes a critical statement. It's ready for wider use, and now we take backwards compatibility seriously.

But hurray! Commercial interest won again, and now you have to change engines again, once the Unity Overlords decide to go full Shittification on your poorly paying ass.

Re: Migrating away from Rust

#40
post #14

The article title is half-true. It wasn't so much they migrated away from Rust, but that they migrated away from Bevy, which is an alpha quality game engine. I wouldn't have read the article if it'd been labeled that, so kudos to the blog writer, I guess.

The problem with Rust is that almost everything is still at an alpha stage. The vast majority of crates are at version 0.x and are eventually abandoned, replaced, or subject to constant breaking changes While the language itself is great and stable, the ecosystem is not, and reverting to more conservative options is often the most reasonable choice, especially for long-term projects.

I have totally disagree here.

I don't even look at crate versions but the stuff works, very well. The resulting code is stable, robust and the crates save an inordinate amount of development time. It's like lego for high end, high performance code.

With Rust and the crates you can build actual, useful stuff very quickly. Hit a bug in a crate or have missing functionality? contribute.

Software is something that is almost always a work in progress and almost never perfect, and done. It's something you live with. Try any of this in C or C++.

Post reply on HN