Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Development

Development::Development Forum for development topics and for those interested in EQEMu development. (Not a support forum)

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 06-05-2025, 03:31 AM
Torven
Sarnak
 
Join Date: Aug 2014
Posts: 76
Default A Comprehensive Study of EverQuest's Classic Resist System

Over the last year I've been spending a lot of time trying to figure out as much of EverQuest's original resist system as I could and this document will detail my knowledge of it. This research is largely based on decompiles given to me by Kicnlag and some I've produced myself. Kicnlag discovered that the Kunark and earlier era clients had the server-side resist logic in them. (Sony stopped including it in the Velious and later clients) This is a huge discovery and it turns out that the classic resist system was considerably harsher than we realized. As it plays a very important part in the balance of the classes and the game's difficulty, it's important to get it accurate.

We used a program called Ghidra to spit out decompiles of the client binaries and we then figured out what most of the variable names and literals are to make the code understandable. Since I'm familiar with the modern resist math it wasn't that difficult for me to decipher what the variable names are. We have only two clients from the pre-Kunark era, which are February 16 1999 (the launch CD client) and March 21 2000 (one month before Kunark). There are many clients available in the Kunark era however and we are able to view some of the evolution of the algorithm up to Velious. The latest client with the resist logic is November 29 2000 (one week before Velious) and that is the most valuable binary for this research.

All but the February 1999 client binaries were obtained from here: https://web.archive.org/web/*/everqu...wnload/patch/*

Decompiles are extremely compelling but not necessarily 100% proof. I checked all available sources to try and verify the code authenticity, and I can say that everything found in the decompiles ended up correct and explainable. Not all of the resist logic is found in that one resist function however, and the Kunark clients do not have some of this remainder. For that I had to figure it out the old fashioned way. The only significant pieces I could not nail down were wizard and dragon breath lure behavior from December 5 2000 until Sept 4 2002 but otherwise this document should explain just about everything. Although there could be unknown unknowns.

Note: in this document I'll be referring to the entire time period from before September 4 2002 as "classic" unless I say "pre-K classic" to indicate the era before April 24 2000.


Classic Resist Rolls

The most significant finding we discovered is that in classic EQ, spell resist rolls were 0 to 99. This was the case up until September 4 2002 when it switched to 0-199. A "roll" here means a randomly generated number from X to Y, which is then compared against the effective resist value, which is the target's resist after all modifiers are applied to it. If the roll is lower than or equal to the effective resist value then the spell is resisted.

It's important to understand the significance of this. This means that every single point of resist from gear or buffs increased your chance to resist an all-or-nothing spell back then by 1%. Resists were essentially twice as powerful in the classic eras when resisting against most spells. (there are exceptions which I explain later) This meant that the buff Group Resist Magic by itself increased your chance to resist by 55%, so only having this buff on while naked for most races/classes made the magic resist rate 80%. Resisting all-or-nothing spells in classic EQ was much easier, for both PCs and NPCs.

This finding explains why some of Sony/Daybreak's developer comments mentioned a "resist chance" variable in place of what is obviously "effective resist value", which in the newer logic is one resist value = 0.5% resist chance. Prathun's 2010 pseudocode says this and some other sources also confused resist chance with resist value which I mention in my Charm, Root, Lull thread. The reason is simply because in September 2002 Sony changed the scale from 0-99 to 0-199.

This also explains why many resist modifiers seemed so weak/trivial. The resist modifier from level difference for example is found in the old clients, which is level^2 / 2. So an NPC five levels above you only reduces your effective resist by twelve points, which seemed rather trivial under the PoP era mechanics. This caps at -40 in the case of a higher level PC vs an NPC, meaning when fighting green cons you only gain a 40 resist value advantage. If the scale is 100 points wide instead of 200, then these modifiers are twice as significant.

The September 4 2002 patch was a massive buff to caster DPS for this and other reasons which I will go into. This is the primary reason why casters are so overpowered right now on the emu servers in the early game.

Other Evidence For The 0-99 Scale

I did check for logs to try and verify if the 0-99 scale applied in Velious and Luclin eras, and it was easy to find. In November 2001, three weeks before Luclin opened, I had produced logs against the mist panther NPC in Wakening Lands to parse my DPS with various weapons. One weapon was my Scepter of Destruction. This weapon procs Anarchy. Before September 4 2002 it was an all-or-nothing spell. The mist panther has a typical resist value of 35 MR and it's a level 60 mob so the level difference modifier does not apply in this case. I added up the resists in my mist panther logs and the resist rate was 36% in 300+ procs, which was the expected rate.

My personal logs yielded more evidence: I found in them that I was resisting certain spells very easily without a bard, like Thunder Blast. That spell is cast by blue drakes in Temple of Veeshan. I was a warrior with Halls of Testing armor, and I resisted 60 out of 61 casts, which agrees with a 0-99 scale, as with that equipment the MR would have been under 200. I have screenshots from the time period showing my MR value. (note: the spell was all-or-nothing at the time)

I also found a log from the tipa16384 archive (https://github.com/tipa16384/harcour.../tree/main/DSR) which agreed with 0-99. The Nina character was a 48 halfling warrior with a cold resist buff on (so 65 CR) while in the Great Divide cave fighting a AoEing wurm, and the full hit rate was only 9 out of 36 casts (25%) of Shardwurm Breath. The partial damage also matched the Kunark logic and not the post-Sept 2002 logic.

PvP would have been dramatically impacted by the change to a 0-200 resist scale, so I went looking for posts made by PvP players and I found them.

Here are some comments made right after the September 4 2002 patch:

Thread title: Resist changes

"Bards can pvp at 55 again. People with 120+mr aren't invincible to me anymore. I engaged 6 people in about 20 minutes and dropped all of them. Slow/snare is USEFUL! YAY! And of course, the best thing about this is that the people with crappy low resist no drop gear get their butts totally handed to them every time now." (09/04/02)

"I GOT MEZED YESTERDAY FOR TEH FIRST TIME IN LIKE 8 MONTHS!" (09/06/02)
https://web.archive.org/web/20031127...b=5&o=&fpart=1

Thread title: verant has to change resists back

"As a warrior I am going to get owned by all classes now...including paladins and rangers. With gear on all my resists were well over 100, which I don't think is bad for a pure melee" (09/05/02)

"yea these resists are fucked up i get snared easy as hell with 122 mr on my sk, same with my wiz thats got 112 mr i meant wtf how am i sposed to get my mr to fuckin 250! such bullshit i really hope they change it back" (09/05/02)

"i was snared for the first time in months with a 141 MR i was shocked and it was some shity ranger" (09/06/02)
https://web.archive.org/web/20031127...b=5&o=&fpart=1


I also found some great Casters Realm threads from 2000 about players who did resist tests to find out the effectiveness of charisma on mez spells. This first guy did tests at 25 MR and 80 MR by casting on a second player. The resist rates were expected using the 0-99 scale:
https://web.archive.org/web/20001018...ML/002086.html

Another guy mezed himself at 25 MR, 50 MR, and 99 MR. The results were as expected using the 0-99 scale. (note that CHA will reduce resist rates a bit, thus the resist rate is not exactly equal to the resist value in these tests) He also did PvE mez tests on a guard NPC, and the reduction in resist rates from Tashania being applied agreed with a 0-99 roll.
https://web.archive.org/web/20020816...c&f=9&t=003257

Note: the PvP resist scale was modified shortly after September 4 2002 which I will explain in a later section.


The Level Difference Resist Floor

The second most significant discovery in the decompiles is the existence of a level difference resist floor which was removed in the September 4 2002 patch and applies to virtually all spells. This floor is similar to the tick save floor which I discussed in another thread. Spells with tick saves do a periodic resistance check and the reason why charm for example can never be guaranteed to last the full duration is because the magic resist is floored to a minimum value which is always above zero. This level difference floor cannot be debuffed under like tick saves, meaning it was not possible to debuff resists down to zero in classic EQ, meaning even debuffed level one newbie area mobs could resist spells from level 50s. This is not the case post Sept 2002 where effective resists can be and very often are zero after debuffs and level difference.

Some spells did ignore this floor however. Lifetaps, lures and unresistable spells were hardcoded to skip the final resist roll entirely thus were not subjected to the floor. Certain DoT spells used the partial damage resist scale even though they were essentially debuffs and this allowed them to hit through the floor because even when failing the roll the partial damage math allowed the spell to land. (Druid magic DoTs and Necro fire DoTs)

For NPC targets, the floor was computed like this:

Code:
level_diff = target_level - caster_level

if (level_diff > -11 and target_level > 14 and final_resist < 10) then
	final_resist = 10
end
if (level_diff < -20 or target_level < 15) then
	floor = 2
else
	floor = 5
end

if (final_resist < floor) then
	final_resist = floor
end
Which means: mobs within 10 levels of the caster (except newbie levels, so the vast majority of dark blues) and all NPCs above dark blues had a floor of 10. Most greens had a floor of 2. Stuff between had a floor of 5. Since the rolls were 0-99 and the comparison used a < instead of <= this means that the actual resist rates were 11%, 6% and 3%. (I discuss roll logic in more detail in a later section)

For player/client targets, the floor was always 1.

This is a controversial discovery so I realize that ample evidence is required to convince people. Part of EQ's original ethos was to not have guarantees, so a resist floor makes perfect sense to have existed. It shouldn't be that controversial but players hate nerfs. The following is log file and old user comment evidence of this floor.

We do have pre-Sept 2002 era logs to examine. Finding proof in these logs isn't difficult. I still have some of my own logs of my wizard casting AoE spells on NPCs low enough in level that the effective resist on them should be zero without a floor, but resists are seen. One case in particular was when I was AoEing mobs in the Fungus Grove zone, casting AoEs on mushrooms and dregs. Since AoE spells were used it provides a lot of spell hits. The resist rates and partial damage values matched the Kunark client spell resist logic. Dregs have a level range of 49 to 53, so most dregs would end up having a 10 resist floor, and the resists I saw in the log showed dregs resisting at a higher rate than the sub level 50 mushrooms, and the partial damage hits showed dregs having resist values of 10 and 5 as expected. This alone is quite irrefutable although my logs aren't public.

You need not take my word for this. You can download old 2001 logs from the tipa16384 archive (https://github.com/tipa16384/harcour.../tree/main/DSR) and you will find her doing quad kites in Cobalt Scar on a mid 50s druid, and she gets snare resists on the wyverns.

Here is also a case of her level 55 druid getting a full Ensnare resist on a level 12 or under NPC in Crushbone: (she had an amusing snare macro)

File: etha_log_021502.txt
[Mon Dec 24 04:22:19 2001] You begin casting Ensnare.
[Mon Dec 24 04:22:19 2001] You say, 'Hopefully, orc legionnaire is snared now.'
[Mon Dec 24 04:22:21 2001] Your target resisted the Ensnare spell.
[Mon Dec 24 04:22:24 2001] You emote 'magically ensnares orc legionnaire, bringing it to a crawl!'

again, these aren't hard to find:

[Mon Dec 24 04:26:40 2001] You emote 'magically ensnares orc centurion, bringing it to a crawl!'
[Mon Dec 24 04:26:41 2001] You begin casting Ensnare.
[Mon Dec 24 04:26:41 2001] You say, 'Hopefully, orc centurion is snared now.'
[Mon Dec 24 04:26:42 2001] Your target resisted the Ensnare spell.

A Usenet poster in July 2002 posted an AoE log in Sebilis from a wizard's perspective here: https://groups.google.com/g/alt.game...m/l4m4vFVmMw8J

Notice that the Zephyr of Ice spell was getting partial hits. This spell has and had an innate -10 modifier on it and it's a level 56 spell so he is at least level 56. Combined with level difference he would have overtaken the entire 35 standard cold resist. In fact one of his partial hits was on a zol knight which is the lowest level frog in the zone. The partial damage numbers also agree with effective resist values of 5 and 10.

I found some discussions on an EQ Bard mailing list about bard mezes from early 2000. These bards cast thousands of mez songs on NPCs to get resist rates. The results clearly showed the 3% floor on level 1 greens and the 6% floor on high greens and low dark blues. In one post a bard mentions a "5% cap". This is extremely compelling:
https://dbsanfte.github.io/eq-archiv...tml/14644.html
https://dbsanfte.github.io/eq-archiv...tml/13968.html

"My experience is more with about 20-30 mob pulls than 50, but I seem to get about 10% resists. Ie, for each cast of stun, if we have about 25 mobs there, I see one to four resist messages, usually" (Jul 22, 2002)
https://groups.google.com/g/alt.game...m/waylPHHZsv8J

"Even things that are deep, deep green to him are resisting spells at annoyingly high rates" (April 2002)
https://dbsanfte.github.io/eq-archiv...msg-105695.txt
Reply With Quote
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 03:06 AM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3