From 79298fa9b69b3d7fb0548c1bbcfefd78a52019d9 Mon Sep 17 00:00:00 2001 From: "Ryan P. McKinnon" <15917743+mrhoribu@users.noreply.github.com> Date: Tue, 27 Jan 2026 09:13:24 -0500 Subject: [PATCH 1/9] fix(ebounty.lic): v1.9.2 expand CLI forage options --- scripts/ebounty.lic | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/scripts/ebounty.lic b/scripts/ebounty.lic index 474089510..23a52fd70 100644 --- a/scripts/ebounty.lic +++ b/scripts/ebounty.lic @@ -10,10 +10,13 @@ game: Gemstone tags: bounty, adventure's guild, advguild, bounties required: Lich >= 5.12.10 - version: 1.9.1 + version: 1.9.2 Version Control: Major_change.feature_addition.bugfix + v1.9.2 (2025-01-27) + - add CLI support for ;ebounty forage bounty + - add CLI support for ;ebounty forage "herb" "location" v1.9.1 (2025-01-18) - bugfix for running gem tracking script v1.9.0 (2025-01-08) @@ -3675,14 +3678,24 @@ when 'remove' EBounty::Task.bounty_remove(true) EBounty.go2(EBounty.data.start_room) when 'forage' - if Script.current.vars[2].nil? || Script.current.vars[3].nil? - EBounty.msg "error", ' Proper syntax: ;ebounty forage "herb to find" ' + if Script.current.vars[2].nil? || (Script.current.vars[3].nil? && Script.current.vars[2] != 'bounty') + EBounty.msg "error", ' Please use one of the following proper syntax for the forage option:" + EBounty.msg "error", ' To search closest 10 rooms for foraged herb:' + EBounty.msg "error", ' Autodetect Bounty: ;ebounty forage bounty' + EBounty.msg "error", ' Closest 10 Rooms: ;ebounty forage "herb to find" ' + EBounty.msg "error", ' All Rooms At Location: ;ebounty forage "herb to find" "location to search"' exit end return_room = Room.current.id EBounty.load(EBounty.load_profile) EBounty.set_variables(load_profile: false) - EBounty::Task.forage_bounty(Script.current.vars[2], Script.current.vars[3].to_i) + if Script.current.vars[2] == 'bounty' && Bounty.task.herb? + EBounty::Task.forage_bounty(Bounty.task.herb, Bounty.task.number, Bounty.task.area) + elsif Script.current.vars[4].is_a?(String) + EBounty::Task.forage_bounty(Script.current.vars[2], Script.current.vars[3].to_i, Script.current.vars[4]) + else + EBounty::Task.forage_bounty(Script.current.vars[2], Script.current.vars[3].to_i) + end EBounty.go2(return_room) when /location/i if Bounty.task.requirements[:area].nil? From 2fbc5892f52fc3c0a6d72fae6720e17c0a91787c Mon Sep 17 00:00:00 2001 From: "Ryan P. McKinnon" <15917743+mrhoribu@users.noreply.github.com> Date: Tue, 27 Jan 2026 09:16:02 -0500 Subject: [PATCH 2/9] fix: syntax typo --- scripts/ebounty.lic | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ebounty.lic b/scripts/ebounty.lic index 23a52fd70..4f7e46d78 100644 --- a/scripts/ebounty.lic +++ b/scripts/ebounty.lic @@ -3679,7 +3679,7 @@ when 'remove' EBounty.go2(EBounty.data.start_room) when 'forage' if Script.current.vars[2].nil? || (Script.current.vars[3].nil? && Script.current.vars[2] != 'bounty') - EBounty.msg "error", ' Please use one of the following proper syntax for the forage option:" + EBounty.msg "error", ' Please use one of the following proper syntax for the forage option:' EBounty.msg "error", ' To search closest 10 rooms for foraged herb:' EBounty.msg "error", ' Autodetect Bounty: ;ebounty forage bounty' EBounty.msg "error", ' Closest 10 Rooms: ;ebounty forage "herb to find" ' From d3df14a1141d33fb54e8b45ebb98b16771c14343 Mon Sep 17 00:00:00 2001 From: "Ryan P. McKinnon" <15917743+mrhoribu@users.noreply.github.com> Date: Tue, 27 Jan 2026 18:47:19 -0500 Subject: [PATCH 3/9] fix: swap checkpcs to Claim.mine? for forage/heirloom search --- scripts/ebounty.lic | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/scripts/ebounty.lic b/scripts/ebounty.lic index 4f7e46d78..1dd5e3ca7 100644 --- a/scripts/ebounty.lic +++ b/scripts/ebounty.lic @@ -17,6 +17,7 @@ v1.9.2 (2025-01-27) - add CLI support for ;ebounty forage bounty - add CLI support for ;ebounty forage "herb" "location" + - bugfix in heirloom_search and forage_bounty to use Claim.mine? instead of checkpcs v1.9.1 (2025-01-18) - bugfix for running gem tracking script v1.9.0 (2025-01-08) @@ -3017,7 +3018,7 @@ module EBounty location_list.each do |room| EBounty.go2(room) - unless (GameObj.targets.count.positive? && EBounty.data.settings[:forage_options].include?("run")) || checkpcs || GameObj.loot.any? { |i| i.name =~ /black void/ } + unless (GameObj.targets.count.positive? && EBounty.data.settings[:forage_options].include?("run")) || !Claim.mine? || GameObj.loot.any? { |i| i.name =~ /black void/ } empty_hands @@ -3365,7 +3366,7 @@ module EBounty EBounty.change_stance(100) loop { - unless (GameObj.targets.count.positive? && EBounty.data.settings[:heirloom_options].include?("run")) || checkpcs || GameObj.loot.each { |i| i.name =~ /black void/ } + unless (GameObj.targets.count.positive? && EBounty.data.settings[:heirloom_options].include?("run")) || !Claim.mine? || GameObj.loot.each { |i| i.name =~ /black void/ } unless Map.current.tags.include?("meta:nomagic") if Stats.prof =~ /Cleric|Empath/i && EBounty.data.settings[:heirloom_options].include?("use_213") lines = EBounty.get_command("sense", /You open your soul to the lesser/, silent: true, quiet: true) From f362017deb7dfc65d18917981fe45502dacd33c9 Mon Sep 17 00:00:00 2001 From: "Ryan P. McKinnon" <15917743+mrhoribu@users.noreply.github.com> Date: Wed, 28 Jan 2026 17:16:38 -0500 Subject: [PATCH 4/9] fix: anchor ending gem names in search functions to prevent false matching on other items --- scripts/ebounty.lic | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/scripts/ebounty.lic b/scripts/ebounty.lic index 1dd5e3ca7..372bb3529 100644 --- a/scripts/ebounty.lic +++ b/scripts/ebounty.lic @@ -18,6 +18,7 @@ - add CLI support for ;ebounty forage bounty - add CLI support for ;ebounty forage "herb" "location" - bugfix in heirloom_search and forage_bounty to use Claim.mine? instead of checkpcs + - anchor ending gem names in search functions to prevent false matching on other items v1.9.1 (2025-01-18) - bugfix for running gem tracking script v1.9.0 (2025-01-08) @@ -2075,7 +2076,7 @@ module EBounty bounty_eval += %Q{ || !!(count = 0;EBounty.data.containers.each{|i| i.contents.each{ |k| if k.name =~ /bundle of #{EBounty.data.bundle_skin}/ && !EBounty.data.bundle_skin.to_s.empty? && !hidden?; lines = Lich::Util.quiet_command_xml("measure #"+k.id.to_s, /You glance through/);count += lines.sum { |l| l.scan(/count a total of (\\d+) = EBounty.data.remaining_skins.to_i && @CORRECT_PERCENT_MIND >= EBounty.data.complete_mind)} bounty_eval += %Q{ || !!(j=0;EBounty.data.containers.each{|i| j += i.contents.count{|l| l.name =~ /#{EBounty.data.skin}/i && !EBounty.data.skin.to_s.empty?}.to_i }; j >= EBounty.data.remaining_skins.to_i && @CORRECT_PERCENT_MIND >= EBounty.data.complete_mind)} elsif checkbounty =~ /The gem dealer/ - bounty_eval += %Q{ || !!(t=0;EBounty.data.containers.each{|k| t += k.contents.count{|v| v.name =~ /#{EBounty.data.gem.strip}/i && !EBounty.data.gem.to_s.empty?}.to_i}; t>= EBounty.data.remaining_gems.to_i && @CORRECT_PERCENT_MIND >= EBounty.data.complete_mind)} + bounty_eval += %Q{ || !!(t=0;EBounty.data.containers.each{|k| t += k.contents.count{|v| v.name =~ /#{EBounty.data.gem.strip}$/i && !EBounty.data.gem.to_s.empty?}.to_i}; t>= EBounty.data.remaining_gems.to_i && @CORRECT_PERCENT_MIND >= EBounty.data.complete_mind)} end UserVars.op['bounty_eval'] = bounty_eval @@ -3292,7 +3293,7 @@ module EBounty EBounty.data.containers.each { |container| EBounty.open_container(container) container.contents.each { |item| - if item.name =~ /#{EBounty.data.gem}/ + if item.name =~ /#{EBounty.data.gem}$/ count += 1 end } From 1a0e72861eea73c482f956bef261d9284052facb Mon Sep 17 00:00:00 2001 From: "Ryan P. McKinnon" <15917743+mrhoribu@users.noreply.github.com> Date: Wed, 28 Jan 2026 18:31:00 -0500 Subject: [PATCH 5/9] fix: SG resting spot shattered --- scripts/ebounty.lic | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/scripts/ebounty.lic b/scripts/ebounty.lic index 372bb3529..44fc76232 100644 --- a/scripts/ebounty.lic +++ b/scripts/ebounty.lic @@ -19,6 +19,7 @@ - add CLI support for ;ebounty forage "herb" "location" - bugfix in heirloom_search and forage_bounty to use Claim.mine? instead of checkpcs - anchor ending gem names in search functions to prevent false matching on other items + - fix resting spot for SG shattered v1.9.1 (2025-01-18) - bugfix for running gem tracking script v1.9.0 (2025-01-08) @@ -1032,7 +1033,7 @@ module EBounty "Wehnimer's Landing" => 'u7120', 'Zul Logoth' => 'u13006016', 'Cold River' => 'u7503205', - "Contempt" => 'u7150608', + "Contempt" => "#{XMLData.game.eql?('GSF') ? 'u7150607' : 'u7150608'}", } resting_keys = [ @@ -1070,8 +1071,12 @@ module EBounty "u7120" => @settings[:landing_resting], # Wehnimer's Landing "u13006016" => @settings[:zul_resting], # Zul Logoth 'u7503205' => @settings[:hw_resting], # Hinterwilds - 'u7150608' => @settings[:contempt_resting], # Sailor's Grief } + if XMLData.game.eql?('GSF') + @resting_spots['u7150607'] = @settings[:contempt_resting] # Sailor's Grief Shattered + else + @resting_spots['u7150608'] = @settings[:contempt_resting] # Sailor's Grief + end end end From 1999db6105cb50c0078fca71b4a077b08286b521 Mon Sep 17 00:00:00 2001 From: "Ryan P. McKinnon" <15917743+mrhoribu@users.noreply.github.com> Date: Thu, 29 Jan 2026 18:20:19 -0500 Subject: [PATCH 6/9] fix: forage tag in starting room crash --- scripts/ebounty.lic | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/scripts/ebounty.lic b/scripts/ebounty.lic index 44fc76232..d3cfce962 100644 --- a/scripts/ebounty.lic +++ b/scripts/ebounty.lic @@ -20,6 +20,7 @@ - bugfix in heirloom_search and forage_bounty to use Claim.mine? instead of checkpcs - anchor ending gem names in search functions to prevent false matching on other items - fix resting spot for SG shattered + - fix forage tag in starting room crash v1.9.1 (2025-01-18) - bugfix for running gem tracking script v1.9.0 (2025-01-08) @@ -2954,7 +2955,8 @@ module EBounty location_list = location_list.first(10) location_list.each do |room| - if Room.current.path_to(room) == nil + next if room.id.eql?(Room.current.id) + if Room.current.path_to(room).nil? location_list.delete(room) else travel = Map.estimate_time(Room.current.path_to(room)) @@ -2975,8 +2977,13 @@ module EBounty location_list = location_list.sort { |a, b| shortest_distances[a] <=> shortest_distances[b] } location_list.each do |room| - travel = Map.estimate_time(Room.current.path_to(room)) - location_list.delete(room) if travel.to_i > 90 + next if room.id.eql?(Room.current.id) + if Room.current.path_to(room).nil? + location_list.delete(room) + else + travel = Map.estimate_time(Room.current.path_to(room)) + location_list.delete(room) if travel.to_i > 90 + end end return location_list From 83999a4232c984167b3b4ca18e70ca0ef806796e Mon Sep 17 00:00:00 2001 From: "Ryan P. McKinnon" <15917743+mrhoribu@users.noreply.github.com> Date: Fri, 30 Jan 2026 09:43:05 -0500 Subject: [PATCH 7/9] fix: between script(s) added erroneous commas between script parameters --- scripts/ebounty.lic | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/scripts/ebounty.lic b/scripts/ebounty.lic index d3cfce962..91ae46041 100644 --- a/scripts/ebounty.lic +++ b/scripts/ebounty.lic @@ -21,6 +21,7 @@ - anchor ending gem names in search functions to prevent false matching on other items - fix resting spot for SG shattered - fix forage tag in starting room crash + - fix between script(s) added erroneous commas between script parameters v1.9.1 (2025-01-18) - bugfix for running gem tracking script v1.9.0 (2025-01-08) @@ -649,7 +650,7 @@ module EBounty scripts.split(/,\s*/).each do |i| tokens = i.split(/\s+/) if (tokens.size > 1) - Script.run(tokens[0], tokens[1..-1].join(", ")) + Script.run(tokens[0], tokens[1..-1].join(" ")) else Script.run(tokens[0]) end @@ -2195,7 +2196,7 @@ module EBounty EBounty.msg("debug", "scripts: #{i}") tokens = i.split(/\s+/) if (tokens.size > 1) - Script.run(tokens[0], tokens[1..-1].join(", ")) + Script.run(tokens[0], tokens[1..-1].join(" ")) else Script.run(tokens[0]) end From 603326cf25a77b0b1d14467b4554430056d087ab Mon Sep 17 00:00:00 2001 From: "Ryan P. McKinnon" <15917743+mrhoribu@users.noreply.github.com> Date: Fri, 30 Jan 2026 16:32:27 -0500 Subject: [PATCH 8/9] fix rubocop --- scripts/ebounty.lic | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ebounty.lic b/scripts/ebounty.lic index 91ae46041..abe166314 100644 --- a/scripts/ebounty.lic +++ b/scripts/ebounty.lic @@ -21,7 +21,7 @@ - anchor ending gem names in search functions to prevent false matching on other items - fix resting spot for SG shattered - fix forage tag in starting room crash - - fix between script(s) added erroneous commas between script parameters + - fix between script(s) added erroneous commas between script parameters v1.9.1 (2025-01-18) - bugfix for running gem tracking script v1.9.0 (2025-01-08) From 7accbdc9cbea4184ac737b576dfd72bfd58b6b61 Mon Sep 17 00:00:00 2001 From: "Ryan P. McKinnon" <15917743+mrhoribu@users.noreply.github.com> Date: Sat, 31 Jan 2026 16:27:07 -0500 Subject: [PATCH 9/9] fix: forage bounty exit if no forage bounty --- scripts/ebounty.lic | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/scripts/ebounty.lic b/scripts/ebounty.lic index abe166314..b9d0ca4b3 100644 --- a/scripts/ebounty.lic +++ b/scripts/ebounty.lic @@ -3704,7 +3704,13 @@ when 'forage' return_room = Room.current.id EBounty.load(EBounty.load_profile) EBounty.set_variables(load_profile: false) - if Script.current.vars[2] == 'bounty' && Bounty.task.herb? + if Script.current.vars[2] == 'bounty' + unless Bounty.task.herb? + EBounty.msg "error", ' Started ebounty with ;ebounty forage bounty' + EBounty.msg "error", ' But you have no bounty!' + EBounty.msg "error", " #{Bounty.task.inspect}" + exit + end EBounty::Task.forage_bounty(Bounty.task.herb, Bounty.task.number, Bounty.task.area) elsif Script.current.vars[4].is_a?(String) EBounty::Task.forage_bounty(Script.current.vars[2], Script.current.vars[3].to_i, Script.current.vars[4])