Harvest – A highly customisable farming script

Winterbay

Active member
Thanks Winterbay. I'm not sure why updating that script fixes the issue but thank you!

RL

It fixes the issue because what harvest.ash is doing at that point is to call eatdrink to fill up your organs and gain adventures. r10245 updated things in the data files that made eatdrink want to consume drunkibears, but it couldn't do that since it tried to drink them instead of eating them. The update in the eatdrink thread actively prohibits the consumption of drunkibears and thus the problem is solved.
 

Banana Lord

Member
Nope. No idea sorry. Does it still run, or does it abort? Also, do yourself a favour and set eatdrink_pause to 0 in /kolmafia/data/vars_CHARNAME.txt

EDIT: Ninja rabbit! No wonder he's stealing cookies!

EDIT2: Good news everyone! Mafia now has a FaxBot command so I'll be able to put support for that in the next release! I'll probably be wanting beta testers for that feature at some point, so if you'd like to help out please post so I can make a note of your name.

EDIT3: @coderanger: In the relay script, is there any way to improve the entry animation? Currently it starts a fixed number of pixels above the frame, which works OK, but it results in a slight delay when the active panel is small, or could cause the bottom of one of the larger panels to begin the animation on screen.
 
Last edited:

Banana Lord

Member
Cool. I should clarify, what I was hoping to do was have the animation start so that the bottom edge of the active panel is just on the top of the screen (well, one pixel above I suppose, so that it can't be seen initially).
 

Banana Lord

Member
Also, I finally have a feature request. Would it be possible to implement CSS switching based on the different activities, ie. bounty, farming, etc? I would like to use a separate script for bountying (ie, harvest combat), then swap to my own for my farming.

I've been thinking about this, and I really don't want the user to have to explicitly set a CCS for each section. Could you not write a single ash script with code copy-pasted from Harvest Combat.ash (the bounty hunting code in your case, along with the necessary functions from the top of the script)? Then you could add your own functions for farming and hook into the har_current_activity property to work out which to use and when to use them, using a single CCS to consult it.

The thing is that for most people Harvest Combat will do everything they need, and the people who want more will be skilled enough and have sufficient motivation to write their own script as I outlined above. It doesn't seem necessary to me to add more settings when there's a perfectly viable alternative. But please, argue against my reasoning. It's not technically difficult to implement (you could mod the script pretty easily, actually), so the only thing stopping me is the perception that this wouldn't be useful for very many people. Though again, I'll be happy to be proven wrong :).

EDIT: Oh and one day I'm hoping Zarqon will finish his epic combat suite, at which time I may well stop developing Harvest Combat.
 
Last edited:

Arundel

New member
This is probably a question that is hilariously obvious, but is there a way I can force the harvest script to nightcap a bucket of wine as opposed to something that eatdrink establishes? The script works great and I love it, but this is a bit of confusion I have with it. (Note: I have no scripting abilities, sorry)

Right now I rarely use any clip art summons a given day so I almost always have one available. Would this be an easy thing for me to specify or would it be non-trivial?
Thanks!
 

Theraze

Active member
EatDrink gives me buckets of wine... if yours doesn't, you don't have it set high enough to value buckets...
 

Banana Lord

Member
Hmm, interesting request. The short answer is no, the long answer is yes. I'll explain them separately.

As you know, Harvest uses ED to handle consumption so there's technically no way to have Harvest do this, because it's not in charge of consumption. However, if ED thinks that something else is better than a bucket of wine (and in your case it does) then it will have balanced the cost of buying something against the potential profit of selling the bucket of wine you have in your inventory. So essentially what ED is saying is "sure you've got a bucket of wine, but you could make more meat by selling it and buying this other thing instead". So either you can just accept that ED is doing what's best and making you as much meat as possible, or you can tweak your settings to make them more optimal (here I defer to others to guide you).

There is an alternative. Harvest requires a consumption script, but it doesn't require that that consumption script be ED. You could write your own (with help, if you need it) and specify that instead of ED in the "Consumption script" setting. So I guess it would look something like this:
PHP:
import <eatdrink.ash>;

if(get_property("har_current_activity") == "finish")
	{
	if(my_inebriety() == inebriety_limit())
		{
		if(item_amount($item[bucket of wine]) == 0)
			buy(1, $item[bucket of wine]);
		use(1, $item[bucket of wine]);
		}
	}
else
	eatdrink(fullness_limit(), inebriety_limit(), spleen_limit(), true);
Note that I threw that together in five minutes, so it might need some tweaking. In theory it will use ED to fill you up as normal before farming, and then use a bucket of wine to over drink afterwards, while being well behaved and using suitable checks to avoid unexpected behaviour. In theory ;-) The only thing you really have to remember when specifying a consumption script other than ED is that Harvest will get ode for you if (and only if) you don't have the skill yourself, in which case it will attempt to get it from a buffbot. If you do have the skill then it will assume that the consumption script will make use of it.
 
Last edited:

fronobulax

Developer
Staff member
This is probably a question that is hilariously obvious, but is there a way I can force the harvest script to nightcap a bucket of wine as opposed to something that eatdrink establishes? The script works great and I love it, but this is a bit of confusion I have with it. (Note: I have no scripting abilities, sorry)

Right now I rarely use any clip art summons a given day so I almost always have one available. Would this be an easy thing for me to specify or would it be non-trivial?
Thanks!

To hijack the thread, there are code snippets floating around that folks are adding to their logout scripts. If you have any Clip summons left then it will summon the most expensive item in the mall and sell it. There are a couple of variations on the script but it pretty much makes sure you don't leave a clip summons "on the table".
 

alexsqian

New member
This is one of the best scripts I've ever seen. I have a few questions though. For two of my characters, it'll do rave combo's as well as the disco combo's, but I can't for the life of me get this third DB to do rave combos. The nemesis quest is finished and I can use the rave combo's outside of the Volcano, but it'll just keep on using Disco combos. Oh right, here's what verbosity 3 shows Strategy: C:\Junk\ccs\meat farm.ccs
Round 0: albertsqian wins initiative!
Beginning farming...
Beginning db combos...
can_dnirvana: true
can_dconcentration: true
pickpocket; pickpocket; skill 5005; skill 5008;skill 5003; skill 5005; skill 5008;while !pastround 25; attack; endwhile;
pickpocket%3B+pickpocket%3B+skill+5005%3B+skill+5008%3Bskill+5003%3B+skill+5005%3B+skill+5008%3Bwhile+%21pastround+25%3B+attack%3B+endwhile%3B
Round 1: albertsqian executes a macro!

Another question,
Visit to Beanstalk: Giant's Castle in progress...
hidden city (automatic)
hidden city (encounter)
Multiple matches against Hidden City.
Bad location value: "Hidden City" (CounterChecker.ash, line 78)
Fortune Cookie counter expired. Last semirare found 1072 turns ago (on turn 17590) in Giant's Castle
This keeps on popping up and stopping the script. I have "get semi-rares" checked on the harvest relay, and the latest counterchecker.ash. This occurs on all the characters it's used on.
 

Banana Lord

Member
I'm glad you like the script. It's pretty cool seeing a few hundred people download something you've made and (hopefully) get some use out of it.

I can't tell you off the top of my head what's going on with your combo problem, and I'll be flat out for the next week so either you'll have to hang tight until then, or maybe someone else will find the problem for us before then. As soon as I have a chance I'll get right on it.

The second problem is easy to fix, just make sure you have the latest daily build :)
 

Theraze

Active member
Yeah... that was added to CounterChecker 1.49995 back on January 23rd. Any "latest" that doesn't have it, isn't...
 

Theraze

Active member
Well, the advice you gave was good, but updating to the latest daily build is actually what caused the problem before the first post. :D

Veracity added the new locations of Hidden City (automatic) and Hidden City (encounter) which, because they both match Hidden City, cause old versions of scripts that use specific locations to choke. CounterChecker and canadv are the ones that people are most likely to notice it in, I think... But anyways, details.
 

eegee

Member
I'd add the functionality if you sponsor me one :p.. then again, I could probably add try add it sometime and you test it. Banana Lord is busy at the moment so if he wants to add it, I'm not sure when he'll get a chance to.
 
Top