Magic Style Groups and The Correct SC and Mana calculations:

Started by The Crazy Animal, June 23, 2006, 08:40:43 PM

Previous topic - Next topic

0 Members and 3 Guests are viewing this topic.

June 23, 2006, 08:40:43 PM Last Edit: June 25, 2006, 01:03:18 PM by The Crazy Animal
I was playing around to day and realized that the spell casting and mana for the classes were wrong so after playing around most of the day rerolling and placing stats on new characters that I figured out the correct calculations.

I figured I?d put this into an idea to make it easier to make new magic styles so that it would have the most benefit to the game.

Existing Calculations based on my observations:

Mage:
Common Spellcasting bonus: (Every X Stat points : Reward X SC points)
Intellect 2:1
Willpower: 6:1

Mage 1:
Base SC @ LVL 0: 5
Base Mana @ Level 0: 6
SC Level Gain: 2
Mana Level Gain: 2

Mage 2:
Base SC @ LVL 0: 10
Base Mana @ Level 0: 6
SC Level Gain: 2
Mana Level Gain: 4

Mage 3:
Base SC @ LVL 0: 15
Base Mana @ Level 0: 6
SC Level Gain: 2
Mana Level Gain: 6

Priest:
Common Spellcasting bonus: (Every X Stat points : Reward X SC points)
Intellect: 6:1
Willpower: 2:1

Priest 1:
Base SC @ LVL 0: 5
Base Mana @ Level 0: 6
SC Level Gain: 2
Mana Level Gain: 2

Priest 2:
Base SC @ LVL 0: 10
Base Mana @ Level 0: 6
SC Level Gain: 2
Mana Level Gain: 4

Priest 3:
Base SC @ LVL 0: 15
Base Mana @ Level 0: 6
SC Level Gain: 2
Mana Level Gain: 6

Druid:
Common Spellcasting bonus: (Every X Stat points : Reward X SC points)
Intellect: 3:1
Willpower: 3:1

Druid 1:
Base SC @ LVL 0: 5
Base Mana @ Level 0: 6
SC Level Gain: 2
Mana Level Gain: 2

Druid 2:
Base SC @ LVL 0: 10
Base Mana @ Level 0: 6
SC Level Gain: 2
Mana Level Gain: 4

Druid 3:
Base SC @ LVL 0: 15
Base Mana @ Level 0: 6
SC Level Gain: 2
Mana Level Gain: 6

Bard:
Common Spellcasting bonus: (Every X Stat points : Reward X SC points)
Charm: 2:1

Bard 1:
Base SC @ LVL 0: 5
Base Mana @ Level 0: 6
SC Level Gain: 2
Mana Level Gain: 2

Bard 2:
Base SC @ LVL 0: 10
Base Mana @ Level 0: 6
SC Level Gain: 2
Mana Level Gain: 4

Bard 3:
Base SC @ LVL 0: 15
Base Mana @ Level 0: 6
SC Level Gain: 2
Mana Level Gain: 6

Mystic:
Common Spellcasting bonus: (Every X Stat points : Reward X SC points)
None

Mystic 1:
Base SC @ LVL 0: 505
Base Mana @ Level 0: 0
SC Level Gain: 2
Mana Level Gain: 1

Mystic 2: (not used in mmud)
Base SC @ LVL 0: (?) Based on other data it probably would (510) or (505 * 2)
Base Mana @ Level 0: 0
SC Level Gain: 2
Mana Level Gain: 2 (Guessed rate needs checking)

Mystic 3: (not used in mmud)
Base SC @ LVL 0: (?) Based on other data it probably would be (515) or (505 * 3)
Base Mana @ Level 0: 0
SC Level Gain: 2
Mana Level Gain: 3 (Guessed rate needs checking)

The idea to make this stuff easier to code in:

MMUD had all of this type of data hard coded into the game engine so if you wanted to add a class you would have to keep adding code in. So Basically this involves making a data file to hold all of the above information. This data file can then be quarried from the game engine to tell the game to give the proper amounts of SC and Mana.

ID Data:
Magic Group: <#> (# used to ID that magic type)
Magic Group Name: <text> (name simple enough)
Mana Name: <text> (What ever you want the mana to appear as in game: KAI/MANA/PSI...)
Common Spell Casting Data: (There should be one of these for each stat)
(Stat Name:) <#> (# = number of points to get the bonus)
(Stat Name:) SC Bonus: <#> (# = number of bonus SC given for each bonus)
Non-Common Rating Data: (10 sets of below should be good for this for a long time)
Rating: <#> (# = magic rating for this data set.)
Rating variables: <#> (0 = Use defaults for all, 1 = Use custom values)
Base SC: <#> (0 = Use default)
Base Mana: <#> (0 = Use default)
SC Level Gain: <#> (0 = Use default)
Mana Level Gain: <#> (0 = Use default)

Default Data for Magic Ratings: (This works for every class except mystic right now)
Base SC = (5 * Magic Rating)
Base Mana = (6)
Base SC Level Gain = (2)
Base Mana Level Gain = (2 * Magic Rating)

Example for mage:

Magic Group: 1
Magic Group Name: Mage
Mana Name: <Mana> (on Mystics it would be KAI)
Common Spell Casting Data:
Intellect: 2
Intellect SC Bonus: 1
Willpower: 6
Willpower SC Bonus: 1
Non-Common Rating Data:
Rating: 1
Rating variables: 0 (on mystics this would be 1)
Base SC: 0 (on mystics this would be 505)
Base Mana: 0
SC Level Gain: 0 (on mystics this would be 2)
Mana Level Gain: 0 (on mystics this woild be 1)
-----------------------
Rating: 2
Rating variables: 0
Base SC: 0
Base Mana: 0
SC Level Gain: 0
Mana Level Gain: 0
-----------------------
Rating: 3
Rating variables: 0
Base SC: 0
Base Mana: 0
SC Level Gain: 0
Mana Level Gain: 0

Quote from: The Crazy Animal on June 23, 2006, 08:40:43 PM
Mystic 1:
Base SC @ LVL 0: 505
Base Mana @ Level 0: 6
SC Level Gain: 2
Mana Level Gain: 2
Am I reading this right?? Or does mana mean something other than KAI?

From memory, I thought it went more like this:
Base Mana @ Level 0: 0
Mana Level Gain: 1
If we can hit that bulls-eye, the rest of the dominoes will fall like a house of cards.? Check-mate!

The name mana is just there for continuity, So mana could be shown as kai or or mana at the actual character level as all they are is points in the data. I guess I should add a Mana Name Field into the data set though to take care of that. About the base amount I'm almost certain sure you got Kai points prior to getting any powers. It wouldn't be hard to check again though just to be 100% acurate.


Well I can conclusively say that I have a lvl 59 mystic with 58 Kai (on a mmud board).  Without rerolling and lvling and all that, I'd say my memories served me correctly.
If we can hit that bulls-eye, the rest of the dominoes will fall like a house of cards.? Check-mate!

June 25, 2006, 12:57:57 PM #4 Last Edit: June 25, 2006, 01:06:34 PM by The Crazy Animal
Changed it maybe I just typed it wrong I thought I had recorded them right the first time. Added in a Field for MANA Name too.

Looks great so far.  What about mana regen?


TGS v1.0 (coming soon)


Quote from: Locke Cole on June 26, 2006, 11:09:25 PM
All of these formulas are in mmudtype.pas. :P

Well that doesn't help me much since I don't have that file... So someone needs to post the formulas because I can't seem to figure them out right now. All I've figured out is that the mana regen is purely level based and the stat amount only tells it where the next level is that will give you a bonus point.

Quote from: The Crazy Animal on June 27, 2006, 01:08:00 AMWell that doesn't help me much since I don't have that file... So someone needs to post the formulas because I can't seem to figure them out right now. All I've figured out is that the mana regen is purely level based and the stat amount only tells it where the next level is that will give you a bonus point.

That was more or less for Vitoc, since I've nagged him to look over the file for some time. ;) But here's the relevant formulas from the file (as reverse engineered from MMUD for the most part):

{ Calculates the maximum Mana for a given Level and MagicLevel }
function  CalcMP(Level, MagicLevel: integer): integer;
begin
  Result := ((MagicLevel * Level) * 2) + 6;
end;

{ Calculates the maximum Kai for a given Level }
function  CalcKai(Level: integer): integer;
begin
  Result := Level - 1;
end;

{ Calculates SC from a given Level, MagicLevel, INT, WIL, CHA and MagicType }
function  CalcSC(Level, MagicLevel, INT, WIL, CHA: integer; MagicType: TMagicType): integer;
begin
  case MagicType of
    mtMage: Result := (((INT * 3) + WIL) div 6) + (Level * 2) + (MagicLevel * 5);
  mtPriest: Result := (((WIL * 3) + INT) div 6) + (Level * 2) + (MagicLevel * 5);
   mtDruid: Result := ((WIL + INT) div 3) + (Level * 2) + (MagicLevel * 5);
    mtBard: Result := (((CHA * 3) + WIL) div 6) + (Level * 2) + (MagicLevel * 5);
     mtKai: Result := 500 + (Level * 2) + (MagicLevel * 5);
    else
      Result := 0;
  end;
end;

{ Calculates Mage SC from a given Level, MagicLevel, INT and WIL }
function  CalcMageSC(Level, MagicLevel, INT, WIL: integer): integer;
begin
  Result := (((INT * 3) + WIL) div 6) + (Level * 2) + (MagicLevel * 5);
end;

{ Calculates Priest SC from a given Level, MagicLevel, WIL and INT }
function  CalcPriestSC(Level, MagicLevel, WIL, INT: integer): integer;
begin
  Result := (((WIL * 3) + INT) div 6) + (Level * 2) + (MagicLevel * 5);
end;

{ Calculates Druid SC from a given Level, MagicLevel, WIL and INT }
function  CalcDruidSC(Level, MagicLevel, WIL, INT: integer): integer;
begin
  Result := ((WIL + INT) div 3) + (Level * 2) + (MagicLevel * 5);
end;

{ Calculates Bard SC from a given Level, MagicLevel, CHA and WIL }
function  CalcBardSC(Level, MagicLevel, CHA, WIL: integer): integer;
begin
  Result := (((CHA * 3) + WIL) div 6) + (Level * 2) + (MagicLevel * 5);
end;

{ Calculates Mystic SC from a given Level and MagicLevel }
function  CalcMysticSC(Level, MagicLevel: integer): integer;
begin
  Result := 500 + (Level * 2) + (MagicLevel * 5);
end;

Here's a list of functions from the file in case there's another formula you're interested in down the road:

function  CPLevel(Level: integer): integer;
function  CalcExpNeeded(Level, Chart: cardinal): Int64;
function  OldCalcExpNeeded(const Level, Chart: cardinal): cardinal;
function  GetLegalLevel(EP: integer): TLegalLevel;
function  GetEvilLevel(LegalLevel: TLegalLevel): TEvilLevel;
function  CalcMoneyRequiredToTrain(Level, Markup: integer): longword;
function  GetCurrencyStr(Currency: longword): string;
function  CalcEncumbrance(STR: integer; Encum: integer = 0): integer;
function  CalcEncumbrancePercent(Current, Maximum: integer): integer;
function  ConvertCurrency(Runic: longword = 0; Platinum: longword = 0; Gold: longword = 0; Silver: longword = 0; Copper: longword = 0): longword;
function  CalcSellValue(ValueInCopper: longword; CHA: integer): longword;
procedure CleanupCurrency(var Runic, Platinum, Gold, Silver, Copper: longword);
function  CalcCoinWeight(Runic: longword = 0; Platinum: longword = 0; Gold: longword = 0; Silver: longword = 0; Copper: longword = 0): longword;
function  CalcThievery(Level, AGL, INT, CHA: integer): integer;
function  CalcTraps(Level, AGL, INT, CHA: integer): integer;
function  CalcPicklocks(Level, AGL, INT: integer): integer;
function  CalcTracking(Level, INT, WIL, CHA: integer): integer;
function  CalcMR(INT, WIL: integer): integer;
function  CalcPerception(INT, WIL, CHA: integer): integer;
function  CalcStealth(Level, AGL, INT, CHA: integer; StealthType: integer): integer;
function  CalcHP(Random, Level, HEA, MinHPPerLevel: integer): integer;
function  CalcHPRegen(Level, HEA: integer; HPRegen: integer = 0; Resting: boolean = False): integer;
function  CalcMPRegen(Level, INT, WIL, CHA, MagicLevel: integer; MagicType: TMagicType; MPRegen: integer = 0): integer;
function  CalcMA(ItemDodge, Level, AGL, INT, CHA: integer; CanJumpkick: boolean = False): integer;
function  CalcDodge(Encumbrance, Level, AGL, CHA: integer; Dodge: integer = 0): integer;
function  CalcAccuracy(Encumbrance, Combat, Level, AGL, STR: integer; ItemAccuracy: integer = 0): integer;
function  AdjustSpeedForSlowness(Speed: integer): integer;
function  CalcEnergyUsed(Combat, Level, Speed, AGL: integer; STR: integer = 0; ItemSTR: integer = 0): longword;
function  CalcEnergyUsedWithEncum(Combat, Level, Speed, AGL, STR: integer; Encumbrance: integer; ItemSTR: integer = 0): integer;
function  IsQuickAndDeadly(EU, Encumbrance: integer): boolean;
function  CalcQuickAndDeadlyBonus(AGL, EU, Encumbrance: integer): integer;
function  AdjustEnergyUsedWithSpeed(EU, Speed: integer): integer;
function  AdjustEnergyUsedWithEncum(EU, Encumbrance: longword): longword;
function  GetEncumbranceFromPercent(EncumPercent: integer): longword;
function  CalcMP(Level, MagicLevel: integer): integer;
function  CalcKai(Level: integer): integer;
function  CalcSC(Level, MagicLevel, INT, WIL, CHA: integer; MagicType: TMagicType): integer;
function  CalcMageSC(Level, MagicLevel, INT, WIL: integer): integer;
function  CalcPriestSC(Level, MagicLevel, WIL, INT: integer): integer;
function  CalcDruidSC(Level, MagicLevel, WIL, INT: integer): integer;
function  CalcBardSC(Level, MagicLevel, CHA, WIL: integer): integer;
function  CalcMysticSC(Level, MagicLevel: integer): integer;
function  CalcBSDamage(Level, Stealth, Dmg, BsDmgMod, StealthType: integer): integer;
function  CalcMaxDamageBonus(STR: integer): integer;
function  CalcMinDamageBonus(STR: integer): integer;

Quote from: Locke Cole on June 27, 2006, 08:47:52 PM
Quote from: The Crazy Animal on June 27, 2006, 01:08:00 AMWell that doesn't help me much since I don't have that file... So someone needs to post the formulas because I can't seem to figure them out right now. All I've figured out is that the mana regen is purely level based and the stat amount only tells it where the next level is that will give you a bonus point.

That was more or less for Vitoc, since I've nagged him to look over the file for some time. ;) But here's the relevant formulas from the file (as reverse engineered from MMUD for the most part):

Ya I figured that after I posted that responce.

This is the function that I need at the moment for this idea:
CalcMPRegen(Level, INT, WIL, CHA, MagicLevel: integer; MagicType: TMagicType; MPRegen: integer = 0): integer;

Maybe one of you could post it since I don't have the file.


Quote from: The Crazy Animal on June 27, 2006, 11:46:50 PMThis is the function that I need at the moment for this idea:
CalcMPRegen(Level, INT, WIL, CHA, MagicLevel: integer; MagicType: TMagicType; MPRegen: integer = 0): integer;

Maybe one of you could post it since I don't have the file.

Here's that function, as well as the corresponding HP regen function (and also the function for calculating HP altogether, since I imagine it's related to MP/Kai calculations).

{ Calculates MaxHP for a given Random value (*), Level, HEA and MinHPPerLevel

  HOW THIS WORKS--

    At character creation, the player is given their maximum "range" HP roll.
    This range is what is encoded into the MajorMUD classes database.  For
    example, on a Druid, the range is 3, so at level 1, the 'Random' portion
    as listed below is set to 3.  Each time the player trains, a random number
    is generated between 0 and "range"-- going back to Druids again, this means
    the RNG could return 0, 1, 2, or 3, and this value would be summed with
    the already existing 'Random' value.  To determine the maximum possible HP
    for a given level then, you take the "range" and multiply it by the level
    of the char you want the max for, then pass that result as the 'Random'
    value for the function below.  To determine the minimum possible HP for a
    given level, you take the "range" and pass it as the 'Random' value for the
    function below.  You do NOT multiply it because for minimum rolls you'd
    have received all 0's-- the only reason you pass the "range" is for the
    reason stated above: at level 1, MajorMUD gives you the maximum "range"
    roll your class can get.

    Penalties or bonuses such as HP per level (Halfling, Half-Ogre), or Ability
    modifications such as +HP on sunstone wristbands are figured *after* this
    formula is applied. }
function  CalcHP(Random, Level, HEA, MinHPPerLevel: integer): integer;
begin
  Result := ((HEA div 2) + Level * MinHPPerLevel) + (((HEA - 50) * Level) div 16) + Random;
end;

{ Calculates HP regen for a given Level, Health, HPRegen and Resting state }
function  CalcHPRegen(Level, HEA: integer; HPRegen: integer = 0; Resting: boolean = False): integer;
begin
  Result := (((Level + 20) * HEA) div 750);
  if (Result < 1) then
    Result := 1;
  if (Resting) then
    Result := Result * 3;

  Result := ((HPRegen + 100) * Result) div 100;
end;

{ Calculates mana regen from a given Level, INT, WIL, CHA, MagicLevel,
  MagicType and optional MPRegen }
function  CalcMPRegen(Level, INT, WIL, CHA, MagicLevel: integer; MagicType: TMagicType; MPRegen: integer = 0): integer;
begin
  if (MagicType <> mtKai) then begin
    case MagicType of
      mtMage: Result := INT;
    mtPriest: Result := WIL;
     mtDruid: Result := (INT + WIL) div 2;
      mtBard: Result := CHA;
      else
        Result := 0;
    end;
    Result := (((Level + 20) * Result) * (MagicLevel + 2)) div 1650;
  end else begin
    Result := 1;    // Mystics are always 1
  end;
  Result := ((MPRegen + 100) * Result) div 100;
end;

MPRegen is the +ManaRegen ability (seen on some items, like bone necklace, or on spells, like nature tap, earthbind, mana flux, etc).

oooo it makes me all hottt when you guys speak code like that....

I'm thinking that the data fields to control mana regen would go like this:

Mana Regen Use Stats:
Strength (MPR_Str): 0 = no or 1= yes
Agility (MPR_Agi): 0 = no or 1= yes
Health (MPR_Hea): 0 = no or 1= yes
Intellect (MPR_Int): 0 = no or 1= yes
Willpower (MPR_Wil): 0 = no or 1= yes
Charm (MPR_Cha): 0 = no or 1= yes
Use Constant: # (any value here would be the MPR_Calc value see way bottom it will make sence
Use Custom Formula: (text formula) = MPR_Calc

This is how the system would determin the formula:

If the stat is check this is the values:
Strength:
If  MPR_Str = 1
Then (Str_check) = 100000
Else (Str_check) = 0

Agility:
If MPR_Agi = 1
Then (Agi_check) = 10000
Else (Agi_check) = 0

Health:
If MPR_Hea = 1
Then (Hea_check) = 1000
Else (Hea_check) = 0

Intellect:
If MPR_Int = 1
Then (Int_check) = 100
Else (Int_check) = 0

Willpower:
If MPR_Wil = 1
Then (Wil_check)  = 10
Else (Wil_check)  = 0

Charm:
If MPR_Cha = 1
Then (Cha_Check)= 1
Else (Cha_Check)= 0

(Str_check + Agi_check + Hea_check + Int_check + Wil_check + Cha_Check) = MPR_formula_number
(MPR_Str + MPR_Agi + MPR_Hea + MPR_Int + MPR_Wil + MPR_Cha) = MPR_stat_count

This would give a unique number to each of the possible formulas for calculating this part of the formula:

mtDruid: Result := (INT + WIL) div 2

It would look like this though:

MPR_formula_number would then pick the formula like such

110: Result := (INT + WIL) div (MPR_stat_count)

You could also have it filter the amount of formulas down using the MPR_stat_count this might be use full because of the amount of them. Anyway Heres all the formulas for each stat and stat combo.

100000: (Str) div (MPR_stat_count) = base_MPR_stat
10000: (Agi) div (MPR_stat_count) = base_MPR_stat
1000: (Hea) div (MPR_stat_count = base_MPR_stat
100: (Int) div (MPR_stat_count) = base_MPR_stat
10: (Wil) div (MPR_stat_count) = base_MPR_stat
1: (Cha) div (MPR_stat_count) = base_MPR_stat

110000: (Str+Agi) div (MPR_stat_count) = base_MPR_stat
101000: (Str+Hea) div (MPR_stat_count) = base_MPR_stat
100100: (Str+Int) div (MPR_stat_count) = base_MPR_stat
100010: (Str+Wil) div (MPR_stat_count) = base_MPR_stat
100001: (Str+Cha) div (MPR_stat_count) = base_MPR_stat
11000: (Agi+Hea) div (MPR_stat_count = base_MPR_stat
10100: (Agi+Int) div (MPR_stat_count = base_MPR_stat
10010: (Agi+Wil) div (MPR_stat_count = base_MPR_stat
10001: (Agi+Cha) div (MPR_stat_count = base_MPR_stat
1100: (Hea+Int) div (MPR_stat_count) = base_MPR_stat
1010: (Hea+Wil) div (MPR_stat_count) = base_MPR_stat
1001: (Hea+Cha) div (MPR_stat_count) = base_MPR_stat
110: (Int+Wil) div (MPR_stat_count) = base_MPR_stat
101: (Int+Cha) div (MPR_stat_count) = base_MPR_stat
11: (Wis+Cha) div (MPR_stat_count) = base_MPR_stat

111000: (Str+Agi+Hea) div (MPR_stat_count) = base_MPR_stat
110100: (Str+Agi+Int) div (MPR_stat_count) = base_MPR_stat
110010: (Str+Agi+Wil) div (MPR_stat_count) = base_MPR_stat
110001: (Str+Agi+Cha) div (MPR_stat_count) = base_MPR_stat
101100: (Str+Hea+Int) div (MPR_stat_count) = base_MPR_stat
101010: (Str+Hea+Wil) div (MPR_stat_count) = base_MPR_stat
101001: (Str+Hea+Cha) div (MPR_stat_count) = base_MPR_stat
100110: (Str+Int+Wil) div (MPR_stat_count) = base_MPR_stat
100101: (Str+Int+Cha) div (MPR_stat_count) = base_MPR_stat
100011: (Str+Wil+Cha) div (MPR_stat_count) = base_MPR_stat
11100: (Agi+Hea+Int) div (MPR_stat_count) = base_MPR_stat
11010: (Agi+Hea+Wil) div (MPR_stat_count) = base_MPR_stat
11001: (Agi+Hea+Cha) div (MPR_stat_count) = base_MPR_stat
10110: (Agi+Int+Wil) div (MPR_stat_count) = base_MPR_stat
10101: (Agi+Int+Cha) div (MPR_stat_count) = base_MPR_stat
10011: (Agi+Wil+Cha) div (MPR_stat_count) = base_MPR_stat
1110: (Hea+Int+Wil) div (MPR_stat_count) = base_MPR_stat
1101: (Hea+Int+Cha) div (MPR_stat_count) = base_MPR_stat
1011: (Hea+Wil+Cha) div (MPR_stat_count) = base_MPR_stat
111: (Int+Wil+Cha) div (MPR_stat_count) = base_MPR_stat

111100: (Str+Agi+Hea+Int) div (MPR_stat_count) = base_MPR_stat
111001: (Str+Agi+Hea+Cha) div (MPR_stat_count) = base_MPR_stat
111010: (Str+Agi+Hea+Wil) div (MPR_stat_count) = base_MPR_stat
110110: (Str+Agi+Int+Wil) div (MPR_stat_count) = base_MPR_stat
110101: (Str+Agi+Int+Cha) div (MPR_stat_count) = base_MPR_stat
110011: (Str+Agi+Wil+Cha) div (MPR_stat_count) = base_MPR_stat
101101: (Str+Hea+Int+Cha) div (MPR_stat_count) = base_MPR_stat
101011: (Str+Hea+Wil+Cha) div (MPR_stat_count) = base_MPR_stat
100111: (Str+Int+Wil+Cha) div (MPR_stat_count) = base_MPR_stat
11110: (Agi+Hea+Int+Wil) div (MPR_stat_count) = base_MPR_stat
1111: (Hea+Wil+Int+Cha) div (MPR_stat_count) = base_MPR_stat

111110: (Str+Agi+Hea+Int+Wil) div (MPR_stat_count) = base_MPR_stat
111101: (Str+Agi+Hea+Int+Cha) div (MPR_stat_count) = base_MPR_stat
111011: (Str+Agi+Hea+Wil+Cha) div (MPR_stat_count) = base_MPR_stat
110111: (Str+Agi+Int+Wil+Cha) div (MPR_stat_count) = base_MPR_stat
101111: (Str+Hea+Int+Wil+Cha) div (MPR_stat_count) = base_MPR_stat
11111: (Agi+Int+Hea+Wil+Cha) div (MPR_stat_count) = base_MPR_stat

111111: (Str+Agi+Int+wil+cha) div (MPR_stat_count) = base_MPR_stat

From there you would just use the formula

Formula: (((Level + 20) * base_MPR_stat) * (Magic_Rating + 2)) div 1650 = MPR_Calc
Formula: ((MPRegen + 100) * MPR_Calc) div 100 = MPR_Rate

This should take care of every calculation needed.

For mystics I would use (Magic_Rating) and just put it in the Use Custom Formula field then kai 1 would regen 1 and kai 3 would regen 3...

hmmm I'm not sure if I like what I just said adds alot of hardcoding in even though it handles more stuff... argggg what to do...