Help! HP formula gain plus stat boost per level using yanfly base formula plugin

hi, im using yanfly base parameter formula plugin and im trying to gain HP based on + level and for each level you also gain half your DEF/2, but every formula i try it doesnt increment the HP based on DEF/2. i can only add HP based on level so per level you get +1 HP, but thats not what i want. 


here's the basic formula im trying out but its not working.


base stats:


HP = 10


Def = 10


(base + plus + (user.level += (user.level + user.def/2))) * paramRate * buffRate + flat


so with that formula i only get +2 HP per level, instead of +6 ( + level and + def/2 with 10 as base stat, it comes to +5)


please help i spent 2 days trying to figure out this formula but i dont know how to increment the HP parameter based def/2.
i figured it out. here's the formula if anyone wishes to use this HP rate.


(base + plus) + user.def/2 + (user.level *= user.def/2) + user.level * paramRate * buffRate + flat


basically, what happens is, the user gains its base HP rate defined by the class, plus half it's Def at the start of the game, plus half its def +1 per level


so in my case


base stats.


HP = 10


DEF = 10


starts with 21 HP, gains 6 HP per level, and scales based on how much Def you have increasing per level but for my game i changed Def to mean Constitution.

Original thread: https://forums.rpgmakerweb.com/threads/help-hp-formula-gain-plus-stat-boost-per-level-using-yanfly-base-formula-plugin.73222/