BeachComber - fast and efficient beach combing

Veracity

Developer
Staff member
Revision 193 will log Meat.
Revision 194 will save page HTML not only for messages in bottles, but also for beached whales and rainbow pearls (another forum rumor).
 

Veracity

Developer
Staff member
Huh. Maybe I should do it for the cursed pirate stuff, too, since I am curious to see what it tells you when it unearths such. I bet there is something more (or at least different) than for less-special rough sand.
 

Veracity

Developer
Staff member
Revision 195 saves the HTML if you comb an unknown square type or find cursed pirate gear.

Eventually, some of these will result in tweaks to the code (unknown square types, extracting messages from bottles, etc.) but they all will still be worth calling out in red, even if we don't save the page HTML any more.
 

Veracity

Developer
Staff member
Revision 196 saves the page HTML before combing for whales and unknown square types and after combing for both of those as well as bottle messages, rainbow pearls, and cursed pirate gear.
 

Veracity

Developer
Staff member
Revision 197 uses my new "buffer_to_file" function to save the HTML files, rather than putting the HTML into a map and using "map_to_file".
The latter works, but it escape newlines, tabs, and backslashes, so it's harder for human eyes to look at, in my opinion.

This means that you'll need to upgrade to r19439 in order to use this script now. That came out a couple of days ago.

I'll be publishing a new point release this weekend, for people who don't use daily builds. :)
 

Yendor

Member
Ran into problems when I randomly hit 1 minute; the script kept trying to comb the previous area.

Code:
Took choice 1388/2: (secret choice)
choice.php?whichchoice=1388&option=2&pwd
Encounter: Comb the Beach (6333 minutes down the beach)
> 1 squares in beach 6333 contain a sand castle
> 3 squares in beach 6333 contain combed sand
> 86 squares in beach 6333 contain rough sand
> Combing the square at coordinates 5,63321 which contains rough sand
Took choice 1388/4: (secret choice)
choice.php?whichchoice=1388&option=4&coords=5%2C63321
Encounter: Comb the Beach
You acquire an item: magenta seashell
You acquire grain of sand (3)
Took choice 1388/2: (secret choice)
choice.php?whichchoice=1388&option=2&pwd
Encounter: Comb the Beach (1 minute down the beach)
> 1 squares in beach 6333 contain a sand castle
> 3 squares in beach 6333 contain combed sand
> 86 squares in beach 6333 contain rough sand
> Combing the square at coordinates 5,63327 which contains rough sand
Took choice 1388/4: (secret choice)
choice.php?whichchoice=1388&option=4&coords=5%2C63327
Encounter: Comb the Beach (1 minute down the beach)
Took choice 1388/2: unknown
choice.php?whichchoice=1388&option=2&pwd
Encounter: Comb the Beach (1 minute down the beach)
> 1 squares in beach 6333 contain a sand castle
> 3 squares in beach 6333 contain combed sand
> 86 squares in beach 6333 contain rough sand
> Combing the square at coordinates 5,63324 which contains rough sand

(and so on)

I manually combed the area like so:
Code:
Encounter: Comb the Beach (1 minute down the beach)
Took choice 1388/4: (secret choice)
choice.php?whichchoice=1388&pwd&option=4&coords=2%2C1
Encounter: Comb the Beach
You acquire an item: sea carrot
You acquire grain of sand (3)
 

Veracity

Developer
Staff member
Ha. I’m away from my computer now, but I bet that Kolmafa is looking to match “XXX minutes down the beach” and it is “1 minute”.
 

Veracity

Developer
Staff member
Yup. Adding one character to the Pattern:

Code:
[color=green]> beach wander 1[/color]

Encounter: Comb the Beach
Encounter: Comb the Beach (1 minute down the beach)
Beach at 1

10: crrcrrrrrr
9: rrrcrcrrcr
8: rccrcrrcrr
7: rrccrcccrr
6: rrrcrrrcrc
5: crcrcrrrcc
4: crrrcrcccc
3: rcrrcrrccr
2: rrrcccrrrr

[color=green]> beach comb 2 0[/color]

Encounter: Comb the Beach
You acquire an item: bunch of sea grapes
You acquire grain of sand (3)
Kolmafia revision 19462
 

Magus_Prime

Well-known member
Would you be willing to incorporate a call to this script from VMF? Perhaps with the default being "free" but with the option to configure an arbitrary number of turns or beach head?
 

Veracity

Developer
Staff member
Here's what I found today:
... a message in a bottle ...
Well, that's cool!

The script should have saved the HTML in a file. Presumably, that is what you looked at to get that image?

Could you upload/attach that file, please? I'd like to look at it to figure out how we can parse out the message and log that separately.

Thanks!
 

Veracity

Developer
Staff member
Revision 202 tracks number of actual turns spent combing the beach today (using this script) in _VBC.TurnsSpentCombing
 

Veracity

Developer
Staff member
Whew! Just noticed that I found a bottle a couple weeks ago during my 11 free daily combings.

Code:
Encounter: Comb the Beach (3676 minutes down the beach)
> 1 squares in beach 3676 contain combed sand
> 99 squares in beach 3676 contain rough sand
> Combing the square at coordinates 4,36755 which contains rough sand
Took choice 1388/4: (secret choice)
choice.php?whichchoice=1388&option=4&coords=4%2C36755
Encounter: Comb the Beach
> You found a message in a bottle!
> Saving page HTML to Veracity_beachcombings_20191127151821207.txt
and at the end, where I reported on what was found:

Code:
> Special beach combings saved::
> Veracity_beachcombings_20191127151821207.txt
Seems to be the same message I've seen reported elsewhere.
Good to see that my automatic "save the HTML" feature works as expected.
 

Arashmin

New member
This also presently borks the script, since it doesn't recognize these gifs. Also means the logic of the script may need to be revised to prioritize twinkles/rares.

I guess so few thought about the Sea since it's been a while, until we were pulled back under.
 

Veracity

Developer
Staff member
Yeah.

Revision 19656 of KoLmafia will put a 't' in the _beachLayout for "rough sand with a twinkle".
Revision 213 of (my scripts) makes BeachComber.ash recognize - and prioritize - 't' squares.
It is configurable:

Code:
// How to prioritize beach squares to comb
//
// W	a beached whale
// ?	an unclassifiable square
// C	a sand castle
// r	rough sand
// t	rough sand with a twinkle
// c	combed sand
// H	a beach head
//
// We think there are fixed set of 11 beach heads, and if you want to
// visit, you can do that manually, so they are not prioritized by
// default. If you want a random buff rather than items, add them.
//
// We do not expect any unidentifiable square. If KoLmafia finds a
// square it cannot classify, it will log it in the gCLI and session log
// and return a "?". This script assumes such squares are worth visiting.

string_list priorities = define_property( "VBC.Priorities", "string", "W,?,t,r,c", "list" ).to_list_of_string( "," );
... the only differences being that I added the "t" to the list of square types and added it near the front of the default square priority.

Fortunately, my multi with a Beach Comb had rescued Grandpa and was able to test this.
My main hasn't even rescued Little Brother yet in this run.

I guess she'll rescue Grandpa tomorrow before doing Crimbo stuff so she can unlock this feature. :)
 

fredg1

Member
Is it possible to add a feature to let you only use a certain amount of your free combings? (For if you plan to comb some beach heads later on)

At first I just added modifications to the script myself without bothering anyone, but the update undid them =(
 

fronobulax

Developer
Staff member
At first I just added modifications to the script myself without bothering anyone, but the update undid them =(

Where were your changes? If you edit the version in scripts then that is expected. If you edit the version in svn/veracity0-beach the SVN features will try and merge updates with your changes.
 
Top