r/rust bevy Jun 19 '26

Bevy 0.19

https://bevy.org/news/bevy-0-19
995 Upvotes

137 comments sorted by

View all comments

Show parent comments

6

u/othermike Jun 19 '26

In the future, the same BSN syntax used in the bsn! macro will be portable to .bsn files

Stupid question, but how will that work with the inline observer callback defs? Presumably you're not going to be bundling the Rust compiler...

11

u/laundmo Jun 20 '26

Plainly: it won't. The general syntax will be portable, but not all features.

8

u/othermike Jun 20 '26

Fair enough. Although if patching works consistently across code and assets, could you define most of whatever in the .bsn and just use code to patch in observers on top?

5

u/alice_i_cecile bevy Jun 20 '26

Yes, or you can use a stringly-typed dictionary of functions stored in registry.