New Content - Implemented July 2019 IotM - Beach Comb

Veracity

Developer
Staff member
Ha ha. Well, that was like 1 line. Revision 19378 parses the map and sets the layout and minutes when you visit the beach area for the first time.

This should make it easier to have an intelligent script without having to do a lot of manual map parsing.
It should make it easier for us to have a "beachcomb" command which does ... stuff.
 

xKiv

Active member
I have also seen some sand castles, although I didn't save the html so I can't tell if they are already covered by the existing code or not. They seem to behave like uncombed squares so far anyway, except they give a different into message.
 

Veracity

Developer
Staff member
Thanks. Revision 19380 recogizes those and notates them as 'S'.

Too bad "C" is "combed sand". Perhaps we could use 'r' and 'c' (lowercase) for sand and 'H', 'C', and 'W' (uppercase) for special things.
 

Veracity

Developer
Staff member
Useful URLs:

Wander along the beach for XXX minutes
choice.php?whichchoice=1388&pwd&option=1&minutes=XXX

Wander to a random spot
choice.php?whichchoice=1388&pwd&option=2

Grab Common Items (Uses 10 Free Beach Walks)
choice.php?whichchoice=1388&pwd&option=6

Visit Beach Head #1 (Hot-Headed)
choice.php?whichchoice=1388&pwd&option=3&buff=1

Visit Beach Head #2 (Cold as Nice)
choice.php?whichchoice=1388&pwd&option=3&buff=2

Visit Beach Head #3 (A Brush with Grossness)
choice.php?whichchoice=1388&pwd&option=3&buff=3

Visit Beach Head #4 (Does It Have a Skull In There??)
choice.php?whichchoice=1388&pwd&option=3&buff=4

Visit Beach Head #5 (Oiled, Slick)
choice.php?whichchoice=1388&pwd&option=3&buff=5

Visit Beach Head #6 (Lack of Body-Building)
choice.php?whichchoice=1388&pwd&option=3&buff=6

Visit Beach Head #7 (We're All Made of Starfish)
choice.php?whichchoice=1388&pwd&option=3&buff=7

Visit Beach Head #8 (Pomp & Circumsands)
choice.php?whichchoice=1388&pwd&option=3&buff=8

Visit Beach Head #9 (Resting Beach Face)
choice.php?whichchoice=1388&pwd&option=3&buff=9

Visit Beach Head #10 (Do I Know You From Somewhere?)
choice.php?whichchoice=1388&pwd&option=3&buff=10

Visit Beach Head #11 (You Learned Something Maybe!)
choice.php?whichchoice=1388&pwd&option=3&buff=11

Stop Beachcombing
choice.php?whichchoice=1388&pwd&option=5
 
Last edited:

Veracity

Developer
Staff member
Revision 19381 changes the characters in the layout to make special features more visible:

rough sand -> 'r'
combed sand -> 'c'
sand castle -> 'C'
beach head -> 'H'
whale -> 'W'

Also, if we can't identify the square - and thus give it a '?' - we print the hover text and the image name.
 

Darzil

Developer
r19398 - When equipping and unequipping Beach Comb or hewn moon-rune spoon, add or remove appropriate skills.
 

Kyrinia

New member
Mafia thinks using the etched hourglass uses it up and removes it from inventory screens (and trying to use it again before doing an inventory refresh has mafia try to make a new one)
 

Veracity

Developer
Staff member
So my multi just found a "piece of driftwood", a usable item which the Wiki says gives you:

Code:
--------------------
10291	driftwood beach comb	560767631	woodbeachcomb.gif	accessory	q	0
driftwood beach comb	0	none
Item	driftwood beach comb	Moxie Percent: +1, MP Regen Min: 1, MP Regen Max: 2, Familiar Weight: +1, Single Equip, Lasts Until Rollover
--------------------
This is apparently the "day pass" for the Beach Comb. It's a quest item, so is not tradeable, although the piece of driftwood is. Unlike other day passes, you don't use it and magically gain access to the area for the day. You use it and get an item with a "comb" link.
 

Veracity

Developer
Staff member
Which means we don't need "beachCombAlways" and "_beachCombToday" properties, like othe areas; having access to the "Beach Comb" or "driftwood beach comb" is what you need.

Which is to say, other than adding the item to the KoLmafia data files, nothing needs to be done here. My script, on the other hand, will require a little bit of work. :)
 

Ezandora

Member
Which is to say, other than adding the item to the KoLmafia data files, nothing needs to be done here. My script, on the other hand, will require a little bit of work. :)

Could add a _property for tracking free minutes used, and a _property for knowing which head buffs we've used today. (you can only pick each one once/day)
 

Veracity

Developer
Staff member
Could add a _property for tracking free minutes used, and a _property for knowing which head buffs we've used today. (you can only pick each one once/day)
Oh, sure. When I said "nothing needs to be done here", I meant "regarding the day pass".
 

Veracity

Developer
Staff member
Revision 19427 adds a couple settings:

_freeBeachWalksUsed - starts at 0, goes to 11
_beachHeadsUsed - starts empty, goes to "3", "1,3", "1,3,5,7", whatever.

Those numbers are the Beach Head numbers as shown on the buttons on the choice page.

Code:
	// Beach Heads:
	//
	// #1 (420)	Hot-Headed
	// #2 (2323)	Cold as Nice
	// #3 (4242)	A Brush with Grossness
	// #4 (6969)	Does It Have a Skull In There??
	// #5 (8888)	Oiled, SLick
	// #6 (37)	Lack of Body-Building
	// #7 (3737)	We're All Made of Starfish
	// #8 (7114)	Pomp and Circumstands
	// #9 (5555)	Resting Beach Face
	// #10 (1111)	Do I Know You From Somewhere?
	// #11 (9696)	You Learned Something Maybe!
I don't actually parse the results when you wander to a beach segment or visit a beach head; I parse the page you get when you use the beach comb, which is shown again after you comb a beach square or visit a beach head.

I may have to rethink that, since if you have no free turns left and run out of turns combing the beach, I think it doesn't show you that page. That's sort of a corner case in that you have to run out of free turns with no turns left, say. I can actually test that today; my main has combed a couple of beach heads for buffs but has otherwise used no free turns. I'll have her use up her free turns at the end of the day before drinking a nightcap and see how it behaves.
 

Veracity

Developer
Staff member
Here's how it works.

You have to have a turn to use the Beach Cob. If you don't "You don't have time for that".

If you do have a turn left, you get the "choose what to do" choice, which we parse and figure out how many free wanders you have used and which beach heads you have visited. We need to do that, in any case, because one of KoLmafia's core principles is that we cannot assume that you run all of your turns in KoLmafia for us to observe; we can track your character state for things you do in the program, but if you do things outside of KoLmafia, we need to figure out your character state via some other means.

Therefore, you have a turn left when you start, and, if you are using free wanders, you still have a turn left and are shown the "choose what to do page". Which tells me that we don't need to do any "after adventure" tracking to decide if this was a free wander; the initial Comb the Beach page will suffice.

Beach heads are a different issue. Currently I decide which ones you have visited based on which shortcuts you see on the initial page, but that is not correct. There are two settings needed:

beachHeadsUnlocked - every head you have ever visited and which there will subsequently be a shortcut for
_beachHeadsVisited - every head you have visited today.

There definitely are things we can deduce from the Comb the Beach page

- If we see a shortcut, we know that one has been unlocked and has not been visited
- If you have 11 free wanders available, we known none have been visited
- If you have 11 free wanders available, we know that the set of shortcuts offered is sll beach heads you have unlocked.

But there is one additional thing we need to do:

- When you actually comb a square and get an Effect, mark the appropriate beach head as both unlocked and used today.

I think that should cover it. It won't matter if you use you last turn visiting a beach head via shortcut or manually and we don't get to see the Comb the Beach page again.

I'll do this, by and by. And I'll set up some Beach Head data in the BeachManager to support it which will also be useful in a forthcoming combbeach command, should we do one. Something which will allow you get a beach head buff of your choice, whether or not you have the shortcut unlocked, say.
 

Veracity

Developer
Staff member
Revision 19429 should handle beachHeadsUnlocked and _beachHeadsUsed correctly.

While testing, I noticed a KoL bug, which I reported, but this code will continue to work, whether or not they fix it.
 

Veracity

Developer
Staff member
I think we need the following to "finish" this:

1) Add a "combbeach" command

combbeach common

collect the "common" items using 10 free walks (assuming you have that many left today

combbeach head 2
combbeach head cold
combbeach head Cold as Nice

Get a beach head buff, specified by number, keyword, or effect name.

BeachManager has this for beach heads:

Code:
	public static final BeachHead [] BEACH_HEADS = 
	{
		new BeachHead( 1, "Hot-Headed", 420, "hot" ),
		new BeachHead( 2, "Cold as Nice", 2323, "cold" ),
		new BeachHead( 3, "A Brush with Grossness", 4242, "stench" ),
		new BeachHead( 4, "Does It Have a Skull In There??", 6969, "spooky" ),
		new BeachHead( 5, "Oiled, Slick", 8888, "sleaze" ),
		new BeachHead( 6, "Lack of Body-Building", 37, "muscle" ),
		new BeachHead( 7, "We're All Made of Starfish", 3737, "mysticality" ),
		new BeachHead( 8, "Pomp and Circumsands", 7114, "moxie" ),
		new BeachHead( 9, "Resting Beach Face", 5555, "initiative" ),
		new BeachHead( 10, "Do I Know You From Somewhere?", 1111, "familiar" ),
		new BeachHead( 11, "You Learned Something Maybe!", 9696, "experience" ),
	};
as well as data structures to look up those objects via id and effect name - and an array for doing fuzzy matching on keyword - which are what we need to support this command.

It has the "minutes" number, so if you don't have the shortcut, we can visit that square and find the beach head in it. Are they always in the same square? Seems likely, and saving the coords would be good, but we can find it in the beach map after visiting, if we don't know the coordinates.
I'll look at my session logs for my two characters who have visited all the beach maps and find the coordinates.

2) add appropriate "beachcomb" command to statuseffects for each of the effects.

3) add "beachcomb" as a recognized command in the maximizer.
---------------------
Beyond that, I don't know anything else KoLmafia itself needs to do now.

You want to farm? My BeachComber script is in the repo.

(Ezandora has her own spading script. I k-chatted with her and asked if she wanted to make a forum thread for it so I could add it to the repo. She said people had asked her about it a day or two before I released mine, which is why other people knew about it, but she'd just point people to mine, now, so, no.)

Anything else we need for this?
 
Top