Advertisement
intangibles

Untitled

Jun 4th, 2016
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 2.32 KB | None | 0 0
  1. [sbounty: location inside if statement: Rift]
  2. [sbounty: location after downcase rift]
  3.  
  4. [sbounty: name: Rift - Plane 3]
  5. [sbounty: data: {:enable_bounty_only=>false, :enable_hunting_rotation=>true, :enable_search_only=>false, :location=>"Rift", :skins=>["gizzard"], :targets=>["aivren(c)"], :room=>"12093", :boundaries=>["99999999"]}]
  6. [sbounty: Rift]
  7. [sbounty: String]
  8. [sbounty: test: aivren(c)]
  9. [sbounty: cleaning targets: ["aivren(c)"]]
  10. [sbounty: location inside locations.find: rift]
  11. [sbounty: location outside locations.find: ]
  12. --- Lich: sbounty has exited.
  13.  
  14.  
  15. if bounty? =~ /#{bounty_patterns['task_skin']}/
  16.         # remember: don't swap the order or the global $ vars are lost!
  17.         target   = $3.strip.downcase
  18.         skin     = clean_skin.call($2)
  19.         location = locations.find { |name, data| GSC.SBOUNTY_CLEAN_TARGETS(data[:targets]).find { |t| target =~ /#{t}/i } and data[:skins].find { |s| skin =~ /#{s.strip.downcase}/i }}
  20.     else
  21.         echo "inside if-else of get_bounty_location- if bounty?" if $sbounty_debug
  22.         bounty_patterns.each { |key,value|
  23.             echo "key: #{key}" if $sbounty_debug
  24.             echo "value: #{value}" if $sbounty_debug
  25.             echo bounty? if $sbounty_debug
  26.             if bounty? =~ /#{value}/i
  27.                 target   = $1
  28.                 location = $2
  29.  
  30.                 break
  31.             end
  32.         }
  33.         echo "location inside if statement: #{location}" if $sbounty_debug
  34.         location = location.downcase.strip
  35.         echo "location after downcase #{location}" if $sbounty_debug
  36.         location = locations.find { |name, data|
  37.             echo "name: #{name}" if $sbounty_debug
  38.             echo "data: #{data}" if $sbounty_debug
  39.             echo data[:location].strip if $sbounty_debug
  40.             echo data[:location].class if $sbounty_debug
  41.             echo data[:targets] if $sbounty_debug
  42.             location =~ /#{data[:location].strip}/i and GSC.SBOUNTY_CLEAN_TARGETS(data[:targets]).find {|t| target =~ /#{t}/i}
  43.             echo "cleaning targets: #{GSC.SBOUNTY_CLEAN_TARGETS(data[:targets])}" if $sbounty_debug
  44.             echo "location inside locations.find: #{location}" if $sbounty_debug
  45.         }
  46.         echo "location outside locations.find: #{location}" if $sbounty_debug
  47.     end
  48.  
  49.     echo "location: #{location}" if $sbounty_debug
  50.     exit
  51.     if location
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement