Lone Wolf Development Forums

Lone Wolf Development Forums (http://forums.wolflair.com/index.php)
-   HL - D&D 5th Edition SRD (http://forums.wolflair.com/forumdisplay.php?f=89)
-   -   Scripting Help Request (http://forums.wolflair.com/showthread.php?t=61274)

Mergon September 22nd, 2018 07:19 AM

Scripting Help Request
 
I've finally gotten around to working on Demonic Boons for MToF.

Each boon grants the following ability:

Ability Score Adjustment: Up to a +4 bonus to Strength, Wisdom, or both.

I've decided to try adding 2 separate Ability Score Adjustments which feed from a common field[abValue].value on the Epic Boon itself. However, I have never used findchild before.

The script I am trying to use is as follows:

Quote:

~ If we're disabled, do nothing &
doneif (tagis[Helper.Disable] = 1)

var sExpr as string
sExpr = "thingid.bn5CMToFDB" & field[abText].text

var iStatMax as number
iStatMax = hero.findchild[BaseBoon, sExpr].field[abValue].value

if (iStatMax > 0) then
hero.child[aSTR].field[aStartMod].value += field[actUser].value
hero.findchild[BaseBoon, sExpr].field[abValue].value -= field[actUser].value
endif
Everything seems to compile fine until I get 'Invalid tag expression specified for 'findchild''

Anyone have an idea where I am going wrong? ShadowChemosh? :)

dungeonguru September 22nd, 2018 11:12 AM

I've not used findchild much either but I'm wondering about the tag expression you're passing in.

The line:
sExpr = "thingid.bn5CMToFDB" & field[abText].text

you add to the tag expression.

When you grab abText what would it contain?

The end result is that sExpr should be something like:

"thingid.bn5CMToFDB & component.BaseBoon" right?

Are you missing putting in the " & " or a " | " in the text?

for example:

sExpr = "thingid.bn5CMToFDB & " & field[abText].text

Mergon September 22nd, 2018 11:16 AM

I have the ability Bootstrapped to the Epic Boon. In the bootstrap, I add a field abText. This field contains the name of the Demon to whom the Epic Boon is associated (ie: Baphomet)

Thus I create, I hope, the tag of the Boon (ie: thingid.bn5CMToFDBBaphomet). I love the longer tag names . . . :)

I was hoping that this way, I don't have to create a pair of abilities for each Boon.

dungeonguru September 22nd, 2018 11:56 AM

Ah, well we will have to wait for ShadowChemosh to chime in then.

I had started working on these myself but went down a different road by trying to create generic Abilities that could show up in a Configurable tab called by an Adjustment.

The generic Abilities can handle you making a new abilFunc tag for Demonic Boons. The problem I ran into was that some of the boons boost to +4 and have no negatives while at least one goes to +8 and negatively impacts 3 other scores. The logic checks to keep someone from dropping below 1 on a score adjustment were proving too hard to get the timing right though.

Mergon September 22nd, 2018 11:59 AM

This is my 3rd assault on the issue. :)

ShadowChemosh September 22nd, 2018 12:44 PM

Quote:

Originally Posted by dungeonguru (Post 270760)
Ah, well we will have to wait for ShadowChemosh to chime in then.

I found the PDF after some google searches.

If I pull the latest files from GitHub can I see any of the work in progress on this? Or is this only on your computer Mergon?

How does a person gain access to these Boons? A feat, template, race or something else?

Mergon September 22nd, 2018 12:47 PM

I lost my hard drive a short while ago. I lost my previous attempts at creating these boons. I had the rest of my MToF materials already uploaded to GIT. But that material has nothing to do with the Epic Boons.

Sorry . . . :(

ShadowChemosh September 22nd, 2018 01:15 PM

Quote:

Originally Posted by Mergon (Post 270763)
I lost my hard drive a short while ago. I lost my previous attempts at creating these boons. I had the rest of my MToF materials already uploaded to GIT. But that material has nothing to do with the Epic Boons.

Sorry . . . :(

Ok... Sort of helps...

I am thinking I need to use a Configurable to allow the different choices. I assume a character gets one choice of demon/boon correct? Once I have the configurable working I guess you can bootstrap it to whatever you guys want to give the options to the players.

Mergon September 22nd, 2018 01:17 PM

Nothing in the rules say you CAN"T have 2 Demonic Boons, but I can't see 2 demon lords granting a single individual their boon.

ShadowChemosh September 22nd, 2018 02:24 PM

2 Attachment(s)
Attached to this is a proof of concept for demonic boons. Once you load it and restart HL go to the adjust tab and add the adjustment "Show Demonic Boons Tab".

Then on the Demonic Boons tab you can add Baphomet demon lord. The Demonic Boons tab will then display three things:
Attachment 6054

You get the demon lord and two other helper Picks with dropdowns allowing for selecting a value from 0 to +4. The demon lord pick does validation to make sure the gamer has not selected a total bonus over +4.

Now lets say you want to add the next demon lord "DEMOGORGON". You would make a copy of the "Baphomet" demon lord Thing. To set the ability scores for Demongorgon you need to change a tag on the bootstrapped ability helper Things:

Baphomet has:
Code:

    <bootstrap thing="ab5CDemBoonAbiSco">
      <autotag group="CMDOpt" tag="aSTR"/>
      </bootstrap>
    <bootstrap thing="ab5CDemBoonAbiSco">
      <autotag group="CMDOpt" tag="aWIS"/>
      </bootstrap>

You just need to change the CMDOpt tag to be the new ability score of Charisma instead of Wisdom:
Code:

    <bootstrap thing="ab5CDemBoonAbiSco">
      <autotag group="CMDOpt" tag="aSTR"/>
      </bootstrap>
    <bootstrap thing="ab5CDemBoonAbiSco">
      <autotag group="CMDOpt" tag="aCHA"/>
      </bootstrap>

The thing ab5CDemBoonAbiSco takes care of adjusting the ability scores and then a validation check on the Demon Lord makes sure we don't spend over the +4 bonus. This is done by storing the total value from the Demonic Boons Ability Score picks into the abValue5 field on the demon lord pick.

NOTE: I had to add new features into community pack helper file so you will need to pull the latest github files to get this to compile.


All times are GMT -8. The time now is 06:27 AM.

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