BatBrain -- a central nervous system for consult scripts

zarqon

Well-known member
Edit: Also, what does the first and second field of the monster-part in batfactors actually mean? And man is it annoying to add a new monster when they are sorted alphabetically, meaning you need to update all the index numbers after the one you're adding... (I intended to add the bat in the spat which is why the noskills predicate came up)

Did you read the batfactors ("ashwiki batfactors") Wiki page? I wrote a new section for the monsters category when I updated the format.

Also, you don't need to maintain alphabetical order. I did just for the transition, which took a lot of time (I entered everything in random order, then wrote a tiny ASH script to load the file into a map and then and resave it), but I kind of figured further edits would be chronological rather than alphabetical. On my last update of batfactors for r8 (which already added the Bat in Spats?), I just put the new monsters at the end.

A while back there was a discussion about to_int(data type with no clear integer association). It led to those functions being removed from ASH. This would be a case where, though the integer association is meaningless, it would provide us with a handy method of organizing data. But if we want it we'll have to write our own, which would probably involve either a data file or a gigantic switch statement, since any simple programmatic method will lead to numbers changing when monsters are added.
 

Magus_Prime

Well-known member
Something is still "off" in BatBrains/WHAMs handling of The Thorax. It went to WHAMs round limit and the combat was unwinnable.
I had enough clumsiness bark to win.

Maybe just bad RNG with how often The Thorax drew back to punch. I'll give it another try and see what happens.

For reference: KoL will let you encounter The Thorax even if you don't have enough clumsiness barks to win the combat. If you have less than ten in inventory it's best to walk away. Eight or nine might be enough to win but with ten it seems to be a sure thing.

Edit: Third time around BatBrain/WHAM handled The Thorax.
 
Last edited:

Gawea

New member
Using a fishy wand gives this error:

Expression syntax errors for 'modifier_eval()':
Can't understand underwaterfam/3 (zlib.ash, line 162)
You're on your own, partner.
Click here to continue in the relay browser.
 

zarqon

Well-known member
@Magus: The latest SmartStasis update ought to help out with The Thorax, as well as most other Dis monsters. I'd be interested to know if it uses the skills to farm extra items as well, or if I need to add some code to help persuade it to do that. Also, can you really cast both divine and arcane spells?

@Gawea: it seems the wand has been spaded a bit since I last looked at it -- now it says it only works underwater, so I just changed that keyword to zone(sea).
 

Magus_Prime

Well-known member
SmartStasis isn't but WHAM is using the appropriate "Dis" spells. Not sure what you mean by both divine and arcane spells? Dungeons & Dragons reference? It's been a LONG time. :)

Both The Thorax and The Bat in the Spats was successfully handled by BatBrain/SmartStasis/WHAM although it was almost at the round limit before The Thorax was beaten.

The Terrible Pinch and Thug 1 and Thug 2 were handled without issue.

Mammon the Elephant was handled without issue

The Large-Bellied Snitch was handled but used 13 dangerous jerksicles when only 10 are needed. Here's the combat:

Code:
[1785] The Glacier of Jerks
Encounter: The Large-Bellied Snitch
Strategy: F:\software\Kol\ccs\default.ccs [default]
Round 0: Arbos wins initiative!
WHAM: Running SmartStasis
Round 1: Arbos executes a macro!
Round 1: Arbos casts ENTANGLING NOODLES!
Round 2: Your pet takes a bite that inflicts quite a mark, / and does 11 damage just like a big shark!
Round 2: the large-bellied snitch takes 11 damage.
Round 2: Arbos uses the dangerous jerkcicle!
Round 3: Arbos uses the dangerous jerkcicle!
Round 4: Your familiar did something to help in your plight, / but you were distracted, with monsters to fight.
Round 4: Arbos uses the dangerous jerkcicle!
WHAM: Starting evaluation and performing of attack
Round 5: Arbos executes a macro!
Round 5: Arbos uses the dangerous jerkcicle!
Round 6: Your pet did a thing; I don't know what it did. / Perhaps it went skiing, or huggled a squid?
Round 6: Arbos uses the dangerous jerkcicle!
Round 7: Arbos uses the dangerous jerkcicle!
Round 8: Arbos uses the dangerous jerkcicle!
Round 9: the large-bellied snitch takes 3500 damage.
Round 9: Arbos uses the dangerous jerkcicle!
Round 10: Arbos uses the dangerous jerkcicle!
Round 11: Arbos uses the dangerous jerkcicle!
Round 12: Your pet did a thing; I don't know what it did. / Perhaps it went skiing, or huggled a squid?
Round 12: Arbos uses the dangerous jerkcicle!
Round 13: Arbos uses the dangerous jerkcicle!
Round 14: Arbos uses the dangerous jerkcicle!
WHAM: We are going to 6-shot with Saucegeyser, Weapon of the Pastalord, Weapon of the Pastalord, Weapon of the Pastalord, Weapon of the Pastalord and Weapon of the Pastalord.
Round 15: Arbos executes a macro!
Round 15: Arbos casts SAUCEGEYSER!
Round 16: the large-bellied snitch takes 24 damage.
Round 16: Like the Grumbery birds on the Isle of Berblatt, / Your familiar hits 11 times, just like that!
Round 16: the large-bellied snitch takes 11 damage.
Round 16: Arbos casts WEAPON OF THE PASTALORD!
Round 17: the large-bellied snitch takes 36 damage.
Round 17: Arbos casts WEAPON OF THE PASTALORD!
Round 18: the large-bellied snitch takes 38 damage.
Round 18: the large-bellied snitch takes 5000 damage.
Round 18: Arbos casts WEAPON OF THE PASTALORD!
Round 19: the large-bellied snitch takes 38 damage.
Round 19: Arbos casts WEAPON OF THE PASTALORD!
Round 20: the large-bellied snitch takes 38 damage.
Round 20: Arbos casts WEAPON OF THE PASTALORD!
Round 21: the large-bellied snitch takes 38 damage.
Round 21: the large-bellied snitch takes 5000 damage.
Round 21: Arbos wins the fight!
After Battle: Your pet did a thing; I don't know what it did. / Perhaps it went skiing, or huggled a squid?
You acquire an item: gluttonous stone
You gain 7 Strongness
You gain 21 Magicalness
You gain 18 Roguishness

A better strategy would be to use 10 dangerous jerksicles, funkslinging if possible, then plink until The Snitch impales himself.

This is a HUGE improvement. Thank you!
 
Last edited:

Crowther

Active member
Something's wrong with the damage computation here. BatBrain is prediction 75.88 damage, but I'm taking 113-121. Another hidden sea feature?
Code:
[674] Mer-kin Library
Encounter: Mer-kin drifter
Strategy: /home/scottk/.kolmafia/ccs/Destroy.ccs [default]
Round 0: Crowther loses initiative!
You lose 113 hit points
ATT: 758 (94% × 75.88, death in 7)
DEF: 707 (8.8% × 39.53, win in 262)
HP: 909, Value: 1,721.88 μ, RES: 0
WHAM: Monster HP is 909.0.
WHAM: Running SmartStasis
Profit per round: ActionProfitDamageOtherbase (0μ)0μ--
WHAM: Starting evaluation and performing of attack
WHAM: Enqueuing a stun to help with the battle
WHAM: We are going to 4-shot with Rain-Doh blue balls, Fearful Fettucini, Fearful Fettucini and Clobber.
Round 1: Crowther executes a macro!
Round 1: Crowther uses the Rain-Doh blue balls!
Round 2: mer-kin drifter takes 11 damage.
You lose 121 hit points
Round 2: Crowther casts FEARFUL FETTUCINI!
Round 3: mer-kin drifter takes 405 damage.
You lose 112 hit points
Round 3: Crowther casts FEARFUL FETTUCINI!
Round 4: mer-kin drifter takes 417 damage.
You lose 121 hit points
Round 4: Crowther casts CLOBBER!
Round 5: mer-kin drifter takes 20 damage.
You lose 113 hit points
You lose an effect: Beaten Up
WHAM: Current monster HP is calculated to 910.0

Conditions not satisfied after 1 adventure.
Autorecovery failed.
 

Bale

Minion
I've got a problem. I believe it is the fault of BatBrain, not WHAM, but I cannot be sure. It keeps trying to enqueue my V for Vivala mask after each attack. The result of this is that when WHAM tells me that it is undertaking a series of actions that includes attack, the macro will end with the first attack in that sequence, despite the purple text. Examples:

Code:
[382] Oasis in the Desert
Encounter: swarm of scarab beatles
Strategy: C:\Documents and Settings\David\My Documents\Dropbox\KolMafia\ccs\default.ccs [default]
Round 0: bale loses initiative!
You lose 22 hit points
[COLOR="#800080"]WHAM: Running SmartStasis[/COLOR]
1/4 monsters drop goals here.
WHAM: Starting evaluation and performing of attack
WHAM: We are going to 3-shot with attack with your weapon, attack with your weapon and Toss.
Round 1: bale executes a macro!
Round 1: bale attacks!
Round 2: swarm of scarab beatles takes 178 damage.
You lose 22 hit points
[COLOR="#800080"]WHAM: Starting evaluation and performing of attack
WHAM: We are going to 1-shot with attack with your weapon.[/COLOR]
Round 2: bale executes a macro!
Round 2: bale attacks!
Round 3: swarm of scarab beatles takes 178 damage.
Round 3: bale wins the fight!
You acquire an item: bag of GORP
After Battle: Kyubey surveys the scene from atop the throne, and gains 1 Experience.
You gain 5 hit points
You gain 4 Muscularity Points
You gain 280 Meat
After Battle: Nanael dances around like a pinhead.
You acquire an item: savoy truffle
You acquire an item: rocky raccoon
You acquire an item: Hugo's Weaving Manual
You acquire an item: palm frond
You acquire an item: Maxwell's Silver Hammer
You acquire an item: time's arrow
You gain 52 Fortitude
You gain 16 Wizardliness
You gain 29 Smarm

Casting Fat Leon's Phat Loot Lyric 1 times...
You acquire an effect: Fat Leon's Phat Loot Lyric (duration: 10 Adventures)
Fat Leon's Phat Loot Lyric was successfully cast.
Casting Curiosity of Br'er Tarrypin 2 times...
You acquire an effect: Curiosity of Br'er Tarrypin (duration: 20 Adventures)
Curiosity of Br'er Tarrypin was successfully cast.

Request 4 of 181 (Beach: Oasis in the Desert) in progress...

[383] Oasis in the Desert
Encounter: rolling stone
Strategy: C:\Documents and Settings\David\My Documents\Dropbox\KolMafia\ccs\default.ccs [default]
Round 0: bale wins initiative!
WHAM: Running SmartStasis
1/4 monsters drop goals here.
WHAM: Starting evaluation and performing of attack
WHAM: Enqueuing a stun to help with the battle
[COLOR="#800080"]WHAM: We are going to 9-shot with Entangling Noodles, Toss, Clobber, Clobber, Toss, attack with your weapon, attack with your weapon, attack with your weapon and attack with your weapon.[/COLOR]
Round 1: bale executes a macro!
Round 1: bale casts ENTANGLING NOODLES!
Round 2: Nanael pelts it with a greasy turkey leg, dealing 43 damage.
Round 2: rolling stone takes 43 damage.
Round 2: bale casts TOSS!
Round 3: You pick up Nanael and toss him at your opponent, dealing 16 damage. Go Nanael!
Round 3: rolling stone takes 16 damage.
Round 3: bale casts CLOBBER!
Round 4: rolling stone takes 21 damage.
Round 4: Nanael flicks a ladleful of cold mashed turnips at it, dealing 27 damage.
Round 4: rolling stone takes 27 damage.
Round 4: bale casts CLOBBER!
Round 5: rolling stone takes 21 damage.
Round 5: Nanael flicks a ladleful of cold mashed turnips at it, dealing 32 damage.
Round 5: rolling stone takes 32 damage.
You lose 23 hit points
Round 5: bale casts TOSS!
Round 6: You pick up Nanael and toss him at your opponent, dealing 16 damage. Go Nanael!
Round 6: rolling stone takes 16 damage.
Round 6: Nanael flicks a ladleful of cold mashed turnips at it, dealing 48 damage.
Round 6: rolling stone takes 48 damage.
You lose 23 hit points
Round 6: bale attacks!
Round 7: rolling stone takes 200 damage.
Round 7: Nanael pelts it with a greasy turkey leg, dealing 33 damage.
Round 7: rolling stone takes 33 damage.
Round 7: bale wins the fight!
After Battle: Kyubey surveys the scene from atop the throne, and gains 1 Experience.
You gain 3 hit points
You gain 4 Muscularity Points
After Battle: Nanael dances around like a pinhead.
You gain 48 Beefiness
You gain 23 Wizardliness
You gain 25 Chutzpah

Casting Curiosity of Br'er Tarrypin 2 times...
You acquire an effect: Curiosity of Br'er Tarrypin (duration: 20 Adventures)
Curiosity of Br'er Tarrypin was successfully cast.

Request 5 of 181 (Beach: Oasis in the Desert) in progress...

[384] Oasis in the Desert
Encounter: Glug, Glug, Glug
You acquire an effect: Ultrahydrated (duration: 5 Adventures)

Casting Empathy of the Newt 1 times...
You acquire an effect: Empathy (duration: 10 Adventures)
Empathy of the Newt was successfully cast.
Casting Leash of Linguini 1 times...
You acquire an effect: Leash of Linguini (duration: 10 Adventures)
Leash of Linguini was successfully cast.

Request 6 of 181 (Beach: Oasis in the Desert) in progress...

[385] Oasis in the Desert
Encounter: blur
Strategy: C:\Documents and Settings\David\My Documents\Dropbox\KolMafia\ccs\default.ccs [default]
Round 0: bale wins initiative!
WHAM: Running SmartStasis
1/4 monsters drop goals here.
This monster is the best source of goals (0.98)!
[COLOR="#800080"]WHAM: Starting evaluation and performing of attack
WHAM: Reached WHAM_round_limit while looking for a way to kill the monster. Executing the current strategy and continuing from there.
WHAM: Enqueuing a stun to help with the battle
WHAM: We are going to 10-shot with Entangling Noodles, Toss, Clobber, Clobber, Toss, Toss, Toss, attack with your weapon, attack with your weapon and attack with your weapon.[/COLOR]
Round 1: bale executes a macro!
Round 1: bale casts ENTANGLING NOODLES!
Round 2: bale casts TOSS!
Round 3: You pick up Nanael and toss him at your opponent, dealing 16 damage. Go Nanael!
Round 3: blur takes 16 damage.
Round 3: bale casts CLOBBER!
Round 4: blur takes 21 damage.
Round 4: bale casts CLOBBER!
Round 5: blur takes 21 damage.
Round 5: bale casts TOSS!
Round 6: You pick up Nanael and toss him at your opponent, dealing 16 damage. Go Nanael!
Round 6: blur takes 16 damage.
You lose 28 hit points
Round 6: bale casts TOSS!
Round 7: You pick up Nanael and toss him at your opponent, dealing 16 damage. Go Nanael!
Round 7: blur takes 16 damage.
Round 7: Nanael grabs a fork off of the feast table and hurls it at it, dealing 41 damage.
Round 7: blur takes 41 damage.
You lose 28 hit points
Round 7: bale casts TOSS!
Round 8: You pick up Nanael and toss him at your opponent, dealing 16 damage. Go Nanael!
Round 8: blur takes 16 damage.
Round 8: Nanael tosses a gob of foul-smelling oyster stuffing at it, dealing 23 damage.
Round 8: blur takes 23 damage.
You lose 27 hit points
Round 8: bale attacks!
Round 9: blur takes 1 damage.
You lose 28 hit points
[COLOR="#800080"]WHAM: Starting evaluation and performing of attack
WHAM: We are going to 5-shot with Toss, attack with your weapon, attack with your weapon, attack with your weapon and Toss.[/COLOR]
Round 9: bale executes a macro!
Round 9: bale casts TOSS!
Round 10: You pick up Nanael and toss him at your opponent, dealing 16 damage. Go Nanael!
Round 10: blur takes 16 damage.
Round 10: Nanael pelts it with a greasy turkey leg, dealing 39 damage.
Round 10: blur takes 39 damage.
You lose 28 hit points
Round 10: bale attacks!
Round 11: blur takes 163 damage.
Round 11: bale wins the fight!
After Battle: Kyubey surveys the scene from atop the throne, and gains 1 Experience.
You gain 4 hit points
You gain 4 Muscularity Points
You gain 167 Meat
After Battle: Nanael dances around like a pinhead.
You acquire an item: drum machine
You acquire an item: carbonated water lily
You gain 60 Strengthliness
You gain 22 Mysteriousness
You gain 16 Sarcasm

Conditions satisfied after 6 adventures.

That didn't help much so let's try that at verbosity 9. This is when I figured out the V for Vivala Mask was being equeued as an action.

Code:
[387] Desert (Ultrahydrated)
Encounter: plaque of locusts
Strategy:     C:\Documents and Settings\David\My     Documents\Dropbox\KolMafia\ccs\default.ccs [default]
Round 0: bale wins     initiative!
[COLOR="#A52A2A"]1 HP costs 0.209μ. ( 663 / 1163 )[/COLOR]
[COLOR="#000080"]1     MP costs 8μ. ( 649 / 809 )[/COLOR]
[COLOR="#800080"]WHAM: We     currently think that the round number is: 0 and that the turn number is     386.
WHAM: Checking to see if WHAM sould     adjust the unknown_ml for Plaque of Locusts.
WHAM:     No need to do anything with Plaque of Locusts.
WHAM:     Setting up variables via BatBrain[/COLOR]
You have V for Vivala mask     equipped: 13.2 [COLOR="#FF0000"](13.2)[/COLOR] damage,     stun 0.33, oncrit
You have moveable feast equipped: [COLOR="#0000CD"](11.81)[/COLOR]     damage,
bronzed locust (20.0 @ +226.749371855331):     55μ * 65.35% = 35.94
honey-dipped     locust (20.0 @ +226.749371855331): 115μ * 65.35% = 75.15
handful     of sand (20.0 @ +226.749371855331): 175μ * 65.35% = 114.36
Value     of stat gain: 892.5μ
bronzed locust (20.0 @     +226.749371855331): 55μ * 65.35% = 35.94
honey-dipped     locust (20.0 @ +226.749371855331): 115μ * 65.35% = 75.15
handful     of sand (20.0 @ +226.749371855331): 175μ * 65.35% = 114.36
Value     of stat gain: 892.5μ
ATT: 333 (94% × 33.14, death in 22)
DEF:     324 (97.73% × 107.81 (48),     win in 3)
HP: 345, Value: [COLOR="#008000"]1,117.96 μ[/COLOR],     RES: 0
Parsed round number: 1
Building     options...
Options built! (56 actions)
[COLOR="#800080"]WHAM:     We currently think that the round number is: 1 and that the turn number is     386.
WHAM: Current MP = 649 out of 809.
WHAM:     You have no profitable MP restoratives.
WHAM:     Current HP = 663 out of 1163.
WHAM: You     have no profitable HP restoratives.
WHAM:     You are fighting a Plaque of Locusts. Mafia considers that this monster     has an attack of 333 or 336 when given a monster name.
WHAM:     Mafia further considers that this monster has a defense value of 324 or     326 when given a monster name.
WHAM: Mafia     further further considers that this monster has a HP value of 345 or 342     when given a monster name.
WHAM: Your     current ML-adjustment is: 52.
WHAM: You     have muscle = 330, mysticality = 175, and moxie = 220
WHAM:     Monster HP is 345.0.[/COLOR]
WHAM: WHAM added the     following to BatRound: if pastround 29; abort "Stopping fight because it     has gone on for too long (set WHAM_maxround to a higher value if you think     this was in error)"; endif; 
bronzed     locust (20.0 @ +226.749371855331): 55μ * 65.35% = 35.94
honey-dipped     locust (20.0 @ +226.749371855331): 115μ * 65.35% = 75.15
handful     of sand (20.0 @ +226.749371855331): 175μ * 65.35% = 114.36
Value     of stat gain: 892.5μ
[COLOR="#800080"]WHAM: Attack option     chosen: attack; V for Vivala mask (round 1, profit: 9.66)
WHAM:     Running SmartStasis[/COLOR]
Profit per round:                             Action                          Profit                          Damage                          Other                                      
base; moveable feast; enthroned Li'l Xenomorph [COLOR="#008000"](15.75μ)[/COLOR]                          [COLOR="#008000"]15.75μ[/COLOR]                          0 [COLOR="#0000FF"](11.81)[/COLOR] Actual:           11.81 [COLOR="#008000"](-1.33 μ/dmg)[/COLOR]                                                
    Building custom WHAM actions...
Custom     WHAM actions built! (0 actions)
Building     custom actions...
Custom actions built! (0     actions)
WHAM: Stasis option chosen: skill     5021 (round 1, profit: 1.36)
bronzed locust     (20.0 @ +226.749371855331): 55μ * 65.35% = 35.94
honey-dipped     locust (20.0 @ +226.749371855331): 115μ * 65.35% = 75.15
handful     of sand (20.0 @ +226.749371855331): 175μ * 65.35% = 114.36
Value     of stat gain: 892.5μ
[COLOR="#800080"]WHAM: Attack option     chosen: attack; V for Vivala mask (round 1, profit: 9.66)[/COLOR]
This     monster is not your huckleberry.
Stasis loop     complete.
[COLOR="#800080"]WHAM: SmartStasis complete.
WHAM:     Running SmartStasis took 0.61 seconds.
WHAM:     SS did not finish the fight, continuing with script execution. 
WHAM:     We currently think that the round number is: 1 and that the turn number is     386.
WHAM: Starting evaluation and     performing of attack
WHAM: We currently     think that the round number is: 1 and that the turn number is 386.[/COLOR]
bronzed     locust (20.0 @ +226.749371855331): 55μ * 65.35% = 35.94
honey-dipped     locust (20.0 @ +226.749371855331): 115μ * 65.35% = 75.15
handful     of sand (20.0 @ +226.749371855331): 175μ * 65.35% = 114.36
Value     of stat gain: 892.5μ
[COLOR="#800080"]WHAM: Attack option     chosen: attack; V for Vivala mask (round 1, profit: 9.66)[/COLOR]
WHAM:     Stun option chosen: skill 3004 (round 1, profit: -8.25)
Monster     HP is 345 according to Mafia and 345.0 according to BatBrain.
[COLOR="#FF0000"]WHAM:     We can't Saucesplash.
true, false, false,     true, false[/COLOR]
[COLOR="#800080"]WHAM: We estimate the round     number to currently be 1 (loop variable 0)[/COLOR]
Queued:     skill 3004
Building options...
Options     built! (56 actions)
Monster HP is 345     according to Mafia and 333.1875 according to BatBrain (loop variable i =     1).
Queued: attack; V for Vivala mask
Building     options...
Options built! (56 actions)
bronzed     locust (20.0 @ +226.749371855331): 55μ * 65.35% = 35.94
honey-dipped     locust (20.0 @ +226.749371855331): 115μ * 65.35% = 75.15
handful     of sand (20.0 @ +226.749371855331): 175μ * 65.35% = 114.36
Value     of stat gain: 892.5μ
[COLOR="#800080"]WHAM: Attack option     chosen: attack; V for Vivala mask (round 3, profit: 15.54)
WHAM:     We estimate the round number to currently be 3 (loop variable 2)[/COLOR]
Monster     HP is 345 according to Mafia and 164.08622727272729 according to BatBrain     (loop variable i = 2).
Queued: attack; V for     Vivala mask
Building options...
Options     built! (56 actions)
Parsed round number: 1
Building     options...
Options built! (56 actions)
[COLOR="#800080"]WHAM:     Evaluating the attack but not performing it took 0.95 seconds.
WHAM:     Enqueuing a stun to help with the battle[/COLOR]
Queued:     skill 3004
Building options...
Options     built! (56 actions)
[COLOR="#FF0000"]WHAM: We can't Saucesplash.
true,     false, false, true, false[/COLOR]
[COLOR="#800080"]WHAM: Enqueueing     attack with your weapon (macroid attack; V for Vivala mask). Estimated     damage: 157.28877272727271.[/COLOR]
Queued: attack;     V for Vivala mask
Building options...
Options     built! (56 actions)
[COLOR="#800080"]WHAM: Successfully     enqueued attack with your weapon.[/COLOR]
[COLOR="#FF0000"]WHAM: We     can't Saucesplash.
true, false, false, true,     false[/COLOR]
[COLOR="#800080"]WHAM: Enqueueing attack with your     weapon (macroid attack; V for Vivala mask). Estimated damage:     157.28877272727271.[/COLOR]
Queued: attack; V for     Vivala mask
Building options...
Options     built! (56 actions)
[COLOR="#800080"]WHAM: Successfully     enqueued attack with your weapon.
WHAM: We     are going to 3-shot with Entangling Noodles, attack with your weapon and     attack with your weapon.[/COLOR]
Constructed macro:     scrollwhendone; sub batround; if pastround 29; abort "Stopping fight     because it has gone on for too long (set WHAM_maxround to a higher value     if you think this was in error)"; endif; endsub; skill 3004; call     batround; attack; V for Vivala mask; call batround; attack; V for Vivala     mask; call batround; 
Round 1: bale executes a macro!
Round     1: bale casts ENTANGLING NOODLES!
Round 2: bale attacks!
Round 3:     plaque of locusts takes 138 damage.
Round 3: Nanael pelts it with a     greasy turkey leg, dealing 45 damage.
Round 3: plaque of locusts takes     45 damage.
Happened: skill 3004
Happened:     attack
Parsed round number: 3
Building     options...
Options built! (55 actions)
[COLOR="#800080"]WHAM:     Evaluating the attack and performing it took 3.09 seconds.
WHAM:     Current monster HP is calculated to 162.0
WHAM:     We currently think that the round number is: 3 and that the turn number is     386.
WHAM: We currently think that the     round number is: 3 and that the turn number is 386.
WHAM:     Starting evaluation and performing of attack
WHAM:     We currently think that the round number is: 3 and that the turn number is     386.[/COLOR]
bronzed locust (20.0 @     +226.749371855331): 55μ * 65.35% = 35.94
honey-dipped     locust (20.0 @ +226.749371855331): 115μ * 65.35% = 75.15
handful     of sand (20.0 @ +226.749371855331): 175μ * 65.35% = 114.36
Value     of stat gain: 892.5μ
[COLOR="#800080"]WHAM: Attack option     chosen: attack; V for Vivala mask (round 3, profit: 9.66)
WHAM:     No profitable stun option[/COLOR]
Monster HP is 162     according to Mafia and 162.0 according to BatBrain.
[COLOR="#FF0000"]WHAM:     We can't Saucesplash.
true, false, false,     true, false[/COLOR]
[COLOR="#800080"]WHAM: We estimate the round     number to currently be 3 (loop variable 0)[/COLOR]
Monster     HP is 162 according to Mafia and 162.0 according to BatBrain (loop     variable i = 0).
Queued: attack; V for     Vivala mask
Building options...
Options     built! (55 actions)
Happened: skill 3004
Happened:     attack
Parsed round number: 3
Building     options...
Options built! (55 actions)
[COLOR="#800080"]WHAM:     Evaluating the attack but not performing it took 0.50 seconds.[/COLOR]
[COLOR="#FF0000"]WHAM:     We can't Saucesplash.
true, false, false,     true, false[/COLOR]
WHAM: Enqueueing attack with     your weapon (macroid attack; V for Vivala mask). Estimated damage:     157.28877272727271.
Queued: attack; V for     Vivala mask
Building options...
Options     built! (55 actions)
[COLOR="#800080"]WHAM: Successfully     enqueued attack with your weapon.
WHAM: We     are going to 1-shot with attack with your weapon.[/COLOR]
Constructed     macro: scrollwhendone; sub batround; if pastround 29; abort "Stopping     fight because it has gone on for too long (set WHAM_maxround to a higher     value if you think this was in error)"; endif; endsub; attack; V for     Vivala mask; call batround; 
Round 3: bale executes a macro!
Round     3: bale attacks!
You lose 1 hit point
You lose 22 hit points
Happened:     attack
Parsed round number: 4
Building     options...
Options built! (55 actions)
[COLOR="#800080"]WHAM:     Evaluating the attack and performing it took 4.78 seconds.
WHAM:     Current monster HP is calculated to 162.0
WHAM:     We currently think that the round number is: 4 and that the turn number is     386.
WHAM: We currently think that the     round number is: 4 and that the turn number is 386.
WHAM:     Starting evaluation and performing of attack
WHAM:     We currently think that the round number is: 4 and that the turn number is     386.[/COLOR]
bronzed locust (20.0 @     +226.749371855331): 55μ * 65.35% = 35.94
honey-dipped     locust (20.0 @ +226.749371855331): 115μ * 65.35% = 75.15
handful     of sand (20.0 @ +226.749371855331): 175μ * 65.35% = 114.36
Value     of stat gain: 892.5μ
[COLOR="#800080"]WHAM: Attack option     chosen: attack; V for Vivala mask (round 4, profit: 9.66)
WHAM:     No profitable stun option[/COLOR]
Monster HP is 162     according to Mafia and 162.0 according to BatBrain.
[COLOR="#FF0000"]WHAM:     We can't Saucesplash.
true, false, false,     true, false[/COLOR]
[COLOR="#800080"]WHAM: We estimate the round     number to currently be 4 (loop variable 0)[/COLOR]
Monster     HP is 162 according to Mafia and 162.0 according to BatBrain (loop     variable i = 0).
Queued: attack; V for     Vivala mask
Building options...
Options     built! (55 actions)
Happened: attack
Parsed     round number: 4
Building options...
Options     built! (55 actions)
[COLOR="#800080"]WHAM: Evaluating the     attack but not performing it took 0.50 seconds.[/COLOR]
[COLOR="#FF0000"]WHAM:     We can't Saucesplash.
true, false, false,     true, false[/COLOR]
[COLOR="#800080"]WHAM: Enqueueing attack with     your weapon (macroid attack; V for Vivala mask). Estimated damage:     157.28877272727271.[/COLOR]
Queued: attack; V for     Vivala mask
Building options...
Options     built! (55 actions)
WHAM: Successfully     enqueued attack with your weapon.
WHAM: We     are going to 1-shot with attack with your weapon.
Constructed     macro: scrollwhendone; sub batround; if pastround 29; abort "Stopping     fight because it has gone on for too long (set WHAM_maxround to a higher     value if you think this was in error)"; endif; endsub; attack; V for     Vivala mask; call batround; 
Round 4: bale executes a macro!
Round     4: bale attacks!
Round 5: plaque of locusts takes 138 damage.
Round     5: plaque of locusts takes 37 damage.
Round 5: Nanael grabs a fork off     of the feast table and hurls it at it, dealing 38 damage.
Round 5:     plaque of locusts takes 38 damage.
Round 5: bale wins the fight!
After     Battle: Kyubey surveys the scene from atop the throne, and gains 1     Experience.
You gain 5 hit points
You gain 5 Muscularity Points
You     gain 36 Meat
After Battle: Nanael dances around like a pinhead.
You     acquire an item: honey-dipped locust
You acquire an item: handful of     sand
You gain 52 Strongness
You gain 22 Wizardliness
You gain 16     Cheek
Happened: attack
Parsed     round number: 0
[COLOR="#008000"]Look! You found 1 handful of     sand (175μ)!
Look! You found 1     honey-dipped locust (115μ)![/COLOR]
Happened:     crit
[COLOR="#800080"]WHAM: Evaluating the attack and     performing it took 6.30 seconds.
WHAM: We     currently think that the round number is: 31 and that the turn number is     387.
WHAM: We currently think that the     round number is: 31 and that the turn number is 387.[/COLOR]

I used svn dec to reduce BatBrain, SmartStasis and WHAM to their state before the big "custom" keyword update. I figured that would be safe. That works, but I'm hoping this will be a simple fix so I can update them again.
 
Last edited:

Winterbay

Active member
WHy is the mask merged in together with the normal attack like that? I do not have a mask so may miss some integral feature of it, but it looks a bit odd to have that chosen as one integral action...
 

Bale

Minion
WHy is the mask merged in together with the normal attack like that?

Because it is a bug.

It makes absolutely no sense at all since the mask is NOT an action. Though now it is listed in batfactors as gear. I wonder why gear can get listed in opts.
 

Winterbay

Active member
Well it gets added on line 1105 but I'm not in any way sure why it needs to be there since the action "attack" being performed does not in any way get enhanced by the Mask it is the effect of a potential crit that gets enhanced.
 

morgad

Member
another sea problem?

is this BatBrain or Wham?

Code:
> call scripts/TheSea.ash

Running TheSea.ash version: 1.6.3 (current)
Finding Little Brother in the Octopus's Garden.
You need 1 more wriggling flytrap pellet to continue.
Conditions list cleared.
Condition added: wriggling flytrap pellet

1 HP costs 1.034μ. ( 193 / 326 )
1 MP costs 3.448μ. ( 173 / 358 )
WHAM: We currently think that the round number is: 0 and that the turn number is 979.
WHAM: Checking to see if WHAM sould adjust the unknown_ml for Sponge.
WHAM: No need to do anything with Sponge.
WHAM: Setting up variables via BatBrain
You have plastic pumpkin bucket equipped: (4.99) damage,
sand dollar (10.0 @ +45): 710μ * 14.5% = 102.95
sand dollar (9.0 @ +45): 710μ * 13.05% = 92.66
sand dollar (1.0 @ +45): 710μ * 1.45% = 10.3
slab of sponge (5.0 @ +45): 1,900μ * 7.25% = 137.75
Value of stat gain: 1,196.25μ
Expression syntax errors for 'modifier_eval()':
Expected ,, found
Unexpected end of expr
Expected ), found (zlib.ash, line 162)
You're on your own, partner.
Click here to continue in the relay browser.

best regarrds
DAve
 

Winterbay

Active member
is this BatBrain or Wham?

Code:
> call scripts/TheSea.ash

Running TheSea.ash version: 1.6.3 (current)
Finding Little Brother in the Octopus's Garden.
You need 1 more wriggling flytrap pellet to continue.
Conditions list cleared.
Condition added: wriggling flytrap pellet

1 HP costs 1.034μ. ( 193 / 326 )
1 MP costs 3.448μ. ( 173 / 358 )
WHAM: We currently think that the round number is: 0 and that the turn number is 979.
WHAM: Checking to see if WHAM sould adjust the unknown_ml for Sponge.
WHAM: No need to do anything with Sponge.
WHAM: Setting up variables via BatBrain
You have plastic pumpkin bucket equipped: (4.99) damage,
sand dollar (10.0 @ +45): 710μ * 14.5% = 102.95
sand dollar (9.0 @ +45): 710μ * 13.05% = 92.66
sand dollar (1.0 @ +45): 710μ * 1.45% = 10.3
slab of sponge (5.0 @ +45): 1,900μ * 7.25% = 137.75
Value of stat gain: 1,196.25μ
Expression syntax errors for 'modifier_eval()':
Expected ,, found
Unexpected end of expr
Expected ), found (zlib.ash, line 162)
You're on your own, partner.
Click here to continue in the relay browser.

best regarrds
DAve

That would be a batfactors problem I'd say.try running wham on verboaity 9to get a hint on what formula it is trying to evaluate.
 

zarqon

Well-known member
Several Updates!

Here's what happened in the last three SVN updates.

r10
  • BatBrain now ignores profit from deleveling by default in to_profit(). Profit from deleveling is a look-ahead sort of profit, which BatBrain doesn't do for anything else, and secondly, for simulating an entire combat, the profit from deleveling would be double-counted. Although avoiding this issue creates others, they are issues a calling script can work out.
  • Torment Plant, Pinch Ghost, and Tattle each produce an item the first time they are called against Dis monsters which drop that particular item.
  • As discussed, just like the Bonerdagon, the Sorceress also does not destroy blocked items anymore, so don't consider the cost of multi-usable items against her.

r11
  • Both The Landscaper and Vanya's Creature have non-stat-related damage formulae. Account for those in m_regular().
  • Yellow rays were not always correctly flagged as "custom", so it appears that BatBrain was correctly delaying its automatic response casting, however it was then turning around and recommending YR as a stasis action (it is usually quite profitable to automatically get all the items, after all). I have crossed my fingers hoping that the latest tweak finally fixes yellow raying for fxer and whoever else may benefit from that functionality.
  • With thanks to the friendly warnings, fix all the incomplete names for things so that we can see the end of them.

r12
  • When merging advevents, non-action events (any event that doesn't use up a round, such as your familiar event, the monster event, the retaliation event, the critical event, etc.) should not have their ID's merged with action events. This can lead to the issue reported by Bale. It only recently manifested because I removed the code setting ID's to empty strings, figuring that more information is what the script is all about. This fix retains our superior information without breaking.

Enjoy!
 

atrak

New member
Hi there, I'm not sure if this is something on my end but I keep getting this error now whenever I go to use a combat macro with 'consult SmartStasis.ash' in it.

Bad location value: "the battlefield (frat uniform)" (BatBrain.ash, line 914)
Consult script 'SmartStasis.ash' not found.
You're on your own, partner.

Any ideas? is it just the name thats wrong or is something odd happening on my end?
I tried taking out 'the' but it just spat out some other location errors like the penultimate fantasy airship etc.
 

lostcalpolydude

Developer
Staff member
Hi there, I'm not sure if this is something on my end but I keep getting this error now whenever I go to use a combat macro with 'consult SmartStasis.ash' in it.

Bad location value: "the battlefield (frat uniform)" (BatBrain.ash, line 914)
Consult script 'SmartStasis.ash' not found.
You're on your own, partner.

Any ideas? is it just the name thats wrong or is something odd happening on my end?
I tried taking out 'the' but it just spat out some other location errors like the penultimate fantasy airship etc.

Update mafia
 

morgad

Member
That would be a batfactors problem I'd say.try running wham on verboaity 9to get a hint on what formula it is trying to evaluate.

I will try that on Thurday at the end of the new run. I was getting the error in multiple location that worked ok in-run, and failed in aftercore.
is WHam verbosity seperate from zlibs (I already had verbosity at 9 for the bug report)

best regards
Dave
 

zarqon

Well-known member
You need verbosity 10 to start printing formulas being evaluated. It will still skip formulas that are just numbers unless you set it to verbosity 11, but that's probably almost never necessary. Certainly not in this case as the erroneous formula evidently includes punctuation.
 

fxer

Member
Several Updates!

r11
  • Both The Landscaper and Vanya's Creature have non-stat-related damage formulae. Account for those in m_regular().
  • Yellow rays were not always correctly flagged as "custom", so it appears that BatBrain was correctly delaying its automatic response casting, however it was then turning around and recommending YR as a stasis action (it is usually quite profitable to automatically get all the items, after all). I have crossed my fingers hoping that the latest tweak finally fixes yellow raying for fxer and whoever else may benefit from that functionality.
  • With thanks to the friendly warnings, fix all the incomplete names for things so that we can see the end of them.

Tried it the last 2 days, but no luck it still yellow rays before puttying :/

using batbrain r12, smartstasis r5
 

evilspoons

Member
edit: never mind. I had my WHAM roundcost set to a stupid value that just happened to work with my previous equipment, but the island war frat uniform made it too 'expensive' to use normal spells. Fixed the value, everything seems ok.
 
Last edited:
Top