diff options
Diffstat (limited to 'src/statistics/boon.rs')
-rw-r--r-- | src/statistics/boon.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/statistics/boon.rs b/src/statistics/boon.rs index 4d0348e..912fdb6 100644 --- a/src/statistics/boon.rs +++ b/src/statistics/boon.rs @@ -107,6 +107,9 @@ impl BoonQueue { /// /// * `duration` - The amount of time (in milliseconds) to simulate. pub fn simulate(&mut self, duration: u64) { + if duration == 0 { + return; + } let mut remaining = duration; match self.boon_type { BoonType::Duration => { @@ -138,6 +141,11 @@ impl BoonQueue { self.queue.clear(); } + /// Checks if any stacks are left. + pub fn is_empty(&self) -> bool { + self.queue.is_empty() + } + /// Calculate when the stacks will have the next visible change. /// /// This assumes that the stacks will not be modified during this time. |