diff options
author | dmitry kim <jason@nichego.net> | 2008-12-29 04:38:00 +0300 |
---|---|---|
committer | dmitry kim <jason@nichego.net> | 2008-12-29 04:38:00 +0300 |
commit | 576dd0affc6b85a8efa1f0cff0abef55ac0cd415 (patch) | |
tree | aa67403247f552d31156c77bfd3ab045c68a2d34 | |
parent | ab6aebf3f87aac76cb8b568e0ea8626d19e4d9a9 (diff) |
* (timer) ignore blocked actions .next() :/
-rw-r--r-- | lib/rbot/timer.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/rbot/timer.rb b/lib/rbot/timer.rb index f68e490a..aafa9be2 100644 --- a/lib/rbot/timer.rb +++ b/lib/rbot/timer.rb @@ -248,7 +248,7 @@ class Timer @actions.delete k unless a.next end - nxt = @actions.values.map { |v| v.next }.min + nxt = @actions.values.find_all { |v| !v.blocked? }.map{ |v| v.next }.min if nxt delta = nxt - now |