pub fn frame_counter() -> Plugin {
	Plugin {
		priority: 0,
		tick: Box::new(|state| {
			let timer: Option<usize> = get_state(state, "frame_counter");
			let timer = match timer {
				Some(v) => v + 1,
				None => 0,
			};
			put_state(state, "frame_counter", timer)
		}),
		draw: Box::new(|_, _, _| {}),
	}
}
/// Adds a state key named "timer" that increments every frame.
Adds a state key named "timer" that increments every frame.
Adds a state key named " timer " that increments every frame .
pub fn frame_counter() -> Plugin {
	Plugin {
		priority: 0,
		tick: Box::new(|state| {
			let timer: Option<usize> = get_state(state, "frame_counter");
			let timer = match timer {
				Some(v) => v + 1,
				None => 0,
			};
			put_state(state, "frame_counter", timer)
		}),
		draw: Box::new(|_, _, _| {}),
	}
}
pub fn frame_counter ( ) -> Plugin { Plugin { priority : 0 , tick : Box :: new ( | state | { let timer : Option < usize > = get_state ( state , " " ) ; let timer = match timer { Some ( v ) => v + 1 , None => 0 , } ; put_state ( state , " " , timer ) } ) , draw : Box :: new ( | _ , _ , _ | { } ) , } }
Adds a state key named "timer" that increments every frame.
Adds a state key named " timer " that increments every frame .