Hunting Buddy Settings - elanthia-online/dr-scripts GitHub Wiki
Runs your hunts. For each hunt in your hunting_info, it finds an empty room in the hunt's zone, runs combat-trainer there until a stop condition is met, then moves on to the next hunt. You can have it run other scripts before, during and after each hunt. When the last hunt is done, it walks back to your safe_room and puts your normal gear back on.
Before the first hunt it runs ;restock (unless sell_loot_skip_bank: true), and if you skin and have no bundling rope or bundle, it asks your hometown's tanner for a rope.
Plugins can add to what it does: see Hunting Buddy Plugins.
hunting_info:
- :zone: orc_reivers
:duration: 60
args:
- d0
stop_on:
- Heavy Thrown
- Twohanded Edged
before:
- safe-room
after:
- sell-loot
- :zone:
- bulls_vale
- endrus_serpents
stop_on:
- First Aid
- Skinninghunting_info is a list of hunts, done in order. :zone: and :duration: start with a colon; the other keys don't. A key written the wrong way is ignored.
| Key | Purpose |
|---|---|
| :zone: | The zone to hunt in, or a list of zones, in order of preference (see Finding a room). Names come from hunting_zones or escort_zones in data/base-hunting.yaml, or your custom_hunting_zones. |
| :duration: | Minutes to hunt. Without it, the hunt only ends on one of the other stop conditions. |
| args | Arguments for combat-trainer, such as d0 (its dance threshold) or the name of an extra settings file. |
| stop_on | Skills. The hunt stops once every one of them is at or above the high threshold (see When to stop), and is skipped if they all already are. |
| stop_on_low | Skills. The hunt stops once any of them drops to stop_on_low_threshold or below, and is skipped if one already has; the message names the skills that dropped. Useful for non-combat skills you want to go and train. |
| boxes (or stop_on_boxes) |
true: skip the hunt if you have more than box_hunt_minimum boxes, and stop it when combat-trainer reaches its box_loot_limit. |
| moons (or stop_on_moons) |
true: skip or stop the hunt when no moons are visible. |
| stop_on_encumbrance | An encumbrance level from 0 (none) to 11. Skip or stop the hunt at that level or above. During the hunt it's checked once a minute. |
| stop_on_burgle_cooldown |
true: stop the hunt when your burgle cooldown ends, like stop_to_burgle but for this hunt only. |
| before | Scripts to run, one after another, before the hunt. Add arguments after the name, e.g. - safe-room force. |
| during | Scripts to start in the background when the hunt starts. They're stopped when it ends, and also if you stop hunting-buddy mid-hunt. |
| after | Scripts to run, one after another, after the hunt. |
| full_waiting_room | Room to wait in when every hunting room is taken. Defaults to your safe_room. |
| prefer_buddies |
true: look for a room with one of your hunting_buddies in it first, and only then for an empty one. A buddy's room with a nemesis is skipped, and it also has to pass hunting_buddies_max and avoid_buddies. |
| avoid_buddies |
true: don't share a room with your hunting buddies either (seen, found hiding, or named in what it hears in the room while it listens -- not inside someone's quoted speech, and not ESP, logons and the like); only take empty rooms. A buddy in your group is fine, even hidden or talking. |
| disable_room_descriptions | Turn room descriptions off during this hunt (FLAG DESCRIPTION OFF). Overrides hunting_disable_room_descriptions. |
When a hunt is skipped by stop_on, stop_on_low, moons or stop_on_encumbrance, its before scripts have already run, and its after scripts still run. A hunt skipped by boxes runs neither.
hunting_file_list:
- setup
- backBy default the hunts come from your hunting_info in <name>-setup.yaml. With hunting_file_list, or file names given as arguments (;hunting-buddy back), it reads hunting_info from each of those files (<name>-back.yaml and so on) and does all their hunts in order. Each hunt from a file other than setup passes that file's name to combat-trainer, so combat-trainer uses that file's settings too.
safe_room: 851
hunting_buddies:
hunting_buddies_max: 2
hunting_nemesis:
empty_hunting_room_messages:
hunting_room_min_mana: 0
hunting_room_strict_mana: false
hunting_room_max_searches: 30
custom_hunting_zones:
my_zone:
- 1234
- 1235| Setting | Default | Purpose |
|---|---|---|
| safe_room | 851 | Where it goes after the last hunt, and where it waits when every room is taken (unless the hunt has a full_waiting_room). |
| hunting_buddies | Friends you're happy to share a room with. If you both list each other, you can hunt together. | |
| hunting_buddies_max | 2 | Skip a room with more people than this in it. |
| hunting_nemesis | People you never share a room with. | |
| empty_hunting_room_messages | Things to say when you walk into a room that looks empty; one is picked at random. Leave it blank to say nothing. Hearing your own line back doesn't count as someone talking. | |
| hunting_room_min_mana | 0 | Prefer rooms with at least this much mana (by perceiving). If none of the empty rooms have it, it uses an empty room anyway. Not checked for Moon Mages or Traders. |
| hunting_room_strict_mana | false | With hunting_room_min_mana, only take a room with enough mana (an escort zone fallback still applies; see below). |
| hunting_room_max_searches | 30 | How many times to go round the zone looking for a room before giving up on the hunt. Between rounds it waits 20 to 40 seconds in the waiting room. |
| custom_hunting_zones | Your own zones: a name and a list of room ids (or a single room id). A name that's also in data/base-hunting.yaml replaces that zone; an entry with no rooms (blank or []) doesn't. |
It only looks for a room on the first hunt, and when a hunt's zones don't include the one you're already standing in (your custom_hunting_zones count). It walks the rooms of the hunt's zones in order, and takes the first suitable one:
- Too many people (
hunting_buddies_max), or a nemesis: skip it. - A hunting buddy is there (unless
avoid_buddies): take it. - Anyone else who isn't in your group: skip it.
- Otherwise it SEARCHes for hidden people. If it finds signs of someone, it only takes the room if that's a buddy who speaks up (never with
avoid_buddies). - It says one of your
empty_hunting_room_messages, then listens for about 10 seconds. If someone else talks or attacks, it skips the room; if a buddy speaks (unlessavoid_buddies), or nobody does, it takes it.
If it's too injured to search, it stops all hunting.
Escort zones (in escort_zones in data/base-hunting.yaml) are entered with ;bescort and left the same way after the hunt; they aren't checked for people, so entering one always succeeds.
How the :zone: list is used:
- If the first zone is an escort zone, it takes that escort, and the other zones aren't used.
- Otherwise it searches the rooms of all the ordinary zones together, in list order. If that search gives up (after
hunting_room_max_searchesrounds), it takes the escort into the first escort zone in the list, if there is one -- unless hunting was stopped meanwhile. Escort zones aren't checked for mana, so this fallback applies even withhunting_room_strict_mana.
So [rats, goblins] searches both; [rats, ship, goblins] searches rats and goblins, then falls back to the ship escort; [ship, rats] always takes the ship escort. A custom_hunting_zones entry with an escort zone's name is your custom zone, not the escort. ;validate warns when a list has escort zones it can never use.
If no room is found and there is no escort zone to fall back on, that hunt is skipped without its after scripts, and it moves on to the next. If none of the hunt's zones exist, it tells you and stops; an empty :zone: list just skips the hunt.
stop_on_high_threshold: 32
stop_on_low_threshold: 2
armor_exp_training_max_threshold: 32
weapon_exp_training_max_threshold: 32
magic_exp_training_max_threshold: 32
survival_exp_training_max_threshold: 32
lore_exp_training_max_threshold: 32
stop_to_burgle: false
box_hunt_minimum: 1| Setting | Default | Purpose |
|---|---|---|
| stop_on_high_threshold | 32 | The mindstate a stop_on skill must reach. |
| <skillset>_exp_training_max_threshold | 32 | A separate threshold per skillset (armor, weapon, magic, survival, lore). Only used when stop_on_high_threshold is blank: base.yaml sets it to 32, which applies to every skill. To use these, add stop_on_high_threshold: with nothing after it to your YAML. ;validate warns when stop_on_high_threshold hides one of these set to a different value. magic_exp_training_max_threshold is also used by combat-trainer and magic-training either way. |
| stop_on_low_threshold | 2 | The mindstate at or below which a stop_on_low skill ends the hunt. |
| stop_to_burgle | false | Stop every hunt when your burgle cooldown ends. |
| box_hunt_minimum | 1 | With boxes: true, only hunt while you have this many boxes or fewer. |
A hunt stops when any of these happens:
- its
:duration:is up; - all its
stop_onskills reach the high threshold, or anystop_on_lowskill drops to the low threshold; - its
boxes,moons,stop_on_encumbranceor burgle condition is met; - you start bleeding, or a familiar drags you out (see Safety);
- you stop it yourself (see Usage);
- a plugin ends it.
If you raised a Yiamura in the hunting room in the last 10 minutes, it keeps hunting past the duration, skill and burgle stops until those 10 minutes are up.
Once a minute it tells you how long is left, or which stop_on skills are still below the threshold.
stop_hunting_if_bleeding: true
stop_on_familiar_drag: false
health_threshold: 0| Setting | Default | Purpose |
|---|---|---|
| stop_hunting_if_bleeding | true | Stop the hunt when you start bleeding, and skip the rest of the hunts. hunting-buddy stops on any bleed; the heal-over-time grace described in base.yaml is combat-trainer's own check. |
| stop_on_familiar_drag | false | When a familiar drags you out of combat while you're stunned: true ends the hunt, false takes you back to the hunting room and carries on. |
| health_threshold | 0 | If your health drops below this, it AVOIDs ALL and EXITs, logging you out of the game. 0 never does. Also read by combat-trainer. |
waggle_sets:
prehunt_buffs:
prehunt_buff_waggle: prehunt_buffs
prehunt_buffing_room:
cyclic_no_release:
combat_trainer_gear_set:
hunting_disable_room_descriptions: false| Setting | Default | Purpose |
|---|---|---|
| prehunt_buff_waggle | prehunt_buffs | The waggle set to cast (with ;buff) before each hunt, if you have one. ;validate warns if you have it but no prehunt_buffing_room, or if you named a set you don't have. |
| prehunt_buffing_room | Room to walk to for those buffs. Blank: cast them where you are. | |
| cyclic_no_release | Cyclic spells not to release after a hunt. Every other cyclic is released. | |
| combat_trainer_gear_set | standard | The gear set it puts on after the last hunt. |
| hunting_disable_room_descriptions | false | Turn room descriptions off during hunts, and back on afterwards. |
There are no settings for these; this is what to expect.
- Skips the hunt if you have enough boxes (
boxes). - Runs the
beforescripts. - Skips the hunt for
moons,stop_on_encumbrance,stop_onorstop_on_low(running theafterscripts). - Casts your pre-hunt buffs.
- Finds a room, if it needs to. If that search found you too injured to go on and bleeding, it retreats and stops all hunting (running the
afterscripts). - Starts the
duringscripts, then combat-trainer with the hunt'sargs. - Checks the stop conditions every second until one is met.
- Stops combat-trainer, retreats, and stops the
duringscripts. If both your hands are full, it puts away what's in your left hand, then picks up anything at your feet. - Leaves an escort zone, if it's in one, and releases your cyclic spells.
- Runs the
afterscripts.
If you stop hunting-buddy, it stops combat-trainer and the current hunt's during scripts, releases your cyclic spells and turns room descriptions back on.
| Argument | Purpose |
|---|---|
| file names | Read hunting_info from these settings files (<name>-<file>.yaml) instead of hunting_file_list, and use their settings too. |
;hunting-buddy
;hunting-buddy back
While it's running:
| Command | Purpose |
|---|---|
;e $HUNTING_BUDDY.next_hunt |
End the current hunt and move on to the next. |
;e $HUNTING_BUDDY.stop_hunting |
End the current hunt and skip the rest. |
;e $debug_mode_hunting = true |
Show debug messages. Set it before starting to see how your settings and each hunt were read. |
Run ;validate to check your hunts: it catches unknown zone names, unknown stop_on skills, hunts with neither a duration nor a stop condition, and thresholds hidden by stop_on_high_threshold.
training_list:
- skill:
- Shield Usage
- Parry Ability
- Small Edged
name: Weapons
start: 10
scripts:
- hunting-buddy