-
-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
new example: multiple sprites, one parent entity #13050
base: main
Are you sure you want to change the base?
new example: multiple sprites, one parent entity #13050
Conversation
Screen.Recording.2024-04-21.at.09.21.31.movScreen capture showing the parent entity moving around the window in response to the user pressing the arrow keys |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this! I think the example has its merit, given it's something that beginners trip up on initially.
I just left two comments to improve it, imo, especially the one about Parent
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for addressing the previous comments! One more thing that in my opinion needs to be corrected, otherwise it's good to go from my side.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot! LGTM
I'm not sure the name of the example is correct. It's mostly showing how to use bevy_hierarchy in 2d. It's using mulitple entities, not just one. |
IceSentry's suggestion Co-authored-by: IceSentry <IceSentry@users.noreply.github.com>
What would you suggest instead? I was aiming at searchability (see the linked Reddit thread). Beginners (like me) will wonder "how can I use multiple sprites inside a single entity?" That's how I ended up on the current name. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could you add instructions on screen to use the arrow keys?
Done! |
The main reason for me is that it breaks up the logic in muliple places instead of having everything co-located. It adds runtime logic to setup code that is otherwise not about runtime. It makes it harder/impossible to configure the buttons/values at runtime. It's also a bit unconventional compared to almost all other examples (I would have had the same criticism for the virtual_time example) and uses more advanced features that beginners might not be familiar with. It's not a huge deal, and I guess for an example it doesn't matter, but that's not something that would scale well outside of a simple example.
I don't really have a suggestion. To me the issue is more about bevy_hierarchy not being obvious or easily discoverable. It seems to me like it should be a github discussions with an answer so it's easily googleable. The example itself seems redundant since the |
Updated both of these examples ( |
Bump @mockersf |
Could you rename the example (and everywhere it's mentioned) to "multiple sprites, one parent entity? Saying "one entity" is misleading otherwise |
Done |
I agree that this seems more or less the same as
If this example is merged, looks like there are still instances of @mockersf's issue that need fixing:
|
Objective
Solution