caphector, I was thinking about this, too, and it's actually simpler than you're making it. Whether or not to use clovers depends on the relative value of the adventures and the clovers, but for Wormwood and Astral, it's just a fixed thing - either you 'pay the fee' to adventure in the area, or you don't. Because of this, it should be sufficient (as far as I can tell) to simply adjust the value of the location by a fixed amount.
Here's the code I'm using:
Code:
// Special modifications for Wormwood, Astral trips
if ((loc == $location[Rogue Windmill]) ||
(loc == $location[Mouldering Mansion]) ||
(loc == $location[Stately Pleasure Dome]))
{
item tinybottle = $item[tiny bottle of absinthe];
int tinybottleprice = historical_price(tinybottle);
if(historical_age(tinybottle) > to_float(vars["farm_minAgeLookup"]))
tinybottleprice = mall_price(tinybottle);
loc_meat = loc_meat - (tinybottleprice / 10);
}
if ((loc == $location[Astral Mushroom (Bad Trip)]) ||
(loc == $location[Astral Mushroom (Mediocre Trip)]) ||
(loc == $location[Astral Mushroom (Great Trip)]))
{
item astral = $item[astral mushroom];
int astralprice = historical_price(astral);
if(historical_age(astral) > to_float(vars["farm_minAgeLookup"]))
astralprice = mall_price(astral);
loc_meat = loc_meat - (astralprice / 5);
}
I can't guarantee that this works, but comparing my results with this to the ones I was getting before, it seems to be working - the Great Trip was at the top of my list originally (around 1200 mpa), and now it's way down at the bottom (around 200 mpa), which fits, seeing as how astral mushrooms are ~4000 meat for 5 adventures.
The one other issue with the astral mushrooms is the violet fog non-combat - the value of this is essentially determined by the current price of either the munchies pill or the ice stein, whichever's higher. It shouldn't be to tough to determine what this is, but with the way non-combats are currently valued (hard coded), I can't think of an easy way to make this work right now...