Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Hero Lab Forums > HL - d20 System

Notices

Reply
 
Thread Tools Display Modes
bodrin
Senior Member
 
Join Date: Feb 2007
Location: Nottinghamshire, United Kingdom
Posts: 1,265

Old July 2nd, 2011, 10:08 PM
The title says it all, I'm attempting to add hit points to a hero using a script the calculation is

Add hit points equal to Hit Dice multiplied by the attribute modifier.

I can't find the correct identifier for Hit Dice, I've tried rHitDice, tHitDice and numerous other combinations but I keep getting non existent thing errors.
Please help someone I'm losing the rest of my hair!
bodrin is offline   #1 Reply With Quote
Kendall-DM
Spy
 
Join Date: Jan 2011
Location: Van Nuys, California
Posts: 1,220

Old July 2nd, 2011, 11:48 PM
What you might do is do a tagcount of Hero.HitDice. This will give you the number of hit dice the character has.
Kendall-DM is offline   #2 Reply With Quote
bodrin
Senior Member
 
Join Date: Feb 2007
Location: Nottinghamshire, United Kingdom
Posts: 1,265

Old July 2nd, 2011, 11:58 PM
I've managed to get the script working.

Code:
~ Add our Charisma modifier times our Hit Dice to our Hit Point total.

container.child[Totals].field[tHP].value = container.child[Totals].field[tHitDice].value * hero.child[aCHA].field[aModBonus].value + container.child[Totals].field[tHP].value
I'm quite pleased with this as I'm currently at work without Internet access only on an iPhone and can't do major searches of the code base.
bodrin is offline   #3 Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 02:59 PM.


Powered by vBulletin® - Copyright ©2000 - 2024, vBulletin Solutions, Inc.
wolflair.com copyright ©1998-2016 Lone Wolf Development, Inc. View our Privacy Policy here.