Skip to content
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

Support targeting multiple entities #23

Open
musjj opened this issue Apr 17, 2024 · 1 comment
Open

Support targeting multiple entities #23

musjj opened this issue Apr 17, 2024 · 1 comment

Comments

@musjj
Copy link

musjj commented Apr 17, 2024

Some events intrinsically needs to targets multiple entities.

For example collision events will need to be able to report to multiple entities. You can currently simulate this by cloning the event (which can contain lots of data like a vector of manifolds) and sending them to each entity.

I think the ability to natively target multiple entities would help a lot for this kind of use-case.

@aevyrie
Copy link
Owner

aevyrie commented May 4, 2024

You would need to clone the event regardless. Events need to traverse the hierarchy and can be mutated. If you target two entities, you need two events. If your event is not mutated and you want to avoid cloning it, you can Arc the data.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants