SmartStasis -- a complex script for a simple CCS

If not using Universal Recovery, that might be why... it might be thinking that any amount of HP gain is valued.
 
Improper values for HP or MP is one possible source of this problem. The other part of the problem (likely in these cases) is that the max() in the stasis action sort should be a min() -- or vice versa, I forget. That's why the posted version of BB seems to prefer higher-damage stasis actions; it's a very important fix that I've been wanting to get out but my netbook is very uncomfortable to code on and and more things keep getting added to the list, in forum posts and PMs. My local copy has some partially implemented ideas, and it's thus unreleasable. It also has some changes that are not present in Bale's version, but his version has things that aren't present in mine. It's a mess, and I want to clean it up and consolidate everything rather than help it fork further by releasing a partial update, which requires that I have the time and inclination to install and/or learn diff software for my netbook and then diff Bale's and mine and make sure I incorporated the positive changes he made.
 
Is there a way I can disable salve easily? I forgot about this bug and just HC permed it, and now it's wasting all my MP because it'll salve even when I have full HP. :(
 
Is there a way I can disable salve easily? I forgot about this bug and just HC permed it, and now it's wasting all my MP because it'll salve even when I have full HP. :(
Edit data/batfactors.txt and remove the line starting "skill 4014 Saucy Salve". If it gets updated, you'll need remove it again. Also, if you perm Lasagna Bandages, you'll need to remove that too. There might be a better way, but that works for me!
 
I hadn't thought that this problem would persist with the BB update, since that fixed the min/max bug in the stasis sort. If it's still occurring for you, I'd appreciate seeing some verbosity-8 CLI output from a combat where SS does this; would help give me ideas as to why.
 
I hadn't thought that this problem would persist with the BB update, since that fixed the min/max bug in the stasis sort. If it's still occurring for you, I'd appreciate seeing some verbosity-8 CLI output from a combat where SS does this; would help give me ideas as to why.
Oh, I wasn't aware there was a fix. I just checked my logs and it did happen after the Sept 6th update. I'm not sure exactly what conditions cause it to happen, but I'll revert my batfactors and try and get you a verbose output when it does. It will probably take a couple days before I reach the right conditions.

I need to do a "zlib verbosity = 8", right?
 
I had it happen the otehr day, set verbosity to 9 and of course it didn't happen again. Stupid elusive errors...

Edit: Well, a related idea popped into my head today while stasising germlins. It is probably a good idea to not use Saucy Salve there even if it is the cheapest option since it more often than not leads to the gremlin not doing anything due to quick-casting the skill...
 
Last edited:
Is there a trick to getting feed to happily coexist with SS?

If my CCS includes SS, the line "skill feed" seems to be ignored although it work fine if I take SS out of the CCS.
 
You will have to wait for the skill to be added to Mafia's data files.

I don't think I'm going to get the IoTM, but once I break the prism I'll try to add as much support as I can.
 
You will have to wait for the skill to be added to Mafia's data files.

I don't think I'm going to get the IoTM, but once I break the prism I'll try to add as much support as I can.

How would you feel about it if the IotM mysteriously appeared in your kMail?
 
I don't think it's necessary for a full implementation, since most of the necessary info has been posted, and the special choice adventures can be visited with a tradeable item.
 
If you let me know how many "interviews" you need once you're out of ronin, I'll happily send those or the IOTM.
 
I had it happen the otehr day, set verbosity to 9 and of course it didn't happen again. Stupid elusive errors...
I just got it! I was fully healed at the start of combat, because the previous battle was nothing but saucy salve.
Code:
[718] The Upper Chamber
Encounter: tomb rat
Strategy: /root/.kolmafia/ccs/SmartStasis.ccs [default]
Round 0: Crowther wins initiative!
Running ZLib version: r31 (current)
1 MP costs 4.6511626μ.
1 HP costs 1.3953488μ.
tomb ratchet (20.0 @ +35.0): 1395μ * 27.0% = 376.65
leathery rat skin (30.0 @ +35.0): 150μ * 40.5% = 60.75
unidentified jerky (12.0 @ +35.0): 90μ * 16.2% = 14.580001
Value of stat gain: 642.81μ
Running BatBrain version: 1.11 (current)
Profit per round: ActionProfitDamageOtherbase; Rogue Program (0μ)34.53μ7.43 (0 μ/dmg)MP: 7.43
Running SmartStasis version: 3.6 (current)
tomb ratchet (20.0 @ +35.0): 1395μ * 27.0% = 376.65
leathery rat skin (30.0 @ +35.0): 150μ * 40.5% = 60.75
unidentified jerky (12.0 @ +35.0): 90μ * 16.2% = 14.580001
Value of stat gain: 642.81μ
Monster: Tomb Rat, ATT: 171, DEF: 158, HP: 185, Value: 1207.29
You will die in 231 rounds.
Your attack will kill the monster in 3 rounds.
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; pickpocket; call batround; if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 1: Crowther executes a macro!
Round 1: Crowther tries to steal an item!
Stasis action chosen: skill 4014
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; sub batsub1; skill 4014; call batround; endsub; call batsub1; repeat hasskill 4014 && (!hpbelow 191.0 && !mpbelow 134.0 && !pastround 26); if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 2: Crowther executes a macro!
Round 2: Crowther casts SAUCY SALVE!
KoLmafia thinks it is round 3 but KoL thinks it is round 2
You gain 14 hit points
Stasis action chosen: skill 4014
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; sub batsub1; skill 4014; call batround; endsub; call batsub1; repeat hasskill 4014 && (!hpbelow 191.0 && !mpbelow 130.0 && !pastround 26); if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 3: Crowther executes a macro!
Round 3: Crowther casts SAUCY SALVE!
KoLmafia thinks it is round 4 but KoL thinks it is round 2
You gain 10 hit points
Stasis action chosen: skill 4014
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; sub batsub1; skill 4014; call batround; endsub; call batsub1; repeat hasskill 4014 && (!hpbelow 191.0 && !mpbelow 126.0 && !pastround 26); if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 4: Crowther executes a macro!
Round 4: Crowther casts SAUCY SALVE!
KoLmafia thinks it is round 5 but KoL thinks it is round 2
You gain 15 hit points
Stasis action chosen: skill 4014
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; sub batsub1; skill 4014; call batround; endsub; call batsub1; repeat hasskill 4014 && (!hpbelow 191.0 && !mpbelow 122.0 && !pastround 26); if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 5: Crowther executes a macro!
Round 5: Crowther casts SAUCY SALVE!
KoLmafia thinks it is round 6 but KoL thinks it is round 3
You gain 14 hit points
Stasis action chosen: skill 4014
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; sub batsub1; skill 4014; call batround; endsub; call batsub1; repeat hasskill 4014 && (!hpbelow 191.0 && !mpbelow 118.0 && !pastround 26); if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 6: Crowther executes a macro!
Round 6: Crowther casts SAUCY SALVE!
KoLmafia thinks it is round 7 but KoL thinks it is round 4
You gain 13 hit points
Stasis action chosen: skill 4014
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; sub batsub1; skill 4014; call batround; endsub; call batsub1; repeat hasskill 4014 && (!hpbelow 191.0 && !mpbelow 114.0 && !pastround 26); if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 7: Crowther executes a macro!
Round 7: Crowther casts SAUCY SALVE!
KoLmafia thinks it is round 8 but KoL thinks it is round 5
You gain 10 hit points
Stasis action chosen: skill 4014
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; sub batsub1; skill 4014; call batround; endsub; call batsub1; repeat hasskill 4014 && (!hpbelow 191.0 && !mpbelow 110.0 && !pastround 26); if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 8: Crowther executes a macro!
Round 8: Crowther casts SAUCY SALVE!
KoLmafia thinks it is round 9 but KoL thinks it is round 6
You gain 24 hit points
Stasis action chosen: skill 4014
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; sub batsub1; skill 4014; call batround; endsub; call batsub1; repeat hasskill 4014 && (!hpbelow 191.0 && !mpbelow 106.0 && !pastround 26); if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 9: Crowther executes a macro!
Round 9: Crowther casts SAUCY SALVE!
KoLmafia thinks it is round 10 but KoL thinks it is round 7
You gain 12 hit points
Stasis action chosen: skill 4014
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; sub batsub1; skill 4014; call batround; endsub; call batsub1; repeat hasskill 4014 && (!hpbelow 191.0 && !mpbelow 102.0 && !pastround 26); if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 10: Crowther executes a macro!
Round 10: Crowther casts SAUCY SALVE!
KoLmafia thinks it is round 11 but KoL thinks it is round 8
You gain 15 hit points
Stasis action chosen: skill 4014
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; sub batsub1; skill 4014; call batround; endsub; call batsub1; repeat hasskill 4014 && (!hpbelow 191.0 && !mpbelow 98.0 && !pastround 26); if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 11: Crowther executes a macro!
Round 11: Crowther casts SAUCY SALVE!
KoLmafia thinks it is round 12 but KoL thinks it is round 9
You gain 14 hit points
Stasis action chosen: use 8
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; sub batsub1; use 8; call batround; endsub; call batsub1; repeat hascombatitem 8 && (!hpbelow 191.0 && !mpbelow 94.0 && !pastround 26); if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 12: Crowther executes a macro!
Round 12: Crowther uses the spices!
KoLmafia thinks it is round 13 but KoL thinks it is round 10
Round 13: Crowther uses the spices!
You gain 17 Mojo Points
Round 14: Crowther uses the spices!
Round 15: Crowther uses the spices!
Round 16: Crowther uses the spices!
Round 17: Crowther uses the spices!
You gain 20 Mojo Points
Round 18: Crowther uses the spices!
You gain 29 Mojo Points
Round 19: Crowther uses the spices!
Round 20: Crowther uses the spices!
Round 21: Crowther uses the spices!
Round 22: Crowther uses the spices!
You gain 17 Mojo Points
Round 23: Crowther uses the spices!
You gain 25 Mojo Points
Round 24: Crowther uses the spices!
You gain 15 Mojo Points
Round 25: Crowther uses the spices!
Round 26: Crowther uses the spices!
You gain 19 Mojo Points
You lose 13 hit points
Stasis action chosen: skill 3009
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; sub batsub1; skill 3009; call batround; endsub; call batsub1; repeat hasskill 3009 && (!hpbelow 178.0 && hpbelow 191 && !mpbelow 223.0 && !pastround 28); if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 27: Crowther executes a macro!
Round 27: Crowther casts LASAGNA BANDAGES!
KoLmafia thinks it is round 28 but KoL thinks it is round 25
You gain 20 hit points
Stasis action chosen: use 8
Executing macro: scrollwhendone; sub batround; if haseffect 264 || haseffect 283 || haseffect 284; abort "BatBrain abort: poisoned"; endif; endsub; sub batsub1; use 8; call batround; endsub; call batsub1; repeat hascombatitem 8 && (!hpbelow 191.0 && !mpbelow 217.0 && !pastround 28); if hpbelow 15; abort "BatBrain abort: Danger, Will Robinson"; endif; 
Round 28: Crowther executes a macro!
Round 28: Crowther uses the spices!
KoLmafia thinks it is round 29 but KoL thinks it is round 26
You gain 18 Mojo Points
Round 29: Crowther uses the spices!
Round 30: Crowther uses the spices!
You gain 24 Mojo Points
Round 31: Crowther wins the fight!
You gain 114 Meat
You acquire an item: unidentified jerky
You gain 22 Muscleboundness
You gain 6 Magicalness
You can now equip a steaming evil (and possibly other things).
You gain a Mysticality point!
You gain 21 Smarm
Look! You found 1 unidentified jerky (90μ)!
Stasis action chosen: use 2678
 
@Crowther: Not really getting any clues from that, unfortunately. Did you have any MP regen equipment on? I ask because SS considers HP/MP which will be regenerated at the end of combat to be free.

Also, I should mention that the 3.7 update did away with bounty.txt! So unless you're using a bounty script which still needs that data file, you may delete bounty.txt from your data directory and it won't come back! Yay proxy records!
 
Mayfly bait works in the Haunted Sorority House so I added "case $location[haunted sorority house]:" as line 58 which seems to do the trick.
 
Ooh, excellent. I even have one of those lurking in my inventory somewhere. Thanks for the tip!

Since this is minor but time-sensitive, I added it in the first post without waiting for other changes.
 
Two items that get oddly used by SmartStasis (and DestroyAllMonsters, which really needs its own thread at some point):
1) Paperclip sproinger. It's a 2 round stun, but used up. I don't think there's a good reason why SS would prefer using up my sproinger over noodles, when noodles have a value of ~10 meat and the sproinger is untradable with a creation price of ~890 meat currently. Maybe this has to do with it being untradable and having an autosell_price of 0? Regardless, non-reusable items that are untradable probably shouldn't get used up. :(
2) The Gnomitronic Hyperspatial Demodulator is reusable, but only usable once per combat. DAM tried to reuse it over and over as a stasis item, since it was going to take 13 rounds to kill the giant. As it will only be usable once and should really only get used if the monster has <= 15 hp remaining, maybe it should be a special case?
 
Back
Top