# File format.rb, line 1330 def readFormat (output) @var_values = Hash.new output_line = 0 while (output_line < output.length) @pictures.each_index do |i| repeat = true while (repeat) found_match = setLine( @pictures[i], output[output_line] ) repeat = false #default to stopping if (found_match) output_line += 1 end #we may need to repeat if it's a ~~ line if (@pictures[i].repeat() && found_match) repeat = true end end #while end if block_given? yield @var_values @var_values = Hash.new else return @var_values end end end