Skip to main content

with_current_phase

Function with_current_phase 

Source
pub async fn with_current_phase<F: Future>(
    scene_node_id: SceneNodeId,
    phase_start_ms: u64,
    fut: F,
) -> F::Output
Expand description

Run fut as the body of the phase at scene_node_id (SRD-100 P1c): scopes the task-local [CURRENT_PHASE] for the future’s duration. run_phase wraps itself with this so its whole body — the activity loop and every fiber it propagates — resolves to this phase’s node, and any ambient emit nests under its depth.