Skip to content

Commit

Permalink
- ?
Browse files Browse the repository at this point in the history
  • Loading branch information
LordMisfit committed Aug 28, 2016
1 parent 8344426 commit d481236
Show file tree
Hide file tree
Showing 2 changed files with 71 additions and 34 deletions.
Binary file modified acs/spelllib.o
Binary file not shown.
105 changes: 71 additions & 34 deletions scripts/SPELLSRC.acs
Original file line number Diff line number Diff line change
Expand Up @@ -843,6 +843,7 @@ global int 21:MiscellaneousVars[]; // ***ARRAY*** For various permenant vars in
// [10052] "Berserker Fit EX" Perk Level
// [10053] "Wand Mastery" Perk Level
// [10054] "Wand Mastery EX" Perk Level
// [11001] "Higher Learning" Grand Mastery Perk Level

global int 22:MenuSystemVars[]; // Goto "MENUKEY" for array list.

Expand Down Expand Up @@ -8236,6 +8237,15 @@ function int GetExperience (int RealExpGain, int ExpMultiFactor)
int OldExp3 = RealExpGain;
RealExpGain = RealExpGain * MiscellaneousVars[90] / 100; // EXP Multiplier Option
int OldExp4 = RealExpGain;

// "Higher Learning" Grand Mastery Perk
if (MiscellaneousVars[11001] > 0)
{
//PrintBold(d:RealExpGain,s:" [Base (EXPGain)]");
if (CharacterClass == 0 | CharacterClass == 1) RealExpGain = RealExpGain * 115 / 100; // EXP Multiplier Option
if (CharacterClass == 2) RealExpGain = RealExpGain * 110 / 100; // EXP Multiplier Option
//PrintBold(d:RealExpGain,s:" [Higher Learning (EXPGain)]");
}
if (GameSkill() == SKILL_VERY_EASY) RealExpGain = RealExpGain * 25 / 8; // 312.5%
else if (GameSkill() == SKILL_EASY) RealExpGain = RealExpGain * 5 / 2; // 250%
else if (GameSkill() == SKILL_NORMAL) RealExpGain = RealExpGain * 15 / 8; // 187.5%
Expand Down Expand Up @@ -8270,14 +8280,16 @@ script "LevelUpCode" ENTER // (void)
int PerkFactor;
int leveluptimes = 0;
int leveluptimesmax = 200;
int tempaeonpointincrease;
//*******************
//** LEVEL UP CODE **
//*******************
for (leveluptimes = 0; leveluptimes < leveluptimesmax; leveluptimes++)
{
MiscellaneousVars[48] = ExpTable[PlayerLevel] - Experience;
if (Experience >= ExpTable[PlayerLevel])
{
{
tempaeonpointincrease = 0;
if (PlayerLevel < LevelCap)
{
PlayerLevel += 1;
Expand Down Expand Up @@ -8309,79 +8321,86 @@ script "LevelUpCode" ENTER // (void)
{
if (PlayerLevel > 100)
{
if (random(1,100) <= 65) MiscellaneousVars[25] += 1;
if (random(1,100) <= 65) MiscellaneousVars[25] += 1;
if (random(1,100) <= 25) MiscellaneousVars[25] += 8; else MiscellaneousVars[25] += 5;
if (random(1,100) <= 20) MiscellaneousVars[25] += random(3,5);
if (random(1,100) <= 65) tempaeonpointincrease += 1;
if (random(1,100) <= 65) tempaeonpointincrease += 1;
if (random(1,100) <= 25) tempaeonpointincrease += 8; else tempaeonpointincrease += 5;
if (random(1,100) <= 20) tempaeonpointincrease += random(3,5);
}
else
{
if (random(1,100) <= 65) MiscellaneousVars[25] += 1;
if (random(1,100) <= 25) MiscellaneousVars[25] += 5; else MiscellaneousVars[25] += 3;
if (random(1,100) <= 20) MiscellaneousVars[25] += random(1,3);
if (random(1,100) <= 65) tempaeonpointincrease += 1;
if (random(1,100) <= 25) tempaeonpointincrease += 5; else tempaeonpointincrease += 3;
if (random(1,100) <= 20) tempaeonpointincrease += random(1,3);
}
}
else
if (C1 == 1) // Levels [0/2/4/6/8/10/12/14/16/18]4, [0/2/4/6/8/10/12/14/16/18]8, [1/3/5/7/9/11/13/15/17/19]2, & [1/3/5/7/9/11/13/15/17/19]6
{
if (PlayerLevel > 100)
{
if (random(1,100) <= 65) MiscellaneousVars[25] += 1;
if (random(1,100) <= 65) MiscellaneousVars[25] += 1;
if (random(1,100) <= 15) MiscellaneousVars[25] += 3; else MiscellaneousVars[25] += 2;
if (random(1,100) <= 10) MiscellaneousVars[25] += random(1,2);
if (random(1,100) <= 65) tempaeonpointincrease += 1;
if (random(1,100) <= 65) tempaeonpointincrease += 1;
if (random(1,100) <= 15) tempaeonpointincrease += 3; else tempaeonpointincrease += 2;
if (random(1,100) <= 10) tempaeonpointincrease += random(1,2);
}
else
{
if (random(1,100) <= 65) MiscellaneousVars[25] += 1;
if (random(1,100) <= 15) MiscellaneousVars[25] += 2; else MiscellaneousVars[25] += 1;
if (random(1,100) <= 10) MiscellaneousVars[25] += random(0,1);
if (random(1,100) <= 65) tempaeonpointincrease += 1;
if (random(1,100) <= 15) tempaeonpointincrease += 2; else tempaeonpointincrease += 1;
if (random(1,100) <= 10) tempaeonpointincrease += random(0,1);
}
}
else
if (C1 == 2) // Any other level that's not a multiple of 4 or 20
{
if (PlayerLevel > 100)
{
if (random(1,100) <= 65) MiscellaneousVars[25] += 1;
if (random(1,100) <= 65) MiscellaneousVars[25] += 1;
if (random(1,100) <= 65) tempaeonpointincrease += 1;
if (random(1,100) <= 65) tempaeonpointincrease += 1;
if (random(1,10) <= 6) // 60% chance of +2/3 Aeon Points per level
{
if (random(1,100) <= 15) MiscellaneousVars[25] += 3; else MiscellaneousVars[25] += 2;
if (random(1,100) <= 15) tempaeonpointincrease += 3; else tempaeonpointincrease += 2;
}
}
else
{
if (random(1,100) <= 65) MiscellaneousVars[25] += 1;
if (random(1,100) <= 65) tempaeonpointincrease += 1;
if (random(1,10) <= 3) // 30% chance of +1/2 Aeon Points per level
{
if (random(1,100) <= 15) MiscellaneousVars[25] += 2; else MiscellaneousVars[25] += 1;
if (random(1,100) <= 15) tempaeonpointincrease += 2; else tempaeonpointincrease += 1;
}
}
}
}
// Extra AeonPts for "Perk Mode"
if (GetCVar("dvdsperks_active") == 1)
{
MiscellaneousVars[25] += 2;
if (PlayerLevel >= 15) MiscellaneousVars[25] += 1;
if (PlayerLevel >= 30) MiscellaneousVars[25] += 1;
if (PlayerLevel >= 45) MiscellaneousVars[25] += 1;
if (PlayerLevel >= 60) MiscellaneousVars[25] += 1;
tempaeonpointincrease += 2;
if (PlayerLevel >= 15) tempaeonpointincrease += 1;
if (PlayerLevel >= 30) tempaeonpointincrease += 1;
if (PlayerLevel >= 45) tempaeonpointincrease += 1;
if (PlayerLevel >= 60) tempaeonpointincrease += 1;
// 6
if (PlayerLevel >= 75) MiscellaneousVars[25] += 1;
if (PlayerLevel >= 90) MiscellaneousVars[25] += 1;
if (PlayerLevel >= 105) MiscellaneousVars[25] += 1;
if (PlayerLevel >= 120) MiscellaneousVars[25] += 1;
if (PlayerLevel >= 75) tempaeonpointincrease += 1;
if (PlayerLevel >= 90) tempaeonpointincrease += 1;
if (PlayerLevel >= 105) tempaeonpointincrease += 1;
if (PlayerLevel >= 120) tempaeonpointincrease += 1;
// 10
if (PlayerLevel >= 135) MiscellaneousVars[25] += 1;
if (PlayerLevel >= 150) MiscellaneousVars[25] += 1;
if (PlayerLevel >= 165) MiscellaneousVars[25] += 1;
if (PlayerLevel >= 180) MiscellaneousVars[25] += 1;
if (PlayerLevel >= 135) tempaeonpointincrease += 1;
if (PlayerLevel >= 150) tempaeonpointincrease += 1;
if (PlayerLevel >= 165) tempaeonpointincrease += 1;
if (PlayerLevel >= 180) tempaeonpointincrease += 1;
// 14
if (PlayerLevel >= 195) MiscellaneousVars[25] += 2;
if (PlayerLevel >= 195) tempaeonpointincrease += 2;
// 16
}
if (MiscellaneousVars[11001] > 0) // "Higher Learning" Grand Mastery Perk
{
//PrintBold(d:tempaeonpointincrease,s:" [base (AeonPts)]");
tempaeonpointincrease = tempaeonpointincrease * 5 / 4;
//PrintBold(d:tempaeonpointincrease,s:" [Higher Learning (AeonPts)]");
}
MiscellaneousVars[25] += tempaeonpointincrease;

// Increase Stats
// 16:25 (1-100) [64] + 20:25 (101-200) [80] = [Max of 144 (or -75%)]
Expand Down Expand Up @@ -18610,6 +18629,7 @@ script "INGAMEMENUS_MECHANICS" ENTER
// [10052] "Berserker Fit EX" Perk Level
// [10053] "Wand Mastery" Perk Level
// [10054] "Wand Mastery EX" Perk Level
// [11001] "Higher Learning" Grand Mastery Perk Level

// Visual Stuff
script "INGAMEMENUS_DISPLAYS" ENTER
Expand Down Expand Up @@ -28102,6 +28122,14 @@ script "AddSceptreEXP" (int SExPts, int Check2, int DivAmount)
C2 = C2 * (48 + MiscellaneousVars[40]) / 48;
C2 = C2 * MiscellaneousVars[88] / 100;

// "Higher Learning" Grand Mastery Perk
if (MiscellaneousVars[11001] > 0)
{
//PrintBold(d:C2,s:" [base SceptreEXP]");
C2 = C2 * 110 / 100;
//PrintBold(d:C2,s:" [Higher Learning (SceptreEXP)]");
}

if (ModType == 0) C2 = C2 * 4 / 3; // Classic Doom 1/2 / Heretic / Hexen / Strife
MiscellaneousVars[203] += C2;

Expand Down Expand Up @@ -39430,6 +39458,15 @@ script "AddEXP" (int baseamount, int flags, int incrementcombo)
EXPTimerIncrease += (MiscellaneousVars[31] * 4); // 1 point of Agility = 0.2 tics [or 4 units] [5 points = 1 tic (or 20 units)]
EXPTimerIncrease += (MiscellaneousVars[33] * 1); // 1 point of Deftness = 0.05 tics [or 1 unit] [20 points = 1 tic (or 20 units)]
}

// "Higher Learning" Grand Mastery Perk
if (MiscellaneousVars[11001] > 0)
{
//PrintBold(d:EXPTimerIncrease,s:" [base (ComboTimer)]");
EXPTimerIncrease = EXPTimerIncrease * 11 / 10;
//PrintBold(d:EXPTimerIncrease,s:" [Higher Learning (ComboTimer)]");
}

if (PowerupTimer[7] > 0) EXPTimerIncrease = EXPTimerIncrease * 5 / 4;
MiscellaneousVars[157] += EXPTimerIncrease;
if (PowerupTimer[7] > 0)
Expand Down

0 comments on commit d481236

Please sign in to comment.