Feature Req: automatical check the "no skills" box in valhalla if there are no skills that could be permed.

MCroft

Developer
Staff member
also, do you have a suggestion for "not-orange" on the text? I didn't want to use red because it was no longer a warning.
 

MCroft

Developer
Staff member
hmm. What you're showing there isn't exactly what I checked in.

This is the final version:
Java:
void modify_decision( buffer page )
{
  buffer permery = visit_url("afterlife.php?place=permery");
  if ( permery.contains_text( "It looks like you've already got all of the skills from your last life marked permanent.  There's nothing we can do for you here!" ) )
  {
    string no_perm_warning = `<p style="color:red">Are you sure you want to reincarnate without marking any skills permanent?<br /><label><input type="checkbox" class="req" value="1" name="noskillsok" /> yes</label></p>`;
    string no_perm_ok = `<p style="color:orange">You are reincarnating without marking any skills permanent because you have no skills to make permanent.  Try learning more skills.  Knowledge is power.</p><input type="hidden" value="1" name="noskillsok" />`;
    replace_string(page, no_perm_warning, no_perm_ok );
    }
}

void main()
{
    buffer page = visit_url();
    if ( page.contains_text( "The Astral Pet Salesman" ) ) {
        modify_pet_store( page );
    } else if ( page.contains_text( "The Deli Lama Counterman" ) ) {
        modify_deli( page );
    } else if ( page.contains_text("Are you sure you want to reincarnate without marking any skills permanent?" ) ) {
        modify_decision( page );
    }
    write( page );
}

If you're changing it by hand, the code has a change to use afterlife.1.ash, to get around a known caching issue.
 

ereinion

Member
Yep, it's working correctly on this ascension. I must have messed up something when editing your code. As for a suggestion for not-orange - would kol-blue be an option?
 
Top