Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Hero Lab Forums > HL - D&D 5th Edition SRD
Register FAQ Community Today's Posts Search

Notices

Reply
 
Thread Tools Display Modes
Caedhros
Junior Member
 
Join Date: Feb 2016
Posts: 20

Old February 2nd, 2016, 04:26 PM
I am trying to implement a house rule subrace in 5e where the race sets your Dex score at 14 if it isn't there already. (We use reincarnation so dumping Dex and taking this race is not a concern). This means if you have an 8 Dex, it becomes 14 (post reincarnation) but if you have a 15 nothing happens. I cannot for the life of me figure out how to set a minimum like this and I could use a hand or direction.

Can someone help me out?

I have:

if (hero.child[aDEX].field[Bonus].value < 14) then
hero.child[aDEX].field[Bonus].value = 14
endif

This is adding 16 to all CHA scores period, and I don't see why...

Last edited by Caedhros; February 3rd, 2016 at 05:35 PM.
Caedhros is offline   #1 Reply With Quote
Tamhansen
Junior Member
 
Join Date: Feb 2016
Posts: 9

Old February 3rd, 2016, 01:32 AM
likely because you're adding 16 to the charisma bonus when the bonus is less than 16. If the character doesn't get a bonus of itself, it will add 16. If it does (Say Dragonborn) it will turn the bonus into 16.
Tamhansen is offline   #2 Reply With Quote
Aaron
Senior Member
 
Join Date: Oct 2011
Posts: 6,793

Old February 3rd, 2016, 07:24 AM
So like a minimum of 14? Couldn't you do something like:

hero.childfound[aDEX].field[aNormal].value = maximum(hero.childfound[aDEX].field[aNormal].value, 14)
Aaron is offline   #3 Reply With Quote
Caedhros
Junior Member
 
Join Date: Feb 2016
Posts: 20

Old February 3rd, 2016, 06:15 PM
Well, I tried. I apparently was not born to program! I can't get the "<" to work at all and nothing happens at all when I use the [aNormal] tag instead of [Bonus]. I'll keep playing with it and I'll let you know if I get anywhere.
Caedhros is offline   #4 Reply With Quote
Caedhros
Junior Member
 
Join Date: Feb 2016
Posts: 20

Old February 3rd, 2016, 07:08 PM
I think I got it mostly:

hero.child[aDEX].field[Minimum].value = maximum(hero.child[aDEX].field[Minimum].value,14)
hero.child[aDEX].field[aMaxValue].value = maximum(hero.child[aDEX].field[aMaxValue].value,14)

This does everything but doesn't make it part of the starting stat the way using [aStartMod] does, but I can't figure out how to use [aStatMod] in this equation, HL keeps rejecting it. oh well.

Last edited by Caedhros; February 3rd, 2016 at 07:44 PM.
Caedhros is offline   #5 Reply With Quote
Reply


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 04:02 AM.


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