Junior Member
Join Date: Apr 2017
Posts: 6
|
I'm working on making an activated class ability that applies concealment while active. I've managed to get it applied to the class, it appears correctly in the activated abilities, tracked resources, and everywhere it should appear, but I can't figure out how to get it to apply concealment when I turn it on. I've done everything so far using the basic checkboxes and other fields in the editor, but selecting concealment in the 'special abilities' tab of the 'abilities granted' section doesn't seem to do anything and I don't know how to code the abilities yet, so I could really use some help at this point.
|
#1 |
Senior Member
Join Date: Aug 2010
Posts: 1,528
|
What is it you are expecting to see?
As I understand concealment, it imposes a 20% miss chance on attacks. That's not something HeroLab can "apply" to anything, other than providing a text note that the modifier exists. It is then up the GM and players to act on it during play. |
#2 |
Junior Member
Join Date: Apr 2017
Posts: 6
|
I'm looking for the ability to turn the concealment condition on while it's active. Obviously I could just go over to the conditions tab and turn it on manually, but I'd rather the ability apply it automatically.
|
#3 |
Junior Member
Join Date: Apr 2017
Posts: 6
|
It doesn't make much functional difference with concealment, but I feel like it'll be useful to know how to have an ability apply other conditions in the future.
|
#4 |
Senior Member
Volunteer Data File Contributor
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729
|
You just need to apply a tag to the Hero in a script. Pre-Level/10000 should be fine for this condition.
Code:
~ Turn on Flanking Condition perform hero.assign[Condition.pstFlankin] From inside of Hero Lab go to the menu "Develop->Enable Data File Debugging". If you are doing any editor work you want this option on. Then RIGHT click on the "?" field of Concealment and select "Show Tags".... Hero Lab Resources: Pathfinder - d20pfsrd and Pathfinder Pack Setup 3.5 D&D (d20) - Community Server Setup 5E D&D - Community Server Setup Hero Lab Help - Hero Lab FAQ, Editor Tutorials and Videos, Editor & Scripting Resources. Created by the community for the community - Realm Works kickstarter backer (Alpha Wolf) and Beta tester.- d20 HL package volunteer editor. |
#5 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,213
|
The script on Concealment is at Final/20000, so I don't think this needs to run as early as ShadowChemosh says - this is a class special, so it should be fine to use the usual Post-Level/10000 timing for this script.
|
#6 |
Junior Member
Join Date: Apr 2017
Posts: 6
|
Hey shadow, thanks for the help.
I put this in with the id for concealment and the ability turns on concealment passively, how can I make it so that concealment only applies when I turn on the ability in the 'activated abilities' tab? |
#7 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,213
|
Why don't you post your script (with the phase & priority you're using for it), and we can help you figure out what the script is or is not doing.
|
#8 |
Junior Member
Join Date: Apr 2017
Posts: 6
|
I'm using exactly what ShadowChemosh posted, with Flanking replaced with Concealment.
Code:
~ Turn on Concealment Condition perform hero.assign[Condition.pstConceal] |
#9 |
Senior Member
Volunteer Data File Contributor
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729
|
You need "Stop" script logic to prevent the script from running or it will execute always.
If this is on a Class Ability like Mathias said. I admit I missed that. Then you need to add standard Class Ability stop scripts to make sure the ability only runs when the class is the correct level. Code:
~ If we're not shown, just get out now doneif (tagis[Helper.ShowSpec] <> 1) ~ if we've been disabled, get out now doneif (tagis[Helper.SpcDisable] <> 0) But now you have the ability turning on/off from the In-Play tab. So you need additional stop script logic to support that. Code:
~ If not activated get out now! doneif (field[abilActive].value = 0) Code:
~ If we're not shown, just get out now doneif (tagis[Helper.ShowSpec] <> 1) ~ if we've been disabled, get out now doneif (tagis[Helper.SpcDisable] <> 0) ~ If not activated get out now! doneif (field[abilActive].value = 0) ~ Turn on Concealment Condition perform hero.assign[Condition.pstConceal] Hero Lab Resources: Pathfinder - d20pfsrd and Pathfinder Pack Setup 3.5 D&D (d20) - Community Server Setup 5E D&D - Community Server Setup Hero Lab Help - Hero Lab FAQ, Editor Tutorials and Videos, Editor & Scripting Resources. Created by the community for the community - Realm Works kickstarter backer (Alpha Wolf) and Beta tester.- d20 HL package volunteer editor. |
#10 |
|
|