Replies: 1 comment
-
After further investigation I discovered, that what I set as a component ( Initially I thought that by adding |
Beta Was this translation helpful? Give feedback.
0 replies
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.
Uh oh!
There was an error while loading. Please reload this page.
-
I have a general question to improve my understanding of Bevy.
When I spawn an entity I want it to be interactive (hence
Interaction
enum):I cannot use
Interaction
enum directly, so I need to add enum variant.However, when I run a query on it:
I can also match that entity against any Interaction I want (having both
::Hovered
and::Pressed
working).Both of these examples make sense individually, but together it's a bit counterintuitive design to me. Could somebody elaborate on topic of enum variants as components? From my experiment it doesn't matter which enum variant of Interaction I add to an entity, it gives me all Interaction capabilities.
Beta Was this translation helpful? Give feedback.
All reactions