Page 1 of 62 1 2 3 11 51 ... LastLast
Results 1 to 10 of 618

Thread: Scripting the birth of a new life.

  1. #1
    Minion Bale's Avatar
    Join Date
    Jun 2008
    Posts
    13,152

    Default Scripting the birth of a new life.

    newLife 1.14.4

    I began work on this script largely in response to a bug report concerning choice adventures at the Barrr granting different results according to character class. Since then it has grown more useful. It is a fact that many choice adventures have different optimal decisions based on your current class. It is tedious to manually change all those settings every time you ascend, so I used to ignore them until I was the appropriate level. Then I'd hope not to forget about them or miss one.

    Wouldn't it be nice if all your ascension relevant choice adventures were automatically set every time you ascended?

    Fortunately mafia has the ability to automatically run a script after ascending. I made use of that ability to write a script that will take care of all the little things I want to do whenever I ascend. It will set those niggling choice adventures at the Barrr to keep you from getting drunk. It will ensure the castle wheel is turned in the direction of your mainstat if you're moxie or mysticality. It even ensures you get your mainstat at Whitey's Grove from the one choice adventure that helps your mainstat while the others give an item. There are many more such choice adventures and I think I found them all.

    This script will also reset a few other choice adventures that might get changed in aftercore and are important to ascension like your song choice in the ballroom. It will set automatic recovery to a level appropriate for level 1. It will get the free hat for your Bugged Baby Bugbear from the Arena and it even gets your cowboy boots to save you the trouble. (It's a free pull!) Finally it visits the Toot Oriole, since that is just annoying to click through.

    You can use the script manually or set it to activate automatically every time you ascend. No muss, no fuss. Here's how to do that:
    1. The script is installed through and updated by SVN. Please copy/paste the following line into KoLmafia's CLI and press enter:
      svn checkout https://svn.code.sf.net/p/bale/new-life/code/
    2. To make mafia automatically run it upon ascension, in the CLI type:
      set postAscensionScript = newLife.ash


    Note that there are a few user configurable options in the script to suit your play style. These can be changed for specific characters from the CLI command line. Each character will need to change their preferences separately so you can have character specific behaviors.

    • Normally, this script will not call for the Guy Made of Bees in the Haunted Bathroom. If you like to set up the guy made of bees use the CLI command (capitalization counts, so use copy/paste):
      zlib newLife_SetupGuyMadeOfBees = true
    • If you want the script to smash your hippy stone (it is best to break it before your first rollover) use the CLI command (use copy/paste):
      zlib newLife_SmashHippyStone = true
    • There is an option to have the script sell off pork gets to ensure you acquire a detuned radio, seal tooth and stolen accordion. If you do want this, then use the CLI command (use copy/paste):
      zlib newLife_SellPorkForStuff = true



    Enjoy the script.
    Last edited by Bale; 12-07-2016 at 01:17 AM.
    If people like my scripts, please send me stuffed Hodgmen.
    Universal Recovery, OCD Inventory Control, CounterChecker, newLife, ChIT.


  2. #2
    Minion Bale's Avatar
    Join Date
    Jun 2008
    Posts
    13,152

    Default

    Here's a sample output from my recent ascension as a Disco Bandit, to show you some of what it does:

    Code:
    Pulling items from storage...
    You acquire an item: Clan VIP Lounge key
    Resetting HP/MP restoration settings to minimal
    hpAutoRecovery => 0.1
    mpAutoRecovery => -0.05
    mpAutoRecoveryTarget => 0.2
    manaBurningThreshold => -0.05
    Library's Rise of the House of Spookyraven: Unlock stairs
    choiceAdventure80 => 99
    Setting choice adventures for Moxie class.
    Whitey's Grove: Get wedding cake and rice
    choiceAdventure73 => 3
    Whitey's Grove: Get Moxie stats
    choiceAdventure74 => 1
    Ballroom Curtains: get moxie
    choiceAdventure90 => 2
    Defiled Alcove: skip adventure
    choiceAdventure153 => 4
    Defiled Niche: get Moxie stats
    choiceAdventure155 => 1
    A Test of Testarrrsterone in Barrrney's Barrr: get lots of Moxie
    choiceAdventure186 => 3
    Chatterboxing in F'c'le: get Moxie stats
    choiceAdventure191 => 1
    Bathroom, Don't Hold a Grudge: Get Moxie stats
    choiceAdventure402 => 3
    Hippies on the Verge of War, Bait and Switch: Fight a cadet
    choiceAdventure139 => 3
    Hippies on the Verge of War, Thin Tie-Dyed Line: Get Moxie stats
    choiceAdventure140 => 2
    Frats on the Verge of War, Catching Some Zetas: Fight a pledge
    choiceAdventure143 => 3
    Frats on the Verge of War, One Less Room Than In That Movie: Get moxie stats
    choiceAdventure144 => 1
    Frats on the Verge of War, Fratacombs: Get food
    choiceAdventure145 => 2
    At the Poop Deck, take the Wheel and Sail to Moxie stats
    oceanDestination => moxie
    Optimal ascension choices set.
    Getting your baby buggy bugbear balaclavaed.
    Putting Lllama the Llama Lama back into terrarium...
    Taking spartacus! the Baby Bugged Bugbear out of terrarium...
    You acquire an item: bugged beanie
    You acquire an item: lead necklace
    You acquire an item: lead necklace
    You acquire an item: lead necklace
    Autoselling items to NPCs...
    Items sold.
    Using 1 bugged beanie...
    You acquire an item: bugged balaclava
    Finished using 1 bugged beanie.
    Putting on bugged balaclava...
    Equipment changed.
    Putting spartacus! the Baby Bugged Bugbear back into terrarium...
    Taking Lllama the Llama Lama out of terrarium...
    The Oriole welcomes you back at Mt. Noob.
    You acquire an item: letter from King Ralph XI
    Opening letter from King Ralph XI.
    Using 1 letter from King Ralph XI...
    You acquire an item: stainless steel shillelagh
    You acquire an item: pork elf goodies sack
    You acquire an item: disassembled clover
    Finished using 1 letter from King Ralph XI.
    You are free to autosell pork elf stones now, if you wish.
    Welcome to your new life as a Disco Bandit!
    Last edited by Bale; 08-31-2010 at 07:36 PM.
    If people like my scripts, please send me stuffed Hodgmen.
    Universal Recovery, OCD Inventory Control, CounterChecker, newLife, ChIT.


  3. #3

    Default

    Nice, as always.

    Thanks for the script, I'll use it everytime I ascend now.

  4. #4
    Senior Member halfvoid's Avatar
    Join Date
    Jun 2009
    Location
    London, UK
    Posts
    265

    Default

    have you tried this out with ascend.ash and if so were there any compatibility issues you noticed?

  5. #5
    Minion Bale's Avatar
    Join Date
    Jun 2008
    Posts
    13,152

    Default

    I haven't actually used ascend.ash, but I cannot imagine how they might conflict since they don't interact at all. When you ascend this will set your choice adventures, pull VIP Key and so forth. Then you would call ascend.ash so that it can do its thing.

    Naturally I would like dj_d to correct me if I'm somehow mistaken, but I doubt it.
    If people like my scripts, please send me stuffed Hodgmen.
    Universal Recovery, OCD Inventory Control, CounterChecker, newLife, ChIT.


  6. #6

    Default

    Nice script. The commands to equip starting gear will be wasted server hits in softcore since most people will pull something better.

  7. #7
    Senior Member
    Join Date
    May 2009
    Posts
    145

    Default

    Well, I am not dj_d, but I guess since I use the script I can chime in. You're right bale, since the two scripts don't interact, there is not much harm that can be done. The only forseeable problem I can find is just from pullcrap.ash, which is called by ascend.ash. Because your script pulls the key if available, this may interfere with somebody's customizable pull list that ascend.ash uses, but if somebody pays attention and knows this script pulls the key, it will not be a problem. Otherwise, only 1 pull wasted. Other then that, like I said, no conflict should occur. Hope that helps.


    Cody/CoolBufferBot(In-game)

  8. #8

    Default

    VIP key is a free pull, and no one should have two of them anyway (DC collection maybe, but then it isn't in hagnk's to pull). There's nothing wrong with two scripts trying to pull it, especially since pullcrap.ash should be able to handle the case where someone doesn't have the key at all to pull it.

  9. #9
    Minion Bale's Avatar
    Join Date
    Jun 2008
    Posts
    13,152

    Default

    VIP Key does not cost a pull so there's never a reason not to pull it.

    Nice script. The commands to equip starting gear will be wasted server hits in softcore since most people will pull something better.
    Originally Posted by lostcalpolydude View Post
    Good point. Fixed that. Now it only does that if you're in hardcore. New version can be downloaded from the first post.
    Last edited by Bale; 10-14-2009 at 01:18 AM.
    If people like my scripts, please send me stuffed Hodgmen.
    Universal Recovery, OCD Inventory Control, CounterChecker, newLife, ChIT.


  10. #10
    Senior Member
    Join Date
    May 2009
    Posts
    145

    Post

    Haha. My bad, I haven't been ascending in a while, and I forgot it doesn't take a pull.

Similar Threads

  1. Replies: 0
    Last Post: 08-16-2014, 10:40 PM
  2. Feature - Implemented Heavy Rains: miniature life preserver should be prioritized for familiars
    By Bale in forum Bug Reports
    Replies: 4
    Last Post: 08-16-2014, 10:29 PM
  3. Help with scripting
    By avbferry in forum Scripting Discussion
    Replies: 13
    Last Post: 06-20-2011, 12:36 PM
  4. New to Scripting
    By leperkaun in forum Scripting Discussion
    Replies: 1
    Last Post: 11-06-2010, 05:38 AM
  5. ASH scripting
    By Duckey Yoda in forum Scripting Discussion
    Replies: 11
    Last Post: 04-01-2010, 12:39 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •