Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
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.
- Loading branch information