observe

Function observe 

Source
pub fn observe<E, B, M>(
    observer: impl IntoObserverSystem<E, B, M>,
) -> impl EntityCommand
where E: EntityEvent, B: Bundle,
Expand description

An EntityCommand that creates an Observer watching for an EntityEvent of type E whose EntityEvent::event_target targets this entity.