After a rather exhaustive search through the demo regarding resist, I have this rather long write up regarding resisting spells. My hope is to make it clear why I believe that even during T2A, resist gains were directly based on the damage received from a spell.
First, I would like to walk through the process that all direct damage spells go through before the resist calculation. This is important to understanding exactly how damage is done.
Once all checks in the script for the specific spell have finished, and the damage delay has passed, several pieces of information are passed to a new function. These include the following:
- The spell itself.
- The caster.
- The victim.
- The damage type.
- Whether the spell was reflected or not.
The first thing that's done with this information is to determine the circle of the spell. Once that's done, the next thing that's done is the base damage for the spell is calculated, based on the circle of the spell. Once this basic information has been calculated, the script will double the damage done, if the target is an NPC. Next, the script will calculate the skill of the caster, and apply the following equation to the base damage based on the caster's skill:
Code: Select all
damage = (damage * (caster skill + 50)) / 100
Effectively, the above equation is identical to the tactics modifier for weapon damages, but it is recursive in the sense that magery both determines the damage bonus and the success rate.
In any event, once the damage modifier has been applied, the script finally does the resist check. This is done by first checking to see if the victim is inside guards zone. If they are, then the following piece of code is run:
Code: Select all
integer Q4BI(object user, object usedon, integer damage)
{
if(isDead(usedon))
{
return(0x00);
}
if(Q5ZJ(usedon, 0x1A, Q42P(damage), 0x28) > 0x00)
{
systemMessage(usedon, "You feel yourself resisting magical energy!");
return((damage + 0x01) / 0x02);
}
return(damage);
}
However, if they are not inside guard zone, this code runs:
Code: Select all
integer Q4BH(object user, object usedon, integer damage)
{
if(isDead(usedon))
{
return(0x00);
}
if(testAndLearnSkill(usedon, 0x1A, Q42P(damage), 0x32) > 0x00)
{
systemMessage(usedon, "You feel yourself resisting magical energy!");
return((damage + 0x01) / 0x02);
}
return(damage);
}
So at this point, we now have the following information regarding the way resist functioned in the demo:
- The effective spell damage is based on the Magery of the caster.
- The base spell damage is based on the circle of the spell.
Given this information, we can see that the effective formula for resisting a spell (and gaining) is entirely different from the one presented on stratics. This begs the question: which one is accurate? A highly likely answer comes in the form of the fire field spell. For anyone who played on OSI servers, one of the most common tactics for actually gaining magic resist throughout T2A and UOR was to use fire field up until about 55 - 60 skill (and energy field up until the high 80's during UOR). Using this particular method, we can compare the effectiveness of both methods with some basic facts. The relevant facts are as such:
- If you have no chance to fail at something, you cannot gain in it.
- The magery of the "caster" of a fire field is considered to be zero, because the caster is the fire field itself.
- The base damage for 4th circle is 8 - 29.
So, without getting into the complexities of the success formula itself, let's take a look at the chance to resist a fire field spell using the stratics formula at various levels:
- Skill of 0 = Success chance of 46.8%
- Skill of 25 = Success chance of 93.6%
- Skill of 50 = Success chance of 143.6%
It turns out that using the stratics formula, the chance to resist damage from fire field reaches 100% at only 28.6 skill, thus making it impossible to gain from resist at that point. This is quite obviously an incorrect value as this is approximately half of what should be expected.
Conversely, let's look at the
average chance to resist damage from fire field using the demo formula (I say average because the base damage is part of the calculation):
- Skill of 0 = Success chance of 14%
- Skill of 25 = Success chance of 64%
- Skill of 50 = Success chance of 114%
It turns out that your gains begin to decrease once you hit a base skill of 33, because some of the possible damages from fire field can actually be low enough to be 100% resistible. However, the same is true in the other direction. Even when you reach a base skill of 43, it is still possible to gain off of resist for quite some time, due to the fact that 50% of the damages for resist are still high enough to give you the opportunity to gain. Ultimately, it turns out that resist will cease giving you skill gains at 53 real skill (sound familiar?), due to the fact that all of the values for fire field become 100% resistible at that point.
In any case, the point of this is to show that the stratics formula is likely to be just about dead wrong in this department. In order for their formula to work, the algorithm for determining success rates would have to be completely different from the one in the demo, and we have several pieces of information that show this not to be the case.