summaryrefslogtreecommitdiffstats
path: root/state.rb
diff options
context:
space:
mode:
Diffstat (limited to 'state.rb')
-rw-r--r--state.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/state.rb b/state.rb
index a05cc05..0994c65 100644
--- a/state.rb
+++ b/state.rb
@@ -217,6 +217,11 @@ class State
nil
end
+ # Hold all states of a class
+ def State.hold(type)
+ @@states.select{ |x| x.is_a? self }.each{ |x| x.hold(type) }
+ end
+
private
# Set this state to true
def rise