diff --git a/src/lib.rs b/src/lib.rs index 6d5dc67..90c278c 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -260,6 +260,13 @@ impl EasingChainComponent { self.0 = tmp; self } + + /// Adds a delay before triggering the easing. + pub fn delay(mut self, duration: Duration) -> Self { + self.0[0].paused = true; + self.0[0].timer = Timer::new(duration, TimerMode::Once); + self + } } /// Trait marking components that can be eased