PriceAdvisor: Maximize your profits

No mistake. I was pointing it out because jcowley clearly didn't read the page or he'd have seen it.
 
So, if script want to buy materials for X meat while the Profit of this in the end is less than X, set flag.
Just to be clear: you do know that the profit takes into account buying the extra ingredients?

That being said, PA does give some strange advice sometimes, and this flag could be of some help to establish a rule-of-thumb for automatically deciding if an advice should be followed.
 
Just to be clear: you do know that the profit takes into account buying the extra ingredients?

That being said, PA does give some strange advice sometimes, and this flag could be of some help to establish a rule-of-thumb for automatically deciding if an advice should be followed.

Yeah I know, or rather assumed, that the calculated profit would be based on the income of the finished items vs the cost of the mats and sell them on their own.
What I am hoping for is something so that the script don't tell me to spend millions of meat in mats just for an item that, if it even sell, would give me a few hundred meat in profit.
Yes it would probably help at least flag a warning for some of the more silly advices, such as "you have 2 eyepatch. Make NinjaPirateZombieRobot head. Sell." =)
 
Any suggestions on how to make it so that all non-tradables are kept, specifically when using Zarqon's combined OCD/PA script? Basically, I just want the scripts to make the most money out of all of my tradables (not keeping any spares). I looked at the PA code but it's rather heavy stuff for me, so I'm not really sure where to even start.

Slyz answered my question:
[clan] slyz: after "foreach it in get_inventory() { ", add:
[clan] slyz: if (!is_tradeable(it)) continue;
[clan] slyz: if you also want to skip no-sell items:
[clan] slyz: if (autosell_price(it) == 0) continue;
 
Last edited:
I'm a bit of a script noob, so please forgive the question.
I'm wanting to use Zarqon's script to fill up my OCD database, but how do I run it?

Do I copy it to the OCD script or something like that?

Cheers :)
 
You copy it into say Notedpad and save it as "something.ash", then you go to Mafia and type "call something.ash" and it should work. Make sure you check over the result though as some things are a bit strange... :)
 
Thanks :)

Turns out I had done the right thing, but Word had done its stupidity with 'smart' quotes.

(Not normally that dumb - Notepad and Wordpad crash on this computer. Serves me right for doing KoL at work :P )
 
First of all, I love this script. I have a question, though, and I'm wondering if it's something I could fix myself (if only I knew how)

Here's the situation: I'm using the script to tell me where I should farm, what I should do with my creatable items, etc.

So, I look for cold nuggets.
cold nuggets:
acquire 1 linoleum crossbow; make 1 projectile icemaker; mallsell 1 projectile icemaker: 1453.0 meat
mallsell 1 cold nuggets: 224.0 meat

So I look at that and say "yeah, there's no way I want to load up on projectile icemakers, since like 20 total have been sold in the last month. " So I go though my day assuming that 224 is a much more realistic price for cold nuggets.

But then I look at my palm fronds:
palm frond:
acquire 6 palm frond; make 1 palm-frond cloak; smash 1 palm-frond cloak; acquire 1 linoleum crossbow; make 1 projectile icemaker; mallsell 1 projectile icemaker; mallsell 1 cold wad; autosell 1 effluvious emerald; mallsell 1 glacial sapphire; mallsell 1 hot nuggets; mallsell 1 hot wad; mallsell 1 sleaze nuggets; mallsell 1 sleaze wad; acquire 4 spooky nuggets; make 1 spooky wad; mallsell 1 spooky wad; mallsell 1 spooky wad; autosell 1 steamy ruby; mallsell 1 stench nuggets; mallsell 1 stench wad; autosell 1 tawdry amethyst; acquire 4 twinkly nuggets; make 1 twinkly wad; mallsell 1 twinkly wad; mallsell 1 twinkly wad; autosell 1 unearthly onyx: 825.42737 meat
acquire 4 palm frond; make 1 palm-frond capris; mallsell 1 palm-frond capris: 364.0 meat
acquire 2 palm frond; make 1 palm-frond net; mallsell 1 palm-frond net: 357.0 meat

So the script tells me that the best thing to do is smash a palm-frond cloak, assuming that I'll be using the cold nuggets for a projectile icemaker. Which I don't want to do.

So, my question is- is there a way for me to override some of the prices I get, so that it will use my "no, really, this is the right price" numbers for its other calculations? I'm willing to try a little bit of scripting, if that's what's needed, but I was hoping I'd be able to make a quick edit someplace, if possible.

Thanks again for the awesome script!
 
I'm probably just not realizing the simple word or combination of words for it, but is there a "grouping" for Superhuman Cocktails / Still-creatable drinks for use with the "pam" alias?

I ask just due to the fact that the Still can make stuff without AC/SHC bits (coconut/umbrella/cubes) as opposed to The Wok of Ages / Saucecrafting which all revolve around Dry Noodles or Scrumptious Reagents, which can easily be "pa"d with "dry noodles" or "scrumptious reagent", I'd figure.
 
Eh, My copy apparently updated January 26, 2012.

But being that use_for_items is in the map manager, anyone can update it.
 
But being that use_for_items is in the map manager, anyone can update it.

Oh? If I understand it correctly, it is item to use, item returned, expected number of item returned. Looks like I need to spend some time calculating what the expected results are.

I'm using use_for_items.txt and use_for_meat.txt in a script I'm working on. The thing is, I don't really care what the expected results are, I just need to know what items can be used for meat and what can be used for items. Is there a better way to get that information or is using these two map files the best?
 
Ah... that makes sense. As the use_for_items doesn't have them as they vary... they're actually found inside the script file as overrides. And shouldn't be added to the map, as that would break the script.

Code:
int hippy = to_int(get_property("sidequestFarmCompleted") == "hippy");
item_use[$item[Hippy Army MPE]][$item[handful of walnuts]] = .7 - .2 * hippy;
item_use[$item[Hippy Army MPE]][$item[mixed wildflower greens]] = .7 - .2 * hippy;
item_use[$item[Hippy Army MPE]][$item[cruelty-free wine]] = .533 - .2 * hippy;
item_use[$item[Hippy Army MPE]][$item[Genalen™ Bottle]] = .533 - .2 * hippy;
item_use[$item[Hippy Army MPE]][$item[thistle wine]] = .533 - .2 * hippy;
if (to_boolean(hippy))
	item_use[$item[Hippy Army MPE]][$item[megatofu]] = 1;
	
int frat = to_int(get_property("sidequestFarmCompleted") == "fratboys");
item_use[$item[Frat Army FGF]][$item[brain-meltingly-hot chicken wings]] = .533 - .2 * frat;
item_use[$item[Frat Army FGF]][$item[knob ka-bobs]] = .533 - .2 * frat;
item_use[$item[Frat Army FGF]][$item[frat brats]] = .533 - .2 * frat;
item_use[$item[Frat Army FGF]][$item[can of Swiller]] = .7 - .2 * frat;
item_use[$item[Frat Army FGF]][$item[melted Jell-o shot]] = .7 - .2 * frat;
if (to_boolean(frat))
	item_use[$item[Frat Army FGF]][$item[McMillicancuddy's Special Lager]] = frat;

Probably best to put your own overrides in, unless you can come up with a good way of programically describing that which won't break the current PA users.
 
Ah... that makes sense. As the use_for_items doesn't have them as they vary... they're actually found inside the script file as overrides. And shouldn't be added to the map, as that would break the script

Probably best to put your own overrides in, unless you can come up with a good way of programically describing that which won't break the current PA users.

Yeah, I think I'll just go with adding my own override to my script. I was looking at trying to determine the expected return from those two items and got stuck. The way PA handles it is probably the best.

Edit: Looking at PA itself, it looks like there is also a special case defined for the dead mimic, for good reason.
 
Last edited:
Back
Top