diff options
Diffstat (limited to 'lib/evendoors/room.rb')
-rw-r--r-- | lib/evendoors/room.rb | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/lib/evendoors/room.rb b/lib/evendoors/room.rb index b7f6844..aa1e7d1 100644 --- a/lib/evendoors/room.rb +++ b/lib/evendoors/room.rb @@ -66,12 +66,12 @@ module EvenDoors end # def start! - puts " * start #{path}" if spin.debug_routing + puts " * start #{path}" if @spin.debug_routing @spots.values.each do |spot| spot.start! if spot.respond_to? :start! end end # def stop! - puts " * stop #{path}" if spin.debug_routing + puts " * stop #{path}" if @spin.debug_routing @spots.values.each do |spot| spot.stop! if spot.respond_to? :stop! end end # @@ -86,7 +86,7 @@ module EvenDoors end # def try_links p - puts " -> try_links ..." if spin.debug_routing + puts " -> try_links ..." if @spin.debug_routing links = @links[p.src.name] return false if links.nil? pending_link = nil @@ -97,7 +97,7 @@ module EvenDoors if apply_link or (p.link_value==link.cond_value) # link matches ! if pending_link - p2 = spin.require_p p.class + p2 = @spin.require_p p.class p2.clone_data p p2.apply_link! link send_p p2 @@ -130,10 +130,10 @@ module EvenDoors end # def send_p p - puts " * send_p #{(p.next_dst.nil? ? 'no dst' : p.next_dst)} ..." if spin.debug_routing + puts " * send_p #{(p.next_dst.nil? ? 'no dst' : p.next_dst)} ..." if @spin.debug_routing if p.src.nil? # do not route orphan particles !! - p.error! EvenDoors::ERROR_ROUTE_NS, spin + p.error! EvenDoors::ERROR_ROUTE_NS, @spin elsif p.next_dst p.split_dst! if p.door @@ -147,31 +147,31 @@ module EvenDoors else p.error! EvenDoors::ERROR_ROUTE_NDNL end - puts " -> #{p.dst.path}#{EvenDoors::ACT_SEP}#{p.action}" if spin.debug_routing - spin.send_p p + puts " -> #{p.dst.path}#{EvenDoors::ACT_SEP}#{p.action}" if @spin.debug_routing + @spin.send_p p end # def send_sys_p p - puts " * send_sys_p #{(p.next_dst.nil? ? 'no dst' : p.next_dst)} ..." if spin.debug_routing + puts " * send_sys_p #{(p.next_dst.nil? ? 'no dst' : p.next_dst)} ..." if @spin.debug_routing if p.next_dst p.split_dst! if p.door route_p p elsif p.action - p.dst_routed! spin + p.dst_routed! @spin end else p.error! EvenDoors::ERROR_ROUTE_SND end - puts " -> #{p.dst.path}#{EvenDoors::ACT_SEP}#{p.action}" if spin.debug_routing - spin.send_sys_p p + puts " -> #{p.dst.path}#{EvenDoors::ACT_SEP}#{p.action}" if @spin.debug_routing + @spin.send_sys_p p end # def process_sys_p p if p.action==EvenDoors::SYS_ACT_ADD_LINK add_link EvenDoors::Link.from_particle_data p end - spin.release_p p + @spin.release_p p end # end |