Threat and Subtlety Enchants

Topics: Retired
Coordinator
Apr 16, 2008 at 3:13 AM
Please adjust these to use two different stats, ThreatIncreaseMultiplier and ThreatReductionMultiplier, in order to meet the rule of more of a stat being better.
Coordinator
Apr 16, 2008 at 4:12 AM
Edited Apr 16, 2008 at 4:12 AM
Should I add a new _rawInverseMultiplicativeData since the reduction multiplier stacks differently if we have it in this form (a + b - ab compared to a + b + ab)?
Coordinator
Apr 16, 2008 at 4:59 AM
Hmm... Could you implement it as ThreatMultiplier and ThreatDivisor? That would combine using normal multiplication, and still work, right? -2% Threat would just be 0.02040816 ThreatDivisor, I think? I'm not positive that that's right, just guessing while trying to raid. If that doesn't work, then just go ahead with what you suggest.
Coordinator
Apr 16, 2008 at 8:12 AM
That would work technically, but I think it would confuse people.
Coordinator
Apr 16, 2008 at 8:53 AM
While we're talking about stat calculations it might make sense to convert the + operator to unsafe code to speed up the calculations. I'm guessing the bounding checks must cost quite a bit.
Coordinator
Apr 16, 2008 at 4:18 PM
Coincidently, Bashui was going to look into making that change and seeing if it increased the speed much, about a week ago... What happened to that, Bashui?

Regarding Threat... Gneh, sure, add a _rawInverseMultiplicativeData I guess.
Apr 18, 2008 at 3:43 PM
I have done some performance timing and it seem like the best bet is unsafe, with:
while(--i >=0)
{
   c._rawAdditiveData[i] = a._rawAdditiveData[i] + b._rawAdditiveData[i];
}

I'll be checking this in shortly.
Coordinator
Apr 18, 2008 at 9:03 PM


Bashui wrote:
I have done some performance timing and it seem like the best bet is unsafe, with:
while(--i >=0)
{
   c._rawAdditiveData[i] = a._rawAdditiveData[i] + b._rawAdditiveData[i];
}

I'll be checking this in shortly.


The code you ckecked is not unsafe. Are you still working on it or did you find it doesn't improve performance?