pub unsafe extern "C" fn ecs_set_timeout(
world: *mut ecs_world_t,
tick_source: u64,
timeout: f32,
) -> u64Expand description
Set timer timeout. This operation executes any systems associated with the timer after the specified timeout value. If the entity contains an existing timer, the timeout value will be reset. The timer can be started and stopped with ecs_start_timer and ecs_stop_timer.
The timer is synchronous, and is incremented each frame by delta_time.
The tick_source entity will be a tick source after this operation. Tick sources can be read by getting the EcsTickSource component. If the tick source ticked this frame, the ‘tick’ member will be true. When the tick source is a system, the system will tick when the timer ticks.
@param world The world. @param tick_source The timer for which to set the timeout (0 to create one). @param timeout The timeout value. @return The timer entity.