Feature - Implemented Add "+1 superduperheated metal" as goal for The Bubblin' Caldera

Ryo_Sangnoir

Developer
Staff member
I type this in and run it ~once per day. It would be more convenient for me if it automatically present in the dropdown for default goals.

I'm not hoping for anything fancy like checking for heat-resistant sheet metals -- I'll handle that.
 

Rinn

Developer
It might be a little dangerous to make that a default condition if it doesn't also acquire the sheet metals, a unknowing user could burn a bunch of adventures on a condition that could never be fulfilled. It'd be outside the scope of this, but it would be interesting (but complex) if mafia understood that a condition was impossible and would abort.

Anyway, this may be better suited for a script, something like

Code:
void superduperheatedmetal(int maximum)
{
    if (!(get_property("hotAirportAlways").to_boolean() || get_property("_hotAirportToday").to_boolean()) ||
        get_property("_volcanoSuperduperheatedMetal").to_boolean())
    {
        return;
    }


    set_location($location[The Bubblin\' Caldera]);
    // set equipment


    int count = 0;
    while (!get_property("_volcanoSuperduperheatedMetal").to_boolean() && count < maximum && my_adventures() > maximum-count)
    {
        cli_execute("acquire 1 heat-resistant sheet metal");
        adv1($location[The Bubblin\' Caldera], -1, "");
        count++;
    }
    if (have_effect($effect[drenched in lava]) > 0)
    {
        cli_execute("try; uneffect drenched in lava");
    }
}

 

Veracity

Developer
Staff member
I'm OK with it being a default condition. An "unknowing user" would have no reason to seek a goal for an item that they don't understand. Yes, you can script it - but this FR is for the GUI.

Revision 20036
 

fronobulax

Developer
Staff member
it would be interesting (but complex) if mafia understood that a condition was impossible and would abort.

About a decade ago I thought that was a good idea and tried to get someone else to do it :) Too complex and full of special cases for me to do it.

If I was going to try something, I would start building a preadventure script to do it. The obvious thing would be if a condition was an item, check to see if a monster drops that item. Then, if there is a prerequsite, check it and then I remember why I wasn't going to do it. Zarqon's MercenaryMood might have some ideas for scripting. It knows, for example, to adjust ML for Oil Peak and gettings a wine bomb.
 

Ryo_Sangnoir

Developer
Staff member
Perfect, thanks Veracity.

I agree that doing this properly would involve scripting it, but the character I do this on only does the volcano ad-hoc: I've been running for metal using "acquire 20 tant sheet", then adventuring after setting the goal. This change sends that workflow up nicely :)
 
Top