Jump to content


Photo

Randomized Hit Points


  • Please log in to reply
1 reply to this topic

#1 WizWom

WizWom
  • Member
  • 271 posts

Posted 29 July 2006 - 08:28 AM

D&D specs monsters as N+X Hit dice (or, rarely, y to x); the game engine spec's them as X hit points.

I'm thinking that it would be cool to script the hit points in with an OnCreation()

Since there is no basic script thing to do it, I think that I would have to make a Spell, that would set max hit points to 1d8 and another to add 1d8 max hit points - and another to add 1 max hit point. Then a quick no-visual heal. All done OnCreation()

That way, monsters would have random hit points, if you scripted it so.

IF
OnCreation()
Global("HitPointsSet","LOCALS",0)
THEN
RESPONSE #100
ReallyForceSpell(Myself,"WW1STHD")
ReallyForceSpell(Myself,"WWHD") // repeated until total hit dice rolled
ReallyForceSpell(Myself,"WWADDHP") // repeat as needed
ReallyForceSpell(Myself,"WWHEAL") // and set current to our new max
SetGlobal("HitPointsSet","LOCALS",1)
Continue()
END

#2 WizWom

WizWom
  • Member
  • 271 posts

Posted 29 July 2006 - 10:11 AM

As it turns out, the heal isn't needed, if the spell does a "Set Max HP" effect. I set the CRE file hit points to the maximum, which seems to be the default, then put the spells into the Override script.

And so we get a little closer to P&P :-)