this post was submitted on 05 May 2025
6 points (100.0% liked)

Bevy

322 readers
1 users here now

A community for discussion around the bevy game engine! https://bevyengine.org/

founded 1 year ago
MODERATORS
 

Hi!

I've been learning Bevy and LOVING IT, there's only one thing confusing me. Many components appear to be created magically even if not specified in the Bundle passed to commants.spawn.

For example, when I spawn just a Sprite component, the entity seems to automatically get a Transform component, even if I didn't give it one.

Similarly, this example spawns a Screenshot component, which apparently results in a Capturing component that can be queried later.

Are these "implicit" components documented somewhere? I took a short look at the TransformPlugin for example but I can't seem to figure out where these components come from.

Thanks y'all!

you are viewing a single comment's thread
view the rest of the comments
[–] TehPers@beehaw.org 2 points 1 week ago

The required components are documented in the component impl block. Scroll down in docs.rs until you find impl Component and they'll show up there.

Apparently there were issues getting required components to show up at the top of the page (from my understanding anyway), so for now they live there.