Project 1999

Go Back   Project 1999 > Server Issues > Bugs

Reply
 
Thread Tools Display Modes
  #1  
Old 08-25-2015, 02:25 PM
Technique Technique is offline
Sarnak


Join Date: Jun 2013
Posts: 451
Default

I undertook the incredibly novel task of buffing particular stats/resists with spells of known value and then debuffing the same stats/resists with spells of known value and observed the results. Rocket surgery, I know.
Reply With Quote
  #2  
Old 08-25-2015, 04:25 PM
Raev Raev is offline
Planar Protector


Join Date: Sep 2014
Posts: 2,290
Default

Quote:
Originally Posted by Technique
If the classic server implementation used only a byte to store stat/resist values, then it obviously shouldn't work like that.
I had to think about this a bit, but I'm fairly sure this is incorrect. Which is why you shouldn't be quite so snippy about being asked to present 'obvious' evidence.

You seem to be mentally implementing this as a running counter: resistMagic = (char)min(255, max(0, (int)resistMagic + buffValue)). Unfortunately this won't work. Imagine we start with a character of max resists and cast GRM which is then dispelled:
  • Initial value: 255
  • With GRM: 255+55 -> 255
  • GRM fades: 255 - 55 -> 200 (!!)

So either the resist magic value was computed from scratch every time a new buff was applied (and this would for sure have been using 32 bit math (not 16 bit kaev you nut) to avoid overflow) and then clamped to an 8 bit range to save memory or the value was stored as a 16 bit integer internally and clamped to 255 for game balance reasons.

TLDR: Daldaen's interpretation seems the most reasonable to me, and it's probably not an accident that P1999's implementation matches this.
Last edited by Raev; 08-25-2015 at 04:28 PM..
Reply With Quote
Reply


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 04:00 PM.


Everquest is a registered trademark of Daybreak Game Company LLC.
Project 1999 is not associated or affiliated in any way with Daybreak Game Company LLC.
Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.