Feature Separate out Monster Level from Monster Stats

Darzil

Developer
The meaning of ML has changed somewhat with recent KoL changes. The value of ML is now more important than just controlling a monsters stats, it now affects the way stuns, staggers and damage affect the monster. TPTB have also, it appears, added an effect that adds ML to particular monsters in the Secret Government Lab. Some other existing ML may be similar (Cave Bars? Mother Hellseals?) but would have to be spaded (trivially, but I'm out of turns today, does >150 ML stop staggers working is the simplest test).

My proposal is this :
In monsters.txt, remove ML from monster expressions.
In monsters.txt, allow an optional ML: value entry. This may be an expression, and is a modifier to base ML for that monster.
Still include +ML from all sources in monsters's Attack, Def, HP values displayed in Area Data and relay browser, and in monster proxy fields.
Still include extra initiative from +ML in Area Data and monster proxy fields.
Additionally include +ML in Area Data and add a monster proxy field for ML.
Additionally add +ML to monster expressions (many will need a negative adjustment to HP as +ML increases HP less on scaling monsters) after calculation, as we do for non calculated values.

Questions :
Good idea?
Should we show monster +ML in relay browser along with Attack, Def and HP?
What have I forgotten?
At the moment the following monster expressions do not include base ML, showing monsters unaffected by ML, is this correct?
- Baron von Ratsworth - almost certainly wrong
- Mer-kin balldodger, bladeswitcher, netdragger
- Mother Hellseal
- frog, newt, pig, salamander, grey goo and tomb rat king (monsters that change mid combat)
- your shadow
- Dreadsylvania monsters
- El Dia De Los Muertos Borrachos monsters
- somebody else's butt
Are Spaaaaace and Video Game monsters still capped before ML rather than after?

Edit - Even if we don't do this, I realise we should change all the Exp: calculations to do ML/3 rather than ML/4. But I'm electing not to look at that as that work would be stripped out anyway if I do this.

Edit 2 - Should we actually do scaling monsters differently, and have say, Z-Rex Scale: +5 Cap: 1000 Floor: 10 as KoL has as we see on twitch? Keeping other monster expressions as they are. Scale would mean Atk: MOX + scale value, Def: MUS + scale value, HP: 0.75x (MUS + scale value), Exp: Mainstat + scale value, (capped and floored of course), and ML would only increase HP by 0.75 per ML.
 
Last edited:

lostcalpolydude

Developer
Staff member
At the moment the following monster expressions do not include base ML, showing monsters unaffected by ML, is this correct?
- frog, newt, pig, salamander, grey goo and tomb rat king (monsters that change mid combat)

Those are correct. Those could be handled by a function to process monster stats differently when CLEESH_PATTERN is matched in FightRequest, but there are so few of them that I decided to list it like that for each individual monster instead (especially when I realized someone else already started doing it that way).
 

Darzil

Developer
Hmm, based on my scaling monsters thoughts, and that scaling monsters are the vast majority of expressions :

In monsters.txt, allow an optional Scale: value entry (which can also have Cap: value and Floor: value) which calculates Att, Def, HP, Exp based on MOX+value, MUS+value, 0.75xDef, Mainstat+value respectively, and gains +1, +1, +0.75, +0.33 from Monster Level, above the cap.
In monsters.txt change monsters that fit that profile exactly (most scalers I believe) to use Scale: rather than expressions.
In monsters.txt, allow an optional ML: value entry. This may be an expression, and is a modifier to base ML for that monster.
Still include +ML from all sources in monsters's Attack, Def, HP values displayed in Area Data and relay browser, and in monster proxy fields.
Still include extra initiative from +ML in Area Data and monster proxy fields.
Additionally include +ML in Area Data and add a monster proxy field for ML.
Additionally add +ML to monster expressions for scaling monsters as above (but not expression monsters).
 

Darzil

Developer
Ok, looks like a false alarm, as the monster specific ML thing may not be actually true.

I may well look at scaling for simplification, though.
 

Darzil

Developer
r14827 changes expressions to use ML/3 for ML, except those cases where ML is added before the cap is applied. I am not sure how those will work, or even if they still work like that.

I also suspect that many of the expressions are little suspect and need spading. Do we really have one Feast of Boris monster that has a cap and applies ML, and three that don't? Do we really have many scaling monsters that -ML doesn't work on? Does -ve ML reduce stats gained by ML/4 or ML/3?
 

Fluxxdog

Active member
Well! Let's find out!

Jump into Dreadsylvania castle with -241 ML and no ML increasers (radio off!) as a DB.

Attack was reported at 257, meaning starting attack was 498. This gives us 2 scenarios.

*If EXP is just determined by attack with -ML, EXP should come out to 64.25.
*If EXP is affected by -ML, EXP should come out to (498/4)+(241/3)=124.5-80.3...=40.2

Fight's over, EXP earned was 15/20/33, 15/20/30 adjusting for Vole. Adds up to 65, indicating ML only affects EXP if it's positive. A few more fights give the same results.

Looking at Mafia's sidebar, it's giving me a -29.62 penalty to experience, which would be close to the 241/8, but for some reason, modtrace shows a 1 point Moxie EXP bonus from Disco Bravado. Strange that it's doing that outside of combat...

Double checked maxing out ML, at +143 ML, the sidebar shows a 18.38 EXP bonus. modtrace shows that as a ML/4 bonus.

Looks like more work is need for ML overall. We can safely say this:

if(ML>0) EXPbonus=ML/3;
else EXPbonus=ML/4;
 

Darzil

Developer
It also shows that Dread is affected by ML, but the expressions for Dread don't currently reflect that !
 

Fluxxdog

Active member
There's gonna be a number of questions about how ML will work with certain critters. For example, the Slime Tube: Are slimes affected by ML in the same manner as, say, a rushing bum, or do they get their own special rules? Does bonus ML increase their resistance? Does Slime Hates It increase ML or does it just increase the slime's stats?

Right now, we have a general rule of thumb. ML makes monsters tougher and adjusts their resistance, as well as granting tiered bonuses. It's the exceptions that are gonna make this fun/headachy. <makes a note to play in the Slime Tube tomorrow>
 

Darzil

Developer
Am going to edit in things here for posterity, so we know what state of play was now, and so that no one else has to check them. I'll then bring mafia in line. Currently leaning towards having MLmultipler and MLhpmultiplier as KoL does and applying ML in code, so we don't have loads of complicated lines with -min(ML,0)/4+max(ML,0)/3 in expressions that do cater for it.

Baron von Ratsworth - Wiki is right, Mafia was close but wrong. HP scale to player x 1.25, Att and Def scale with ascensions, cap at scale+13. Monster Level has no effect on the Baron's stats.
Hidden Temple - Mafia is close. Monsters have floors (30 for Cave Bars, 20 for BBB, 7 otherwise), and ignore negative ML, rest was right. Don't know where wiki gets it's +100 on attack!
Thinknerd Warehouse - Mafia is close. Monsters have floors (6 for amok putty, 4 otherwise). Not sure why I had amok putting at scale+21, am only seeing scale+1 now, albeit with higher cap and floor.
Red Queen's Garden - Mafia is close. Monsters have floors (10), and ignore negative ML, rest was right. Croqueteer has no floor, cap of 400.
Hipster Monsters & Black Crayon Monsters - Mafia is close. Monsters have floors (10) and ignore negative ML, rest was right.
Dreadsylvania - Affected by both positive and negative ML, even those that 'scale'.
Giant Rubber Spider - Mafia is close. Has cap of 1000 and is a free fight.
Absinthe monsters - Mafia is close. Have floor of 5, ignore negative ML.
Mt Molehill - Mafia is close, Have floor of 10, ignore negative ML.
Spaaaace - Mafia is close, Have floor of 10, ignore negative ML, positive ML now after cap.
 
Last edited:

Darzil

Developer
Starting to get hopeful that I can simplify this, based on a lot of things previously different coming out the same.

Would be nice to change:
HP: [(max(min(450,MUS+8),10)+max(ML,0))*0.75] Def: [max(min(450,MUS+8),10)+max(ML,0))] Atk: [max(min(450,MOX+8),10)+max(ML,0))] Exp: [max(min(450,STAT+8),10)/4+min(ML,0)/3]
into
SCALE: 8 CAP: 450 FLOOR: 10
for all scaling monsters that have 0.75 hp per Def and aren't affected by negative ML.

So far that'd be all bar Wormwood (which I think I noticed KoL has custom combat code for), Dreadsylvania and Cave Bars. To support Cave Bars we'd additionally need MLMULT: 5 (which could be 0 if we find monsters that don't scale with ML at all - possibly holiday wanderers).
 
Last edited:

Darzil

Developer
r14837 converts monsters.txt to use Scale: X Cap: Y Floor: Z for scaling monsters (monsters which scale Att to moxie + X + ML, Def to muscle + X + ML, have hp 75% of Def, give experience based on mainstat + X + ML, and are affected by positive ML but not negative ML). Also adds MLMult: M (5 for Cave Bars, 0 for some holiday monsters, 1 is assumed if not given).
Also attribute strings are made available to scripters via monster proxy (.attributes) to use in any way they wish.
Tidyup of handling of always win initiative and never win initiative. These are always 10000 and -10000 now, regardless of ML or player initiative, and Location Details shows "Always wins initiative" and "Never wins initiative" rather than 10000 and -10000.

I've checked quite a lot of them, but the following monsters with expressions still need testing for floors, caps and whether +ve or -ve ML affect them:
Full Length Mirror - floor of 10
Ascension Bosses
skulldozer
Basement monsters
Bees Hate You monsters
KOLHS monsters
Heavy Rains monsters
Holiday monsters
Crimbo 2012 elves
disco dancers
accordionists

Edit - Now verified:
Elizabeth Spookyraven - cap and scaling known, no floor
Stephen Spookyraven - cap and scaling known, no floor
four-shadowed mime - cap and scaling known, floor at 3
warbear foot soldiers - cap and scaling known, floor at 20
They - scaling known, cap at 10000, no floor
Holographic Army - scaling known, cap at 10000, no floor
Xiblaxian political prisoner - scaling known, cap at 10000, no floor
pasta wanderers - cap and scaling known, floor at 15 (well, one was, will assume the rest)
spirit world spirits - cap and scaling known, floor at 20 (well, one was, will assume the rest)
 
Last edited:

Fluxxdog

Active member
holographic army:
-25 ML @732 Mus/1811 Mox- HP: 571, Atk: 1841, Def: 762
+0 ML @732 Mus/1970 Mox- HP: 571, Atk: 2000, Def: 762
+20 ML @732 Mus/1811 Mox- HP: 586, Atk: 1861, Def: 782
Falls in line with Scale: 30

Xiblaxian political prisoner
-25 ML @732 Mus/1814 Mox- HP: 579, Atk: 1854, Def: 772
+0 ML @734 Mus/1814 Mox- HP: 580, Atk: 1854, Def: 774
+20 ML @734 Mus/1814 Mox- HP: 595, Atk: 1874, Def: 794
Falls in line with Scale: 40
 
Top