HotFusion's Retroactive Health Mod

Post » Sat Sep 04, 2010 12:08 am

Hey guys,

I am currently setting up morrowind with some basic mods to play through the game again. I want to have retroactive health, but I seem to be running into some problems...

I want to use the Morrowind Code Patch + HotFusion's Retroactive Health Mod, but I don't think the two play well together. Especially when it comes to:

Fortify Health.

Now, in the original, unmodded Morrowind, Fortify Health is basically USELESS, right? Or was I missing something? I want it to have a purpose besides murdering you, so I decided to use the fix added by the Morrowind Code Patch.

The script in the Retroactive Health Mod though doesn't play well with fortify health effects, and it causes my HP to be PERMANENTLY lowered by the amount listed in the fortify health spell after the duration ends. I svck at writing scripts, so I don't really want to try modding his script files to make them more efficient.

Does anyone have any suggestions? I just simply want my health to be retroactive :(.

Would it be possible for me to just simply use the console to modify my health each time I level up using the formula for health with the console command player-> sethealth blah blah blah??? Would this be permanent or would my health constantly reset it self each time I casted a spell or was diseased or drained or whatever?

Please help!
User avatar
Liii BLATES
 
Posts: 3423
Joined: Tue Aug 22, 2006 10:41 am

Post » Sat Sep 04, 2010 4:10 am

Well... I decided to take a list at HotFusion's script, and this is what I found:

Begin HF_StateBasedHP

float CurrentHP
float MaxHP
float damage
float test
short Endur
short level
short FirstLevelHPBonus
short Str
short DoOnce


If ( DoOnce == 0 )
set CurrentHP to Player -> GetHealth
set DoOnce to 1
set MaxHP to ( CurrentHP / PLayer -> GetHealthGetRatio )
Endif

If ( Player -> GetHealthGetRatio == 0 )
return
Endif

set CurrentHP to Player -> GetHealth
set test to ( CurrentHP / PLayer -> GetHealthGetRatio )
If ( test != MaxHP )
set HF_ExtraHP to ( test - MaxHP )
set MaxHP to test
set damage to ( Player -> getHealth )
set damage to ( damage - MaxHP )
Player -> SetHealth, MaxHP
PLayer -> ModCurrentHealth, damage
Endif


If ( endur == Player -> GetEndurance )
If ( Str == Player -> GetStrength )
return
Endif
Endif

set Endur to ( PLayer -> GetEndurance )
set Str to ( Player -> GetStrength )
set CurrentHP to Player -> GetHealth
set MaxHP to ( CurrentHP / PLayer -> GetHealthGetRatio )
set damage to ( Player -> getHealth )
set damage to ( damage - MaxHP )
set level to ( Player -> GetLevel )
set MaxHP to ( Endur / 10 )
set MaxHP to ( MaxHP * ( level - 1 ) )
set FirstLevelHPBonus to ( Endur + Str )
set FirstLevelHPBonus to ( FirstLevelHPBonus / 2 )
set MaxHP to ( MaxHP + FirstLevelHPBonus + HF_ExtraHP )
set test to MaxHP
Player -> SetHealth, MaxHP
PLayer -> ModCurrentHealth, damage

End


Now, I've never written a script before, but just from my experience with playing games a little bit of modding I did with some other games in the past, this seems pretty simple mathematically. I wonder if anyone could help me rewrite this script and make it more efficient? It seems kind of inefficient...

My ideal would be to remove all glitches and make it play nicely with Fortify Health, specifically, the Fortify MAXIMUM health modification introduced by the Morrowind Code Patch.

On a side note, do you think they would ever implement this as an option into the Morrowind Code Patch?
User avatar
Heather Kush
 
Posts: 3456
Joined: Tue Jun 05, 2007 10:05 pm

Post » Sat Sep 04, 2010 5:32 am

I'm sorry to doing something considered taboo, but I really need some help with this problem.
User avatar
lauren cleaves
 
Posts: 3307
Joined: Tue Aug 15, 2006 8:35 am

Post » Sat Sep 04, 2010 3:45 am

Don't worry, it's not taboo or anything. 90% of the modders here learned by messing with other modders' work. :wink_smile:

I've never heard of this particular mod, myself. I've seen HotFusion's State Based Hit Points, which seems to do a similar thing to what you're describing, but not this one. You may want to check that out and see if it sounds good to you: http://planetelderscrolls.gamespy.com/View.php?view=Mods.Detail&id=2840.

Yes, using SetHealth is permanent. Unless another mod alters your maximum health regularly, setting your health stays.
User avatar
benjamin corsini
 
Posts: 3411
Joined: Tue Jul 31, 2007 11:32 pm

Post » Sat Sep 04, 2010 6:40 am

Don't worry, it's not taboo or anything. 90% of the modders here learned by messing with other modders' work. :wink_smile:

I've never heard of this particular mod, myself. I've seen HotFusion's State Based Hit Points, which seems to do a similar thing to what you're describing, but not this one. You may want to check that out and see if it sounds good to you: http://planetelderscrolls.gamespy.com/View.php?view=Mods.Detail&id=2840.

Yes, using SetHealth is permanent. Unless another mod alters your maximum health regularly, setting your health stays.


Sorry! I'm so silly, I called it Retroactive Health Mod, but it is the same mod you linked to, the State-Based HP Mod. Sorry, I should have named it correctly. This is the exact script copied and pasted from his mod file.
User avatar
Emmi Coolahan
 
Posts: 3335
Joined: Wed Jan 24, 2007 9:14 pm


Return to III - Morrowind