Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[scripts][outdoorsmanship] Enforce collect practice usage exclusively #6775

Merged
2 changes: 1 addition & 1 deletion athletics.lic
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ class Athletics
start = Time.now
DRCT.walk_to(@outdoorsmanship_rooms.sample) unless @outdoorsmanship_rooms.empty?
stow_athletics_items
DRC.wait_for_script_to_complete('outdoorsmanship', [number, "room=#{Room.current.id}", 'collect', 'rock'])
DRC.wait_for_script_to_complete('outdoorsmanship', [number, "room=#{Room.current.id}", 'rock'])
remaining_pause = ((number * 15) - (Time.now - start))
pause remaining_pause if remaining_pause > 0
get_athletics_items
Expand Down
14 changes: 2 additions & 12 deletions outdoorsmanship.lic
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ class Outdoorsmanship
{ name: 'perception', regex: /perception/, optional: true, description: 'Check Perception skill in place of Outdoorsmanship' },
{ name: 'mindstates', regex: /^\d+/, optional: true, description: 'Number of mindstates or collection attempts to perform before exiting. Defaults to 3' },
{ name: 'room', regex: /(room=(\d+))/, optional: true, description: 'Specific room to forage in - primarily used to locate a trash bin. Syntax: room=1234' },
{ name: 'forage', regex: /forage|collect/, optional: true, description: 'Default method is collect, specify forage to override. Forage is best used with a trash bin.' },
{ name: 'collect_item', regex: /\w+/i, optional: true, description: 'Item to collect. Will use forage_item if not set. Wrap "multiple words" in double quotes.' }
]
]
Expand All @@ -30,7 +29,7 @@ class Outdoorsmanship
@train_method = if DRSkill.getrank('Outdoorsmanship') < 20
'forage'
else
args.forage || @settings.outdoors_method
'collect'
end
@forage_item = if DRSkill.getrank('Outdoorsmanship') < 20
'rock'
Expand All @@ -53,25 +52,16 @@ class Outdoorsmanship
attempt = 0 # Failsafe counter to prevent an infinite loop if item isn't collectable in the room
while (DRSkill.getxp(@skill_name) < @end_exp) && (attempt < @targetxp)
if @train_method == 'forage'
DRC.message("#########################################################################")
DRC.message("##############################NOTICE#####################################")
DRC.message("Using FORAGE is going to be deprecated in favor of using COLLECT PRACTICE")
DRC.message("If you are seeing this message, you should remove the line")
DRC.message("outdoors_method: forage")
DRC.message("From your yaml")
DRC.message("This functionality will be completely removed on the 28th of Feb 2024")
DRC.message("#########################################################################")
DRCA.crafting_magic_routine(@settings)
DRC.forage?(@forage_item)
DRCI.dispose_trash(@forage_item, @worn_trashcan, @worn_trashcan_verb)
attempt += 1
else
item = @forage_item
DRCA.crafting_magic_routine(@settings)
DRC.collect(item)
waitrt?
DRC.kick_pile? unless DRC.kick_pile?("#{item}")
end
attempt += 1
end
magic_cleanup
end
Expand Down
2 changes: 0 additions & 2 deletions profiles/base.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -747,8 +747,6 @@ crossing_training_requires_movement:
performance_pause: 3
# mindstate goal for performance.lic
performance_mindstate_goal: 31
# Define as `forage` to override outdoorsmanship gathering method.
outdoors_method: collect
# If you choose forage method, you'll want a room with a trash bin! Leave blank to not set a default room.
outdoors_room:
# If you choose forage method, you'll want to select a custom item for best learning rate.
Expand Down
Loading