Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Hero Lab Forums > HL - D&D 5th Edition SRD

Notices

Reply
 
Thread Tools Display Modes
jjashley
Senior Member
 
Join Date: Jan 2017
Posts: 139

Old February 13th, 2018, 03:43 PM
Is there a way to stack dark vision and have it reflect that in hero lab? Example would be a bugbear wearing a blue dragon mask. While wearing the mask he should have dark vision out to 120 feet.

Joe
jjashley is offline   #1 Reply With Quote
dungeonguru
Senior Member
 
Join Date: May 2016
Posts: 608

Old February 14th, 2018, 03:28 AM
Yes.

You have to bootstrap darkvision on the Blue Dragon Mask. On the field values you need to have two fields:

#1 - abValue with value 60
#2 - abValue2 with value 60

The way darkvision is calculated is that it loops through all bootstrapped Darkvision sources and sets the base range to the largest abValue. It then loops through all the abValue2 values and adds them to extend the ranges. If an thing has both, It only applies the abValue2 if there is another source of darkvision (it doesn't add both for the mask for a human for instance).

I think the dragon masks don't have any darkvision bootstraps, so these probably need to be added, you might want to open a ticket over on the community github to fix the dragon masks.

Last edited by dungeonguru; February 14th, 2018 at 03:33 AM.
dungeonguru is offline   #2 Reply With Quote
jjashley
Senior Member
 
Join Date: Jan 2017
Posts: 139

Old February 14th, 2018, 05:49 AM
Quote:
Originally Posted by dungeonguru View Post
Yes.

You have to bootstrap darkvision on the Blue Dragon Mask. On the field values you need to have two fields:

#1 - abValue with value 60
#2 - abValue2 with value 60

The way darkvision is calculated is that it loops through all bootstrapped Darkvision sources and sets the base range to the largest abValue. It then loops through all the abValue2 values and adds them to extend the ranges. If an thing has both, It only applies the abValue2 if there is another source of darkvision (it doesn't add both for the mask for a human for instance).

I think the dragon masks don't have any darkvision bootstraps, so these probably need to be added, you might want to open a ticket over on the community github to fix the dragon masks.
ok the blue dragon mask does, at least in one of my packages. I didn't think about it working that way but makes perfect sense. Thank you very much for the reply.

J
jjashley is offline   #3 Reply With Quote
jjashley
Senior Member
 
Join Date: Jan 2017
Posts: 139

Old March 16th, 2018, 06:03 AM
ok another question. if I don't have Dark Vision as a racial ability but receive it thru a class ability where it is boot strapped, then get a potion or spell cast on me that adds to the Dark Vision, it doesn't seem to be adding just abValue at this point, it seems to add both abValue and abValue2. My example is Dark Velocity ability from the Blood Hunter that is up on the Beyond site, you then get a mutagen called Nighteye that you can make permanent at level 18. Darkvelocity gives you dark vision 30, and nighteye gives you 60 or an additional 60 if you already have darkvision. the result I'm seeing in Hero Lab is 150 feet, I believe the abValue 60 taking over as the higher value, but then for some reason it is adding the abValue2 from each of those 2 things. I have bootstrapped as you indicated here, thought I do have conditions on the bootstraps, one is a level condition and the other is a condition based on user choice, both of the conditions seem to function correctly.

J
jjashley is offline   #4 Reply With Quote
dungeonguru
Senior Member
 
Join Date: May 2016
Posts: 608

Old March 16th, 2018, 10:51 AM
Yeah, never ran into that issue before but I can see what's happening.

I've tried looking deeper in a copy of Darkvision and there's a few lines that go:

Code:
        ~ If we've found a copy other than ourselves, then add the abValue2
        ~ field from that copy to our own abValue2 field.
        if (eachpick.uniqindex <> uniqindex) then
          field[abValue2].value += eachpick.field[abValue2].value
          endif
So after it runs on Dark Velocity dark velocities darkvision totals are:
abValue = 60
abValue2 = 60 + 30 = 90

When the code runs on Nighteye
abValue = 30
abValue2 = 30 + 60 = 90

Then due to timing on the darkvision scripts we calculate distance, which I missed the first time.

So highest abValue plus abValue2 is 150 rather than the 120 you expected.

I'm thinking that items that extend darkvision might need to have a line of script that runs and checks to see if the character has darkvision before assigning an abValue2 number.

The hero tag [Hero.HasDarkVis] gets assigned in First/5000, but the calculations for distance occur in Final/10000. So I think just add some code that runs maybe in pre-levels that checks for the tag and if the tag is there, add an abValue2 to the darkvision that's bootstrapped to the ability... Would take some playing around to get it right...

Maybe ShadowChemosh or a dev wants to chime in and make sure I got the logic right this time? Actually I don't think that would work necessarily either, but just trying to figure it out...

Last edited by dungeonguru; March 16th, 2018 at 11:04 AM. Reason: fixed a confused self
dungeonguru is offline   #5 Reply With Quote
jjashley
Senior Member
 
Join Date: Jan 2017
Posts: 139

Old March 17th, 2018, 04:51 AM
Quote:
Originally Posted by dungeonguru View Post
Yeah, never ran into that issue before but I can see what's happening.

I've tried looking deeper in a copy of Darkvision and there's a few lines that go:

Code:
        ~ If we've found a copy other than ourselves, then add the abValue2
        ~ field from that copy to our own abValue2 field.
        if (eachpick.uniqindex <> uniqindex) then
          field[abValue2].value += eachpick.field[abValue2].value
          endif
So after it runs on Dark Velocity dark velocities darkvision totals are:
abValue = 60
abValue2 = 60 + 30 = 90

When the code runs on Nighteye
abValue = 30
abValue2 = 30 + 60 = 90

Then due to timing on the darkvision scripts we calculate distance, which I missed the first time.

So highest abValue plus abValue2 is 150 rather than the 120 you expected.

I'm thinking that items that extend darkvision might need to have a line of script that runs and checks to see if the character has darkvision before assigning an abValue2 number.

The hero tag [Hero.HasDarkVis] gets assigned in First/5000, but the calculations for distance occur in Final/10000. So I think just add some code that runs maybe in pre-levels that checks for the tag and if the tag is there, add an abValue2 to the darkvision that's bootstrapped to the ability... Would take some playing around to get it right...

Maybe ShadowChemosh or a dev wants to chime in and make sure I got the logic right this time? Actually I don't think that would work necessarily either, but just trying to figure it out...
Is all good, when I get back home I'll do some toying around as well.
jjashley is offline   #6 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 07: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.