how to fetch camera component (and how to read docs) #4687
Unanswered
strattonbrazil
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Using Bevy's simple scene 3d example.
Reading bundle documentation
Looking at the spawn_bundle documentation, the snippet below creates a camera-like entity with one or more components:
Just looking at the PerspectiveCameraBundle, how may I know which components are added? Are the fields mapped to components 1 to 1?
Fetching components
With that camera bundle created, how does the engine know to render through it without any kind of registration? Related, I don't understand the Rust mechanism Bevy uses to register callbacks with parameters that are autopopulated. How does that work? And how would I look at the docs for PerspectiveCameraBundle and see how to type the component I want sent to my system?
Beta Was this translation helpful? Give feedback.
All reactions