bevy/crates/bevy_ecs/src
Aevyrie 4667d80243 Allow registering boxed systems (#10378)
# Objective

- Allow registration of one-shot systems when those systems have already
been `Box`ed.
- Needed for `bevy_eventlisteners` which allows adding event listeners
with callbacks in normal systems. The current one shot system
implementation requires systems be registered from an exclusive system,
and that those systems be passed in as types that implement
`IntoSystem`. However, the eventlistener callback crate allows users to
define their callbacks in normal systems, by boxing the system and
deferring initialization to an exclusive system.

## Solution

- Separate the registration of the system from the boxing of the system.
This is non-breaking, and adds a new method.

---

## Changelog

- Added `World::register_boxed_system` to allow registration of
already-boxed one shot systems.
2023-11-29 16:40:36 -08:00
..
entity Use EntityHashMap<Entity, T> for render world entity storage for better performance (#9903) 2023-09-27 08:28:28 +00:00
query Derive Error for more error types (#10240) 2023-10-28 22:20:37 +00:00
reflect reflect: TypePath part 2 (#8768) 2023-10-09 19:33:03 +00:00
schedule Replace all labels with interned labels (#7762) 2023-10-25 21:39:23 +00:00
storage Make builder types take and return Self (#10001) 2023-10-09 19:46:17 +00:00
system Allow registering boxed systems (#10378) 2023-11-29 16:40:36 -08:00
world Replace all labels with interned labels (#7762) 2023-10-25 21:39:23 +00:00
archetype.rs Add a public API to ArchetypeGeneration/Id (#9825) 2023-10-02 12:54:45 +00:00
bundle.rs Fix some nightly warnings (#9672) 2023-09-02 18:35:06 +00:00
change_detection.rs Updates for rust 1.73 (#10035) 2023-10-06 00:31:10 +00:00
component.rs Updates for rust 1.73 (#10035) 2023-10-06 00:31:10 +00:00
event.rs Only run event systems if they have tangible work to do (#7728) 2023-09-24 00:16:33 +00:00
lib.rs Global TaskPool API improvements (#10008) 2023-10-23 20:48:48 +00:00
removal_detection.rs Hide UnsafeWorldCell::unsafe_world (#9741) 2023-10-02 12:46:43 +00:00