~/talk

Bevy's immutable components: managing side effects in a parallel world

Talkat RustWeek 2025 · 2025-05-13..05-17· [rust, game-development]
slides:none on file

Bevy adds immutable components as a metadata flag that blocks get_mut but still allows removal and reinsertion, which intentionally triggers lifecycle hooks to run immediate world-mutating code. That loophole converts a compile-time restriction into a reliable push-based enforcement mechanism used to implement working relations (doubly linked entity lists) and centralized indexes; relations and indexes are built and validated at insertion/removal and they work, trading higher runtime cost for zero-frame-invariant violations versus slower pull-based change detection.

AI-written summary · about

  1. 0:00Intro
  2. 0:55What is Bevy
  3. 4:23Who uses Bevy
  4. 4:38Why this talk
  5. 5:35What is an ECS
  6. 6:33Components
  7. 7:27Getter setter pattern
  8. 8:45Component trait
  9. 9:31Component mutability
  10. 10:48Mutability
  11. 11:55Life cycle hooks
  12. 13:18Change detection
  13. 14:26Why do we need both
  14. 15:33The core problem
  15. 16:02Pullbased mechanisms
  16. 17:08Implement relations
  17. 18:26Summary
  18. 19:42Support the ecosystem
  19. 19:57Questions
  20. 20:22Game studio
  21. 21:26Tiny Glade
  22. 22:41Whats next
  23. 23:30Flex
  24. 25:13ECS Dev
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.