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
spannclann
Member
 
Join Date: Aug 2018
Location: Texas
Posts: 87

Old March 25th, 2024, 02:13 PM
@Fenris447
I am needing an eval script that checks for the hero's level. If the appropriate level is met then shortbow and damage die are increased to the next highest die.
(i.e. Shortbow to 1d8 and Longbow to 1d10)


I found this level check:
~ Check whether you have at least 18 levels of the Fighter class
@valid = 0
if (#levelcount[Fighter] >= 18) then
@valid = 1
endif

and I know to do this for damage die:
hero.childfound[wShortbow].field[wDieCount].value = 1
hero.childfound[wShortbow].field[wDieSize].value = 8

I assume I need a check to see if the hero has the weapon in question before it applies the larger damage die.
spannclann is offline   #1 Reply With Quote
Fenris447
Senior Member
 
Join Date: Sep 2017
Posts: 600

Old March 25th, 2024, 10:53 PM
So it's gonna get kinda complicated if you want it to work for any weapon, any damage die. Because you could add 2 to the wDieSize, but if they're already at a d12 then you'd be bumping it up to the non-standard d14.

Second thing is, are you looking at specific weapons, a pool of specific weapons, or any weapon of the player's choice? That'll determine exactly how we approach this.

And is it a feature for a specific class/subclass, or is this like a feat where the class doesn't matter?

Found an issue with or have a suggestion for the 5e Community Pack? Please post it here at our GitHub.

Feel free to stop by the Lone Wolf Development Subreddit, for discussion of any and all LWD products and community efforts!
Fenris447 is offline   #2 Reply With Quote
spannclann
Member
 
Join Date: Aug 2018
Location: Texas
Posts: 87

Old March 26th, 2024, 12:21 AM
It is a custom fighter subclass ability. I got it to work using this, but I am not sure if there is a better way.

if (field[xAllLev].value >= 18) then
foreach pick in hero from BaseWep where "IsWeapon.wShortbow"
eachpick.field[wDieCount].value = 1
nexteach
foreach pick in hero from BaseWep where "IsWeapon.wShortbow"
eachpick.field[wDieSize].value = 8
nexteach
foreach pick in hero from BaseWep where "IsWeapon.wLongbow"
eachpick.field[wDieCount].value = 1
nexteach
foreach pick in hero from BaseWep where "IsWeapon.wLongbow"
eachpick.field[wDieSize].value = 10
nexteach
foreach pick in hero from BaseWep where "IsWeapon.wRIPHankyu"
eachpick.field[wDieCount].value = 1
nexteach
foreach pick in hero from BaseWep where "IsWeapon.wRIPHankyu"
eachpick.field[wDieSize].value = 8
nexteach
foreach pick in hero from BaseWep where "IsWeapon.wRIPGreatbow"
eachpick.field[wDieCount].value = 2
nexteach
foreach pick in hero from BaseWep where "IsWeapon.wRIPGreatbow"
eachpick.field[wDieSize].value = 6
nexteach
foreach pick in hero from BaseWep where "IsWeapon.w5COvrLngbw"
eachpick.field[wDieCount].value = 2
nexteach
foreach pick in hero from BaseWep where "IsWeapon.w5COvrLngbw"
eachpick.field[wDieSize].value = 8
nexteach
foreach pick in hero from BaseWep where "IsWeapon.w5CLiReCro"
eachpick.field[wDieCount].value = 1
nexteach
foreach pick in hero from BaseWep where "IsWeapon.w5CLiReCro"
eachpick.field[wDieSize].value = 10
nexteach
foreach pick in hero from BaseWep where "IsWeapon.wCrssbwHan"
eachpick.field[wDieCount].value = 1
nexteach
foreach pick in hero from BaseWep where "IsWeapon.wCrssbwHan"
eachpick.field[wDieSize].value = 8
nexteach
foreach pick in hero from BaseWep where "IsWeapon.wCrssbwHvy"
eachpick.field[wDieCount].value = 1
nexteach
foreach pick in hero from BaseWep where "IsWeapon.wCrssbwHvy"
eachpick.field[wDieSize].value = 12
nexteach
foreach pick in hero from BaseWep where "IsWeapon.wCrossbowL"
eachpick.field[wDieCount].value = 1
nexteach
foreach pick in hero from BaseWep where "IsWeapon.wCrossbowL"
eachpick.field[wDieSize].value = 10
nexteach
endif
spannclann is offline   #3 Reply With Quote
Fenris447
Senior Member
 
Join Date: Sep 2017
Posts: 600

Old March 26th, 2024, 08:09 AM
If it's working the way you want it, then great!

My only note is that typically, 5e subclasses base everything on your class level. That [xAllLev] is basing it on your total level, regardless of multiple classes. But if that's okay with you, then no worries!

Found an issue with or have a suggestion for the 5e Community Pack? Please post it here at our GitHub.

Feel free to stop by the Lone Wolf Development Subreddit, for discussion of any and all LWD products and community efforts!
Fenris447 is offline   #4 Reply With Quote
spannclann
Member
 
Join Date: Aug 2018
Location: Texas
Posts: 87

Old March 26th, 2024, 10:04 AM
I did mean to change it to check for the Fighter level.
spannclann 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 03:53 AM.


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