Bevy game development tutorials and in-depth resources (taintedcoders.com)

by GenericCanadian 118 comments 140 points
Read article View on HN

118 comments

[−] tyleo 34d ago
I really want to like bevy but compile times are slow and the output binaries are huge.

I built a few games in WASM and was shocked to see many of the bevy variants larger than the Unity versions.

There’s definitely a market for rust game engines but it seems that no one’s hit the sweet spot yet.

[−] alfiedotwtf 34d ago
I hear Rust being slow to compile is their biggest gripe, but really - look at what you’re gaining for the slowdown!

Bevy gives you a very nice ECS to model your app but compilation can be slower than hand crafted code, while not using it gives you tonnes more code and the complexities that come with it, just to compile faster?

[−] tyleo 34d ago
I don’t know what you mean by, “just to compile faster.” Compiling fast is critical to game development. There’s no formula for fun so you have to iterate extensively.

I also don’t think that other solutions are “tonnes more code.” Any code will explode in size if poorly written. The same is true for bevy.

[−] NewsaHackO 34d ago
I swear I have only heard about ECS and people trying to show off how good the ECS is when it comes to Bevy, never about an actual game.
[−] polski-g 34d ago
"There are more rust game engines than rust games" - Confucius
[−] Ygg2 33d ago
"The claim which is made without proof can be dismissed without proof" - Big Brain
[−] NewsaHackO 33d ago
What are some notable rust games?
[−] roflcopter69 32d ago
[−] NewsaHackO 31d ago
OK, even though it does not seem like that game was very notable, will give you that one game. Rust has at least ~5-6 game engines though, so you will have to come up with 4-5 more.
[−] CupricTea 25d ago
Tiny Glade launched to 10,692 concurrent players with a 97% overwhelmingly positive score on Steam.

Calling that "not very notable" for an indie title is pretty ignorant.

[−] Ygg2 32d ago
Here is ten games in bevy engine

https://youtu.be/50g3eSrSM6Q

Rust has like 2-3 game engines and a bunch of bindings.

[−] NewsaHackO 31d ago
OK, so I didn't say random games, though. I said notable ones. None of those are notable, and half of them aren't even released yet.
[−] Ygg2 30d ago
No, the statement is there is more Rust engines than games.

It also adds easy to move goalpost of notability, that only accounts for luck and age, not actual capabilities.

[−] NewsaHackO 30d ago
I have created 1000 rust games engines. All will be released Q2 2031.
[−] CyberDildonics 34d ago
Bevy gives you a very nice ECS

That's a single data structure. People say binaries start at 50 MB for a hello world program and 700 MB for the debug binaries.

https://old.reddit.com/r/bevy/comments/16wcixk/cant_figure_o...

[−] saghm 34d ago
It's a single data structure that contains your entire game though? The whole point of the ECS is that literally everything uses the same data; it's like if you modeled every object in the world with one struct that has an optional field for every piece of data that could exist. I'm not saying that necessarily makes the tradeoff worthwhile, but calling it a "single data structure" is a bit reductive.
[−] CyberDildonics 34d ago
It's a single data structure that contains your entire game though?

Are you asking?

but calling it a "single data structure" is a bit reductive.

No it isn't. It's like a tiny database. Depending on how someone implements it, it could use arrays, hash maps and b-trees. There is no universe where this means a binary that does nothing should be 50 megabytes.

[−] fluffybucktsnek 34d ago

> It's like a tiny database.

No it isn't. It also handles system management and concurrency, basically the main loop of your application.

I also would be cautious of assigning the blame of the binary size onto the data structure on its own.

[−] alfiedotwtf 33d ago
I would say yes it’s like a tiny database but as well as all the other things your added. And I think that’s a good thing, because it does this at the type level!

I’m actually seeing if I can build a parser using bevy_ecs just because the way their state machine works, it looks like it would be fun

[−] CyberDildonics 34d ago
system management

What does that mean?

concurrency

Some data structures and databases deal with concurrency.

[−] nkrisc 34d ago
In this case systems are the S of ECS and contain all your game logic, acting upon the entities and components (E and C).

By system management I assume they mean the APIs bevy offers for scheduling and sequencing systems and events so your game logic remains modularized while still running in the correct order.

[−] CyberDildonics 33d ago
It seems like you're calling an entire game engine "ECS". I'm not sure what the point is here, the whole question was what justifies having a 50 MB hello world binary. It doesn't matter what you put into a data structure, the data structure itself shouldn't make 50 MB binaries.
[−] fluffybucktsnek 33d ago
Exactly this.
[−] reitzensteinm 34d ago
Compile times are my biggest struggle, too. I'm vibecoding Bevy with parallel agents, and the bottleneck is often compiling the changes on my 7950X, not getting Codex to write them.

As far as file sizes go, I'd be really interested in how a Rust compiler that didn't monomorphize so much would perform. Right now you have to modify the source code to write polymorphic generic functions, but it doesn't strictly have to be that way (at least as far as I can see).

I wouldn't use Bevy for a web only game either, especially while it's still single threaded on WASM.

[−] vivzkestrel 34d ago
- since we are on the topic, i wanted to ask people here

- could someone kindly share some resources on c++ game development

- here is what i have

- https://gamedev.net/tutorials/

- https://shader-learning.com/

- https://learnopengl.com/

- https://shaderacademy.com/

- https://www.gabrielgambetta.com/client-server-game-architect...

- https://github.com/0xFA11/MultiplayerNetworkingResources

- just a headsup, i am looking for 3D game development without unreal, unity , godot or any of those engines

[−] michaelteter 34d ago
Those of us unfamiliar with Bevy can deduce what it might be, but it would be really nice if your introduction included at least a link titled "Bevy game engine" which links to bevy.org.

Then your unfamiliar readers can first hop to bevy.org to see what it's all about.

[−] nextaccountic 34d ago

> These guides are up to date with Bevy version 0.18

This is huge, thanks. Unfortunately many Bevy resources became stale (the Bevy cookbook was even abandoned, there was little interest in keeping it up to date and so there were many sections for, say, Bevy 0.12)

[−] roflcopter69 34d ago
There's also ongoing work on the (for now hidden) Bevy Book https://bevy.org/learn/book/intro/

Already seems like a great resource to me but it's still WIP.

[−] reitzensteinm 34d ago
This site is excellent. I emailed the author to thank them after reading it cover to cover, and they replied and asked if anything was unclear or if there was anything I wanted to see explored more.

Quite the dedication to a free resource!

[−] jvuygbbkuurx 34d ago
My problem with bevy isn't the basics, but the architecture. I always feel like I'm making wrong decisions on if something should be a component or a field, and how it interacts with other stuff in systems. I just feel like I'm making an unmaintainable mess, but I'm not sure how it could be improved.
[−] Ugvx 34d ago
This has been on my list to kick off for a while. From previous times I looked at it, these tutorials are the only text based tutorials that are really kept up to date. Love it
[−] jippo 34d ago
Thank you. Not many free and in-depth resource for Bevy engine. Mostly are paid ones. I am surprised that you switch from Ruby to Rust. Seems a different beast to me.
[−] SilentM68 34d ago
Thank you :)