PDA

View Full Version : Resist update


aza77
03-02-2006, 07:34 AM
thanks Hvitrev ;)

diff -u -r 0.6.4/zone/spells.cpp 0.6.4a/zone/spells.cpp
--- 0.6.4/zone/spells.cpp 2006-03-02 15:43:22.000000000 +0100
+++ 0.6.4a/zone/spells.cpp 2006-01-20 16:06:37.000000000 +0100
@@ -2710,38 +2710,9 @@
break;

// solar: I don't know how to calculate this stuff
- // Hvitrev: Primsatic = average of all resists
- // Correct Division?
- case RESIST_PRISMATIC:
- base_resist = resist = (GetDR()+GetMR()+GetFR()+GetCR()+GetPR())/5;
- break;
-
- // Hvitrev: Chromatic = lowest of all resists
- case RESIST_CHROMATIC:
- sint16 tempresist = GetMR();
- sint16 tempresist2 = GetFR();
-
- if ( tempresist < tempresist2 ){
- resist = tempresist;
- }
- else {
- resist = tempresist2;
- }
- tempresist = GetCR();
- if ( tempresist < resist ){
- resist = tempresist;
- }
- tempresist = GetDR();
- if ( tempresist < resist ){
- resist = tempresist;
- }
- tempresist = GetPR();
- if ( tempresist < resist ){
- resist = tempresist;
- }
- base_resist = resist;
- break;
- case RESIST_PHYSICAL:
+ case RESIST_CHROMATIC:
+ case RESIST_PRISMATIC:
+ case RESIST_PHYSICAL:
default:
base_resist = resist = GetMR();
break;

fathernitwit
03-02-2006, 12:23 PM
can you please post text supporting why you think this change is appropriate, im not saying its wrong, I am just not convinced that it is right either.

Is it backwards?

ndnet
03-08-2006, 04:34 AM
It's the case that the Prismatic type is the average value of resists and the Chromatic type is the lowest value among resists. Assuming reading diffs are as intuitive as it looks, it would appear to be backwards in that the '-' lines should be added while the '+' lines are to be removed. It seems in the CVS at the moment, it merely defaults these two resist checks to the value of one's MR.