Thank you, unfortunately, those aren't public and there're no public methods that can be overriden or that modify those values, as the result I see no way to change those values.
Right now the mod looks like this:
Code: Select all
public class ModStaticLeveling : MonoBehaviour
void Start ()
FormulaHelper.formula_2de_2i.Add ("CalculateHitPointsPerLevelUp", (de1, de2, a, b) =>
var player = de1 as PlayerEntity;
int setHitPoints = 25 + player.Career.HitPointsPerLevel + (player.Level - 1) * (player.Career.HitPointsPerLevel + FormulaHelper.HitPointsModifier (player.Stats.LiveEndurance));
int addHitPoints = setHitPoints - player.MaxHealth;
if (addHitPoints < 0)
addHitPoints = 0;
//DaggerfallCharacterSheetWindow.minBonusPool = 6;
[Invoke (StateManager.StateTypes.Game, 0)]
public static void Init (InitParams initParams)
GameObject go = new GameObject ("ModStaticLeveling");
ModManager.Instance.GetMod (initParams.ModTitle).IsReady = true;
mikeprichard wrote: ↑
Fri Mar 08, 2019 9:33 pm
Oh wow, UserOfThisSite, so glad to see someone skilled and willing to implement these improvements I've been hoping for for a very long time! As one player who will always be using this mod (static leveling to "fix" Endurance and remove the annoying randomized stat/health points on level up) after you're able to complete it - thank you!
Endurance now retroactive stat at last!
Now, whenever you level up, the game checks how much HP you have, then it checks how much HP you must have according to formula 25 + MaxHPperLVL + (YourLvl-1) * (MaxHPperLVL + ENDmod), then it adds N hp to you, where N is the difference.
On this image you can see that my character has 157 HP, I got 80 END on 1st level, then 86 END, then 91 END, custom class has 30 HP per level. At first I got +33 HP, then +33 HP, then +36 HP. +1 for additional END mod on this level and +2 from previous levels.
Unfortunately you still need to wait for the next level for new END to apply. For example, when on 3rd level I still got 86 END, I received +33 HP and increased END to 91, but I still had the same HP, only on the next level the game calculated the real HP.
You can download this mod here:
https://mega.nz/#!CYAV0YJI!Mp8EOdhThz0c ... pExGjjxYXs
Put it into "Daggerfall\DaggerfallUnity_Data\StreamingAssets\Mods" folder.
The mod still doesn't change attributes per level and it's still random 4-6, unfortunately I can't change it due to its protection. Mod script simply can't access it.