loathers / garbage-collector

Script for farming meat (and garbage) in 2003 web RPG Kingdom of Loathing
25 stars 57 forks source link

[BUG] Macro Aborted - Unknown predicate: (monsterid 2048 #2046

Closed poshpotato closed 1 month ago

poshpotato commented 1 month ago

Before Reporting Ensure that KoLMafia and garbo are both up to date before reporting a bug. If you have installed mafia in a weird or non-standard way, let us know any details about that here. But also, if you've installed mafia in a weird or non-standard way, I'm telling you right now that that's your bug. Also, check existing github issues to see if this has already been reported. If it has, consider leaving a comment with any additional information you can give on that issue, instead of making a new one.

Also, read this.

Describe the bug Custom Combat SCript fails, aborting garbo, with the message Macro Aborted - Unknown predicate: (monsterid 2048. Exception Combat exception! Last macro error: Macro Aborted - Unknown predicate: (monsterid 2048. Exception KoLmafia error: You're on your own, partner.

To Reproduce Run garbo Have garbo get you into a fight (e.g. NEP fight

Expected behavior Garbo to perform as normal

Session Log nukeboy1313_20240827.txt line 1488

Red Text: JavaScript exception: Combat exception! Last macro error: Macro Aborted - Unknown predicate: (monsterid 2048. Exception Combat exception! Last macro error: Macro Aborted - Unknown predicate: (monsterid 2048. Exception KoLmafia error: You're on your own, partner. (Macro Aborted - Unknown predicate: (monsterid 2048).. (file:/C:/Users/nukeb/Downloads/KolMafia/scripts/garbage-collector/garbo.js#39349) at file:/C:/Users/nukeb/Downloads/KolMafia/scripts/garbage-collector/garbo.js:39349 (f) at file:/C:/Users/nukeb/Downloads/KolMafia/scripts/garbage-collector/garbo.js:40646 (freeFights) at file:/C:/Users/nukeb/Downloads/KolMafia/scripts/garbage-collector/garbo.js:45298 at file:/C:/Users/nukeb/Downloads/KolMafia/scripts/garbage-collector/garbo.js:36851 (withClan) at file:/C:/Users/nukeb/Downloads/KolMafia/scripts/garbage-collector/garbo.js:36845 (withVIPClan) at file:/C:/Users/nukeb/Downloads/KolMafia/scripts/garbage-collector/garbo.js:45279 at file:/C:/Users/nukeb/Downloads/KolMafia/scripts/garbage-collector/garbo.js:36830 (withStash) at file:/C:/Users/nukeb/Downloads/KolMafia/scripts/garbage-collector/garbo.js:45278 (main)

Additional context Suspect this is related to latest update that addresses #2039

RooftopTal commented 1 month ago

Can confirm that I'm also seeing this.

Visit to Mountain: The Dire Warren in progress...

[464] The Dire Warren
Preference lastEncounter changed from Adjust your Parka to cheerless mime executive
Encounter: cheerless mime executive
Preference _monsterHabitatsFightsLeft changed from 1 to 0
Round 0: captain yaksworth wins initiative!
Preference cosmicBowlingBallReturnCombats changed from 1 to 0
Round 0: captain yaksworth casts CURSE OF WEAKSAUCE!
You acquire an item: cosmic bowling ball
Preference cosmicBowlingBallReturnCombats changed from 0 to -1
Round 1: Your toy train moves ahead to the Meat Mine Sluice. It's twice as effective because your train just visited the coal hopper. The sluice opens and pours out some meat!
Preference trainsetPosition changed from 402 to 403
You gain 1,722 Meat.
Round 1: cheerless mime executive drops 19 attack power.
Round 1: cheerless mime executive drops 20 defense.
Round 1: captain yaksworth casts RECALL FACTS: MONSTER HABITATS!
<...>
Round 21: cheerless mime executive takes 1 damage.
Round 21: cheerless mime executive drops 20 attack power.
Round 21: cheerless mime executive drops 19 defense.
Round 21: cheerless mime executive takes 1 damage.
Round 21: You lose 1 hit point
Round 21: captain yaksworth executes a macro!
You're on your own, partner. (Macro Aborted - Unknown predicate: (monsterid 2048)
[Click here to continue in the relay browser.](https://github.com/loathers/garbage-collector/issues/main.php)

Preference _concoctionDatabaseRefreshes changed from 528 to 529
No spading data has been collected yet. Please try again later.
logPreferenceChange => false
Preference logPreferenceChange changed from true to false
logPreferenceChangeFilter => _lastCombatStarted,garboEmbezzlerCount,garboEmbezzlerDate,garboEmbezzlerSources,libram_savedMacro,maximizerMRUList,spadingData,testudinalTeachings
CCS set to default
hpAutoRecoveryTarget => 1
mpAutoRecoveryTarget => 1
libramSkillsSoftcore => all
valueOfInventory => 2
spadingScript =>
choiceAdventure1468 => 3
choiceAdventure1473 => 3
Encounter: cheerless mime executive
You fought 8 cheerless mime executive at the beginning of the day, and an additional 0 digitized cheerless mime executive throughout the day. Good work, probably!
Including this, you have fought 79 across all ascensions today
Extreme Items:
1 cosmic bowling ball worth 0 total
1 cosmic bowling ball worth 0 total
This run of garbo, across 0 turns you generated -4,423 meat, with -4,423 raw meat and 0 from items
So far today, across 0 turns you generated -127,197 meat, with -361,783 raw meat and 234,586 from items
JavaScript exception: Combat exception! Last macro error: Macro Aborted - Unknown predicate: (monsterid 2048. Exception KoLmafia error: You're on your own, partner. (Macro Aborted - Unknown predicate: (monsterid 2048). (file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js#36677)
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:36677 (runCombatBy)
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:36702 (garboAdventureAuto)
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:35173 (runGregFight)
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:35191
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:34948 (run)
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:37832 (runTargetFight)
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:39711
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:36830 (withStash)
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:39619 (dailyFights)
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:45301
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:36851 (withClan)
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:36845 (withVIPClan)
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:45279
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:36830 (withStash)
at file:/C:/Users/TimLedsam/Dropbox/kolmafia/scripts/garbage-collector/garbo.js:45278 (main)
Insulindian-Phasmid commented 1 month ago

Can confirm, I manually fought the mimes but the combat macro still abort during normal barf turns

[2916] Barf Mountain Preference lastEncounter changed from garbage tourist to horrible tourist family Encounter: horrible tourist family Round 0: Insulindian_Phasmid wins initiative! Round 0: Insulindian_Phasmid casts CURSE OF WEAKSAUCE! Round 1: You lose 1 hit point Round 1: Gaginald climbs up and sits on your shoulder, and hands you some Meat. Huh, where did he find that? You gain 94 Meat. Round 1: horrible tourist family drops 5 attack power. Round 1: horrible tourist family drops 7 defense. Round 1: You lose 1 hit point Round 1: Insulindian_Phasmid executes a macro! KoLmafia thinks it is round 2 but KoL thinks it is round 1 Preference lastMacroError changed from Macro Aborted - Unknown predicate: (monsterid 2048 to Macro Aborted ("abort") You're on your own, partner. (Macro Aborted ("abort")) Click here to continue in the relay browser.

linzinha commented 1 month ago

I'm seeing this as well, I wonder if there's been a syntax change around if !(monsterid 2048);

Edit: I seem to have fixed the combat macro by removing the parentheses but am not sure how to set this in the garbo script itself:

if hasskill Curse of Weaksauce;skill Curse of Weaksauce;endif;if hasskill Pocket Crumbs;skill Pocket Crumbs;endif;if hasskill 7273;skill 7273;endif;while !pastround 3 && !hppercentbelow 25;use seal tooth;endwhile;if hasskill Curse of Weaksauce;skill Curse of Weaksauce;endif;if hasskill Northern Explosion;skill Northern Explosion;repeat hasskill Northern Explosion;endif;if !monsterid 2048;if hasskill 1005;skill 1005;repeat hasskill 1005;endif;endif;if hasskill Saucegeyser;skill Saucegeyser;repeat hasskill Saucegeyser;endif;if hasskill Weapon of the Pastalord;skill Weapon of the Pastalord;repeat hasskill Weapon of the Pastalord;endif;if hasskill Cannelloni Cannon;skill Cannelloni Cannon;repeat hasskill Cannelloni Cannon;endif;if hasskill Wave of Sauce;skill Wave of Sauce;repeat hasskill Wave of Sauce;endif;if hasskill Saucestorm;skill Saucestorm;repeat hasskill Saucestorm;endif;attack;repeat;