bevy/crates/bevy_app
Jerome Humbert f9c8f511fd
Add SubApp::take_extract() (#16862)
# Objective

Fixes #16850

## Solution

Add a new function `SubApp::take_extract()`, similar to
`Option::take()`, which allows stealing the currently installed extract
function of a sub-app, with the intent to replace it with a custom one
calling the original one via `set_extract()`.

This pattern enables registering a custom "world sync" function similar
to the existing one `entity_sync_system()`, to run custom world sync
logic with mutable access to both the main and render worlds.

## Testing

`cargo r -p ci` currently doesn't build locally, event after upgrading
rustc to latest and doing a `cargo update`.
2024-12-24 18:26:32 +00:00
..
src Add SubApp::take_extract() (#16862) 2024-12-24 18:26:32 +00:00
Cargo.toml Remove bevy_core (#16897) 2024-12-19 18:36:51 +00:00
README.md add and fix shields in Readmes (#9993) 2023-10-15 00:52:31 +00:00

Bevy App

License Crates.io Downloads Docs Discord

This crate is about everything concerning the highest-level, application layer of a Bevy app.