diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2012-05-04 11:01:57 +0200 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2012-05-04 11:08:47 +0200 |
commit | 3722fb51d250fd046befb9945f36fe2b3dcd76b4 (patch) | |
tree | 2eb0b39ce65af685f30d3f1ea409eccb742bf78d /lib | |
parent | 7651af4f398d242bcf32961987caafe3081eec2b (diff) | |
download | edoors-ruby-3722fb51d250fd046befb9945f36fe2b3dcd76b4.zip edoors-ruby-3722fb51d250fd046befb9945f36fe2b3dcd76b4.tar.gz |
Board: must let EvenDoors::ACT_FOLLOW go through
Diffstat (limited to 'lib')
-rw-r--r-- | lib/evendoors/board.rb | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/lib/evendoors/board.rb b/lib/evendoors/board.rb index e8c5053..aacb78c 100644 --- a/lib/evendoors/board.rb +++ b/lib/evendoors/board.rb @@ -26,10 +26,12 @@ module EvenDoors # def process_p p @viewer.receive_p p if @viewer - p2 = @spots[p.link_value] ||= p - return if p2==p - p,p2 = p2,p if p.action==EvenDoors::ACT_FOLLOW - p.merge! p2 + if p.action!=EvenDoors::ACT_ERROR + p2 = @spots[p.link_value] ||= p + return if p2==p + p,p2 = p2,p if p.action==EvenDoors::ACT_FOLLOW + p.merge! p2 + end @saved = p receive_p p if not @saved.nil? |