Old awful formula

From OHRRPGCE-Wiki
Jump to: navigation, search

The "old awful" formula for combining elemental values of equipment can be confusing if you do not understand it. This formula was included for compatibility reasons, however it is possible to use it in new games too (although doing so can cause confusion if you aren't careful). This article attempts to explain it.

Note that for the below, nothing stacks except for the "immune bit" which is multiplied for each item; the others only use the highest value of all items and character.

There are four variables to use, called the "immune bit", "weak bit", "strong bit", and "absorb bit". The absorb bit is an actual boolean value; the others are "fuzzy" values which can range from 0 to 1.

To calculate an elemental value:

  • With each equipment, and the character itself, use the element value:
    • If the value is negative, set the absorb bit and then make it positive for the purpose of calculating the rest of these steps.
    • The immune bit is calculated as follows: If the value is less than 12%, then the immune bit is the fraction of 12% which it has; otherwise 100%.
    • The weak bit is calculated as follows: If the value is 100% or more, the result is 0%; if the value is 24% or less, the result is 100%; otherwise it is a linear interpolation between them.
    • The strong bit is calculated as follows: It is 0% if the value is 12% or less, 100% for 24%, 0% for 100%, and above 100% the result is 100% less than the value, and if between 12% and 24% or between 24% and 100%, it is interpolated linearly.
  • Take the product of all immune bits, the highest strong bit, and the highest weak bit.
  • The result is now: (1-.88*weak_bit)*(1+strong_bit)
  • It is made negative if the absorb bit was ever set.

If the number you want to enter is 24% up to 100% (other than 24% and 100% itself) then to figure out what number you actually need to put in, you use the formula: (1043-19*sqrt(2209-2200*x))/1100

If the number you want to enter is 0% up to 24%, or is 100% or more, then just entering the number directly will work.

As an example, if the hero has 37.3% from fire then the result will be you take 50% from fire. If the hero then equips two items both of which also grant 37.3% from fire, the result will still be that you take 50% from fire. Therefore, it is non-stacking. The interactions become more complicated when some equipment has values 24% to 100% and some have more than 100% or less than 24%; you can try calculating it as above in order to figure out how exactly it will work, before attempting to use it.

If any of the above confuses you, then please don't use the old awful formula.