ippa / chingu

OpenGL accelerated 2D game framework for Ruby
http://ippa.se/chingu
GNU Lesser General Public License v2.1
309 stars 66 forks source link

Expiration time on repeating timers #28

Closed fowlmouth closed 13 years ago

fowlmouth commented 13 years ago

Add :during option to #every method to put an expiration on repeating timers.

every(60_000, :during=>300_000) { @pancakes.flip }.then { @pancakes.move_to_plate }