New Content - Implemented Monster Manuel as monster spading tool

Crowther

Active member
I'm at this point now:

You have casually researched 55 creatures.
You have thoroughly researched 87 creatures.
You have exhaustively researched 518 creatures.

So if you want, you can throw me the same script to see if we have some the other doesn't.

... stupid Butts. hrmph.
Very nice score. You know not what you ask. I didn't write it in ash, it's a set of insanely ugly csh scripts. Now that I know what to do, I really should try doing it in ash, so other can run it.

EDIT:
Monster Manuel
You have casually researched 73 creatures.
You have thoroughly researched 62 creatures.
You have exhaustively researched 323 creatures.
 

Veracity

Developer
Staff member
Wow. That was some seriously ugly hacking I just did, but I got some useful results.
I bet it would be easier and cleaner in ASH. :)

There's a monster with a raw defense of 21. The manual lists that as floor(21*.9), which is 18. ceil(18/.9) is 20 instead of 21. Information is lost.
Really? How do you know the raw defense is 21?

My experience, from looking at hundreds of examples, is that the Manuel displays ceil, not floor. If the Manuel says it is 18, then, by golly, the "raw defense" is 20, not 21. If our data file says it is 21, our data is wrong.

I the end, I kept everything as 90% until the final output, then I convert. If the conversion is unclear, I output both numbers. It's ugly.
I will look at and incorporate your data.

As you probably know, the MM doesn't worry about duplicate names, while monsters.txt tries to have unique names. Also, monsters.txt sometimes includes articles (a, an, the, some) when Manuel doesn't. I managed to ignore those articles.
Ah, yes. We have different names for the Orcish Frat Boys, the Ninja Snowmen, and so on.

Regarding the articles - we may want to include the articles only when KoL itself includes them. We used to always ignore them, but it annoyed me when I was fighting "The Man" and my session log kept saying "Man does 10 damage" or what have you. So, I retained them for monsters that seemed to be unique entities - like constellations, which, strangely, KoL does NOT name that way.

Removing the articles, as appropriate, from monsters.txt at this time might break some scripts...

I skipped some monsters with duplicate names, because my code doesn't handle that well. (nightstands, nemesis forms, protectors, etc)
I have the nightstands.

We should have all 3 nemesis forms in the data files, anyway, since they are effectively different monsters. We can distinguish them by which location they appear in, if not by the image. There may be a bug report about that.

There is a feature request for the protectors. The problem is that they all have the same image and the same location.

Now that I know what to do, I really should try doing it in ash, so other can run it.
I would recommend this. I bet it would be a lot easier, too: Look up each Manuel page of the quest log in turn, iterate over it with a regexp, look up the monster using to_monster( string ), compare the data using monster_attack( monster), monster_defense( monster), and monster_hp( monster), and output a data line if it's different - or if the monster is not present in KoLmafia's database.
 

Veracity

Developer
Staff member
I thought that as rejected?
Yes. I assume it is because you have no way of telling them apart if you don't have a Manuel. As I said, they have the same image, which is how we distinguish the different kinds of frat boys, ninja snowmen, nightstands, knights, and so on.
 

Crowther

Active member
Don't take my comments as requests to change anything (other than monsters.txt stats). I was just listing the problems I ran into. KoL sure is strange on when it considers something to be an article vs proper part of the name. That wasn't a programmer making those decisions.

Really? How do you know the raw defense is 21?

My experience, from looking at hundreds of examples, is that the Manuel displays ceil, not floor. If the Manuel says it is 18, then, by golly, the "raw defense" is 20, not 21. If our data file says it is 21, our data is wrong.
Yes, I think 99% of the time your formula is correct. A good counter example is the beanbat. Manuel says the attack is 21 and the defense is 18. For most of the other bats, raw attack and defense match, so I'd expect the raw defense to be 21, not 20.

EDIT: I should add, I'm not disagreeing with what the monster Manuel does. I'm saying the formula isn't reversible. Information is lost.

Yes, it was a mistake not to write it in ash from the start. I'll try and rectify that shortly. ;)
 
Last edited:

Crowther

Active member
The functions monster_attack and monster_defense return adjusted numbers. This script will list lots of "problems" that aren't if your +ML isn't zero.

Also, it really looks to me like MM is displaying floor(Def*.9) and Mafia is returning ceil(Def*.9), so I get lots of mismatches on perfectly fine monsters. I've no interest in arguing this with Veracity. In addition, this code displays ceil(Def/.9) as requested, but that doesn't properly reverse either MM or Mafia's formula, because neither is reversible.

Enjoy!
 

Attachments

  • checkManuel.ash
    2.9 KB · Views: 41

Veracity

Developer
Staff member
Revision 11555 adds a little support for this - new proxy fields for monsters: raw_hp, raw_attack, and raw_defense. With this you can ignore Monster Level and the .9 defense modifier. I attach a version of your excellent script which uses those and also skips scaling monsters, since the Manuel lists those as 0/0/0 and KoLmafia has expressions that it evaluates for those.

Perhaps I should have made the raw_xxx proxy fields return 0 for such cases. I'll think about that...
 

Attachments

  • checkManuel.ash
    3 KB · Views: 53
Last edited:

Crowther

Active member
Cool!!!!

EDIT:

Some scaling monsters in the MM aren't 0/0/0. WTF?

Hell, yes! It works. . .

So, ignoring the name matching failures and scaling monsters. Here's some monsters.txt updates:

Code:
Grouper Groupie :: Atk: 350 Def: 450 HP: 500
Ice Skate :: Atk: 400 Def: 500 HP: 600
Mer-kin Healer :: Atk: 650 Def: 650 HP: 600
rockfish :: Atk: 300 Def: 300 HP: 400
Roller Skate :: Atk: 450 Def: 400 HP: 700
Skate Board Member :: Atk: 450 Def: 500 HP: 750
Urchin Urchin :: Atk: 400 Def: 350 HP: 600
Caveman Frat Boy :: Atk: 235 Def: 250 HP: 290
Caveman Frat Pledge :: Atk: 255 Def: 230 HP: 220
Caveman Sorority Girl :: Atk: 230 Def: 250 HP: 240
Hobelf :: Atk: 30 Def: 30 HP: 40
Jungle Scabie :: Atk: 90 Def: 90 HP: 100

I'm sure Erich's got plenty more.

EDIT:

I'd like to repeat how big an idiot I was for not coding this in ash from the start.
 
Last edited:

Veracity

Developer
Staff member
You know - I now understand what you meant by ambiguity in defense when using floor. In particular, that there might be more than one defense value that, when multiplied by 0.9, agrees with Monster Manuel.

Revision 11556 reverts certain "fixes" I made to defenses when the old values were perfectly acceptable and the attack == defense, which is a very common pattern.

I also notice that a lot of our difficulty with matching a name with a "monster" could be solved if we stored the image name with the monster in monster.txt; we could then use a "monster monster_by_image( string )" function to look up monster by image, and have a monster.image proxy field to go the other way. Obviously, for things which have the same image - the 5 Protector Spirits, for example - that would not help. But we could disambiguate the various frat boys, ninja snowmen, and so on.

That's be cool, anyway. We could add a list of monsters to our "Internal Database" window. There would be a list of all the monsters we have in monsters.txt. Rather than looking up monster by number, if you clicked on a monster name, we'd pop up a little window with the image, the raw attack/defense/HP, elemental immunities, item drops, whatever we know about it. Sort of like the Wiki's Data:xxx page for each monster. I think I'll make a Feature Request for that.

It would take a fair amount of data entry to add the images - but those of us with large collections in Monster Manuel could help with that a lot, since the Manuel has the images.
 

Erich

Member
I don't know if I'm doing this right, but I ran V's script and this was the output:

Code:
Alielf :: Atk: 90 Def: 90 HP: 90
Ancient Protector Spirit :: Atk: 158 Def: 162 HP: 80
Ancient Protector Spirit :: Atk: 162 Def: 158 HP: 80
Ancient Protector Spirit :: Atk: 160 Def: 156 HP: 80
Ancient Protector Spirit :: Atk: 156 Def: 160 HP: 80
Ancient Protector Spirit :: Atk: 160 Def: 160 HP: 80
Anesthesiologist Bugbear :: Atk: 12 Def: 8 HP: 10
animated nightstand :: Atk: 159 Def: 170 HP: 180
animated nightstand :: Atk: 162 Def: 166 HP: 170
animated nightstand :: Atk: 159 Def: 170 HP: 180
animated nightstand :: Atk: 162 Def: 166 HP: 170
Baron Von Ratsworth :: Atk: 20 Def: 20 HP: 25
Beast with X Ears :: Atk: 0 Def: 0 HP: 0
Beast with X Eyes :: Atk: 0 Def: 0 HP: 0
Box :: Atk: 150 Def: 150 HP: 150
broodling seal :: Atk: 80 Def: 100 HP: 100
Bugbear Drone :: Atk: 135 Def: 135 HP: 150
Bush :: Atk: 156 Def: 156 HP: 150
Candied Yam Golem :: Atk: 1 Def: 0 HP: 1
Centurion of Sparky :: Atk: 150 Def: 200 HP: 200
Clan of Cave Bars :: Atk: 30 Def: 30 HP: 30
Creepy Eye-Stalk Tentacle Monster :: Atk: 8 Def: 6 HP: 6
darkness :: Atk: 99999 Def: 99999 HP: 99999
Deadly Venomtrout :: Atk: 130 Def: 130 HP: 150
Ed the Undying :: Atk: 180 Def: 180 HP: 1
Family of Kobolds :: Atk: 99999 Def: 99999 HP: 99999
Giant Zombie Goldfish :: Atk: 250 Def: 255 HP: 250
Gorgolok, the Infernal Seal :: Atk: 27 Def: 27 HP: 30
Gorgolok, the Infernal Seal :: Atk: 170 Def: 170 HP: 220
Gorgolok, the Infernal Seal :: Atk: 185 Def: 185 HP: 260
Grouchy Furry Monster :: Atk: 6 Def: 7 HP: 8
Grouper Groupie :: Atk: 350 Def: 450 HP: 500
heat seal :: Atk: 175 Def: 175 HP: 200
hermetic seal :: Atk: 110 Def: 200 HP: 150
Hulking Construct :: Atk: 500 Def: 500 HP: 1000000
Hustled Spectre :: Atk: 25 Def: 25 HP: 35
Ice Skate :: Atk: 400 Def: 500 HP: 600
Jungle Scabie :: Atk: 90 Def: 90 HP: 100
knight :: Atk: 115 Def: 115 HP: 130
knight :: Atk: 115 Def: 115 HP: 130
Liquid Metal Bugbear :: Atk: 140 Def: 180 HP: 175
Malevolent Tofurkey :: Atk: 1 Def: 0 HP: 1
Mer-kin Healer :: Atk: 650 Def: 650 HP: 600
Mimic :: Atk: 15 Def: 15 HP: 25
Mimic :: Atk: 25 Def: 25 HP: 35
Mimic :: Atk: 35 Def: 35 HP: 45
N-space Virtual Assistant :: Atk: 175 Def: 175 HP: 180
Naughty Sorceress :: Atk: 190 Def: 190 HP: 400
The Naughty Sorceress (3) :: Atk: 9999999 Def: 9999999 HP: 9999999
Neptune, the Dog that Is a Respected Equal and Not a Pet :: Atk: 45 Def: 45 HP: 80
Ninja Snowman :: Atk: 85 Def: 85 HP: 70
Ninja Snowman :: Atk: 85 Def: 85 HP: 70
Ninja Snowman :: Atk: 85 Def: 85 HP: 70
Ninja Snowman Assassin :: Atk: 150 Def: 150 HP: 0
Orcish Frat Boy :: Atk: 39 Def: 39 HP: 30
Orcish Frat Boy :: Atk: 40 Def: 40 HP: 30
Orcish Frat Boy :: Atk: 41 Def: 40 HP: 30
Orcish Frat Wannaboy :: Atk: 38 Def: 60 HP: 90
Possessed Can of Cranberry Sauce :: Atk: 1 Def: 0 HP: 1
Professor Jacking :: Atk: 85 Def: 85 HP: 200
rockfish :: Atk: 300 Def: 300 HP: 400
Roller Skate :: Atk: 450 Def: 400 HP: 700
Servant of Grodstank :: Atk: 175 Def: 175 HP: 200
shadow of Black Bubbles :: Atk: 175 Def: 175 HP: 200
Skate Board Member :: Atk: 450 Def: 500 HP: 750
Slime Tube monster :: Atk: 100 Def: 100 HP: 200
Smooth Jazz Scabie :: Atk: 95 Def: 95 HP: 140
Spiderbugbear :: Atk: 55 Def: 55 HP: 50
Stuffing Golem :: Atk: 1 Def: 0 HP: 1
Susie Soyburger :: Atk: 50 Def: 40 HP: 90
Timmy Tofurkey :: Atk: 40 Def: 50 HP: 90
Totally Trashed Orquette :: Atk: 48 Def: 60 HP: 90
Trendy Bugbear Chef :: Atk: 200 Def: 200 HP: 250
Trippy Floating Head :: Atk: 20 Def: 20 HP: 20
Trippy Floating Head :: Atk: 20 Def: 20 HP: 20
Trippy Floating Head :: Atk: 20 Def: 20 HP: 20
Trophyfish :: Atk: 5000 Def: 5000 HP: 15000
Urchin Urchin :: Atk: 400 Def: 350 HP: 600
Vanya's Creature :: Atk: 1000 Def: 1000 HP: 3000
Water Spider :: Atk: 130 Def: 130 HP: 150
watertight seal :: Atk: 350 Def: 350 HP: 400
wet seal :: Atk: 175 Def: 175 HP: 200
X Bottles of Beer on a Golem :: Atk: 0 Def: 0 HP: 0
X Stone Golem :: Atk: 0 Def: 0 HP: 0
X-dimensional horror :: Atk: 0 Def: 0 HP: 0
X-headed Hydra :: Atk: 0 Def: 0 HP: 0
(shadow opponent) :: Atk: 150 Def: 99999 HP: 395
[somebody else's butt] :: Atk: 0 Def: 0 HP: 0
 

heeheehee

Developer
Staff member
Hrmm. Maybe an additional field for monpic (the image) would be useful (for disambiguation purposes), or perhaps some metadata, if Manuel has it available, would be useful here? I don't know if such data is available, since I haven't picked up my copy of Manuel yet.
 

Veracity

Developer
Staff member
I don't know if I'm doing this right, but I ran V's script and this was the output:
You done good. Revision 11559. Thanks!

By the way, lost - I noticed you added some monsters. I noticed because of the conflicts I had when I entered Erich's monsters. :) Thanks!

One comment: when I correct - or simply verify - an item in monsters.txt, I change the order of the stats to agree with the Manuel's: the old convention we had was HP/Def/Atk and the Manuel has Atk/Def/HP. This is just a little visual "check" that the entry has been inspected and found to be good.
 
Last edited:

nworbetan

Member
Also, it really looks to me like MM is displaying floor(Def*.9) and Mafia is returning ceil(Def*.9), so I get lots of mismatches on perfectly fine monsters. I've no interest in arguing this with Veracity. In addition, this code displays ceil(Def/.9) as requested, but that doesn't properly reverse either MM or Mafia's formula, because neither is reversible.

Enjoy!

I did some melee damage parsing a while back, and everything that I saw (i.e. when I hit a monster, the damage I saw as a result) agreed perfectly with the ceil(base_def * 0.9) in MonsterData.java, which always felt a little odd to me too. Like maybe on the server side it's doing def -= def * 0.1 or something?
 

charred

Member
my manuel is up to 36-63-649 so i have info on ~750 monsters. im going to assume just paste output here:
Code:
Alielf :: Atk: 90 Def: 90 HP: 90
Ancient Protector Spirit :: Atk: 158 Def: 162 HP: 80
Ancient Protector Spirit :: Atk: 162 Def: 158 HP: 80
Ancient Protector Spirit :: Atk: 160 Def: 156 HP: 80
Ancient Protector Spirit :: Atk: 156 Def: 160 HP: 80
Ancient Protector Spirit :: Atk: 160 Def: 160 HP: 80
animated nightstand :: Atk: 159 Def: 170 HP: 180
animated nightstand :: Atk: 162 Def: 166 HP: 170
animated nightstand :: Atk: 159 Def: 170 HP: 180
animated nightstand :: Atk: 162 Def: 166 HP: 170
Antique Database Server :: Atk: 0 Def: 0 HP: 300
Baron Von Ratsworth :: Atk: 20 Def: 20 HP: 25
Beast with X Ears :: Atk: 0 Def: 0 HP: 0
Beast with X Eyes :: Atk: 0 Def: 0 HP: 0
Box :: Atk: 150 Def: 150 HP: 150
BRICKO Airship :: Atk: 550 Def: 550 HP: 10000
BRICKO Oyster :: Atk: 100 Def: 100 HP: 120
Bush :: Atk: 156 Def: 156 HP: 150
Candied Yam Golem :: Atk: 1 Def: 0 HP: 1
Clan of Cave Bars :: Atk: 30 Def: 30 HP: 30
Cloud of Disembodied Whiskers :: Atk: 2 Def: 3 HP: 3
darkness :: Atk: 99999 Def: 99999 HP: 99999
Ed the Undying :: Atk: 180 Def: 180 HP: 1
Gorgolok, the Infernal Seal :: Atk: 27 Def: 27 HP: 30
Gorgolok, the Infernal Seal :: Atk: 170 Def: 170 HP: 220
Gorgolok, the Infernal Seal :: Atk: 185 Def: 185 HP: 260
Malevolent Tofurkey :: Atk: 1 Def: 0 HP: 1
Mimic :: Atk: 15 Def: 15 HP: 25
Mimic :: Atk: 25 Def: 25 HP: 35
Mimic :: Atk: 35 Def: 35 HP: 45
Naughty Sorceress :: Atk: 190 Def: 190 HP: 400
Ninja Snowman :: Atk: 85 Def: 85 HP: 70
Ninja Snowman :: Atk: 85 Def: 85 HP: 70
Ninja Snowman :: Atk: 85 Def: 85 HP: 70
Orcish Frat Boy :: Atk: 39 Def: 39 HP: 30
Orcish Frat Boy :: Atk: 40 Def: 40 HP: 30
Orcish Frat Boy :: Atk: 41 Def: 40 HP: 30
Possessed Can of Cranberry Sauce :: Atk: 1 Def: 0 HP: 1
Poutine Ooze :: Atk: 3 Def: 2 HP: 3
Slime Tube monster :: Atk: 100 Def: 100 HP: 200
Spooky Hobo :: Atk: 350 Def: 350 HP: 500
Stuffing Golem :: Atk: 1 Def: 0 HP: 1
The Avatar of Sneaky Pete :: Atk: 225 Def: 225 HP: 800
The Luter :: Atk: 75 Def: 75 HP: 100
Trippy Floating Head :: Atk: 20 Def: 20 HP: 20
Trippy Floating Head :: Atk: 20 Def: 20 HP: 20
Trippy Floating Head :: Atk: 20 Def: 20 HP: 20
War Frat Mobile Grill Unit :: Atk: 180 Def: 180 HP: 190
X Bottles of Beer on a Golem :: Atk: 0 Def: 0 HP: 0
X Stone Golem :: Atk: 0 Def: 0 HP: 0
X-dimensional horror :: Atk: 0 Def: 0 HP: 0
X-headed Hydra :: Atk: 0 Def: 0 HP: 0
(shadow opponent) :: Atk: 150 Def: 99999 HP: 395
 

lostcalpolydude

Developer
Staff member
11560 added some new values from there.

War Frat Mobile Grill Unit :: Atk: 180 Def: 180 HP: 190
Veracity already updated this to something different recently...

Cloud of Disembodied Whiskers :: Atk: 2 Def: 3 HP: 3
Poutine Ooze :: Atk: 3 Def: 2 HP: 3
These seem ambiguous so I didn't change them for now.

Many of those are scaling or ambiguous monsters, and something in mafia should probably change to handle that.
 

Veracity

Developer
Staff member
Heh. lost beat me to it, adding your monsters. Thanks!

Revision 11561 adds some more support to help us refine this script:

monster image_to_monster( string ) - looks up monster by image name
monster.image - gets the image name of the monster

I did not add 900+ images. I added specifically those monsters that we disambiguate by image. For example:

Trippy Floating Head (Casey Kasem)
Trippy Floating Head (Grand Moff Tarkin)
Trippy Floating Head (Mona Lisa)

all of which Monster Manuel simply calls "Trippy Floating Head". Contrary to what Erich said on the main G-D thread, it is not that KoLmafia didn't have data for these; it's just that we couldn't unambiguously match the monster given the name in Monster Manuel. We should be able to do that now. Given a little bit of coding. :p

Veracity already updated this to something different recently...
True - but my change was based on the assumption that it was the equivalent of Bailey's Beetle; I hadn't actually seen it. charred gave us real data - and I accept that it is different. After all, you CAN get the War Frat Mobile Grill Unit from the very beginning of your experience on the battlefield, unlike Bailey's Beetle, which requires that you have fought across the battlefield and opened the Junkyard as a Hippy, first.
 
Last edited:

Erich

Member
Contrary to what Erich said on the main G-D thread, it is not that KoLmafia didn't have data for these; it's just that we couldn't unambiguously match the monster given the name in Monster Manuel. We should be able to do that now. Given a little bit of coding. :p

Funny enough, I think I was referring to non head monsters. If I'm not mistaken, I didn't see the Feeling That You're Being Watched stats. I can't go back there just yet though, so I'm just going to assume it was just the floaty heads for now and continue my run.
 

heeheehee

Developer
Staff member
I'm not sure if this is the best place to post this, but I believe tower monsters' HP don't respond to ML (I apparently did 100,017 damage to a malevolent crop circle at 30 ML and killed it), but their attack / defense seems to be affected (the CSA obedience grenade I used at the beginning deleveled by 5001 attack, which is consistent with 100029 base attack, assuming it delevels by 5%, rounded down). Of course, this isn't real spading, since I'm basing this off of one sample. :)

More relevant thought: can't dwarvish war pants be used to disambiguate the ambiguous monsters (according to wiki, variance is rounded down)?
 

Veracity

Developer
Staff member
I believe tower monsters' HP don't respond to ML
We have the mechanism for handling that in monsters.txt: rather than saying the HP is 99999, record it as [99999] - anything in [] is an expression. We use that for scaling monsters, but a constant expression works too.

More relevant thought: can't dwarvish war pants be used to disambiguate the ambiguous monsters (according to wiki, variance is rounded down)?
I expect so. Are you volunteering? :)
 

Crowther

Active member
Okay, I've updated this to parse images and use the monster mafia returns when that works. It seems to work, the code is getting uglier. I got lots of new wrong stats for monsters like Lumpy. I haven't verified if they make more sense than what's in mafia.

I've also added stuff to parse out the number of factoids for each monster. At some point I'm going to want that.

EDIT: Don't use this version. See later post for fixed version. Sorry.
 

Attachments

  • checkManuel.ash
    2.9 KB · Views: 40
Last edited:
Top