Junior Member
Join Date: Aug 2017
Posts: 13
|
I am creating a custom feat that allows a player to choose one of two skills and add proficiency in it if they are not or double their proficiency if they are i have tried, to figure out the script myself and i can get it to work if for the proficiency if i allow them to pick from all skills, so i need to know how to limit the list and how to add the double proficiency, any help is appreciated. I have tried to copy the scripting from the Dwarven Tool Proficiency and change it to skills but it wont limit the selections, properly.
|
#1 |
Senior Member
Join Date: May 2016
Posts: 608
|
I've been playing with it, and I'm almost at 90% working - I can't seem to get the timing right on this code for it to work.
Your feat has to have Checkmark on Show Selection Options on the In-Play Tab? SelectFfrom -> Skills Restrict First List To... -> All things Second Selection From -> Skills Restrict Second List To ... -> All things Eval script will be similar to this timing should be post-levels Code:
doneif (tagis[Helper.ShowSpec] = 0) doneif (tagis[Helper.Disable] <> 0) var tagall as string if (field[usrChosen1].ischosen <> 0) then ~ grab all tags from the chosen pick tagall = field[usrChosen1].chosen.tagids[ProfSkill.?," | "] foreach pick in hero from BaseSkill where tagall if (eachpick.tagis[Helper.Proficient] = 0) then perform eachpick.assign[Helper.Proficient] else perform eachpick.assign[Helper.ProfDouble] endif nexteach endif if (field[usrChosen2].ischosen <> 0) then ~ grab all tags from the chosen pick tagall = field[usrChosen2].chosen.tagids[ProfSkill.?," | "] foreach pick in hero from BaseSkill where tagall if (eachpick.tagis[Helper.Proficient] = 0) then perform eachpick.assign[Helper.Proficient] else perform eachpick.assign[Helper.ProfDouble] endif nexteach endif |
#2 |
Senior Member
Join Date: Jul 2014
Posts: 412
|
Quote:
Code: doneif (tagis[Helper.ShowSpec] = 0) doneif (tagis[Helper.Disable] <> 0) var tagall as string if (field[usrChosen1].ischosen <> 0) then ~ grab all tags from the chosen pick tagall = field[usrChosen1].chosen.tagids[ProfSkill.?," | "] foreach pick in hero from BaseSkill where tagall if (eachpick.tagis[Helper.Proficient] = 0) then perform eachpick.assign[Helper.Proficient] elseif (eachpick.tagis[Helper.Proficient] <> 0) then perform eachpick.assign[Helper.ProfDouble] endif nexteach endif if (field[usrChosen2].ischosen <> 0) then ~ grab all tags from the chosen pick tagall = field[usrChosen2].chosen.tagids[ProfSkill.?," | "] foreach pick in hero from BaseSkill where tagall if (eachpick.tagis[Helper.Proficient] = 0) then perform eachpick.assign[Helper.Proficient] elseif (eachpick.tagis[Helper.Proficient] <> 0) then perform eachpick.assign[Helper.ProfDouble] endif nexteach endif Forum link for my content work: Pathfinder Thread Forum link for SU 5e content work: 5e Steven Universe Thread This link is for my group, but feel free to play it with: DMM 5e | "https://www.dropbox.com/s/vsd9w1eodlnwjq0/updatesDMM.xml?dl=1" Copy this link to your update manager to get updates when available. This adds the Pisky subrace to elves from Berserk! and additional subraces for the Gem Race. Please post comments in the provided threads above. |
|
#3 |
Senior Member
Join Date: May 2016
Posts: 608
|
No, that doesn't work. The problem is really timing and I found a "fix".
In Post-Levels/15000 Component BaseSkill: Assign Helper.Proficient based on ProfSkill tags on Hero runs and that Component call assigns all the pending Helper.Proficient tags (chosen in other areas). then at Post-Levels/20000 Calc skProfBon runs which checks for all the Helper.Proficient skills and updates the field values to be displayed correctly. So I find that the script for this feat has to shoehorn in at Post-Levels/15001 up to Post-Levels/19999 before Calc skProfBon runs in order for it to check if someone already has a proficiency selected elsewhere. The other problem I'm seeing is what do you *davystyles* want to do if the skill already has double proficiency? Just ignore or are you planning on granting advantage? |
#4 |
Senior Member
Join Date: Jan 2016
Location: Adelaide, Australia
Posts: 2,294
|
Hey DungeonGuru... I think it's time we crown you the 5e HL Code Expert Really appreciate having someone around here who's focused on 5e and understands the complexities of Hero Lab Thanks mate.
Realm Works - Community Links Realm Work and Hero Lab Videos Ream Works Facebook User Group CC3+ Facebook User Group D&D 5e Community Pack - Contributor General Hero Lab Support & Community Resources D&D 5e Community Pack - Install Instructions / D&D 5e Community Pack - Log Fault / D&D 5e Community Pack - Editor Knowledge Base Obsidian Obsidian TTRPG Tutorials |
#5 |
Junior Member
Join Date: Aug 2017
Posts: 13
|
probably just gonna ignore it if i want to grant advantage i can put that in the general description, sorry for not getting back to you guys quicker been prepping for Hurricane Irma, the code works great i want to limit the selection of the skill to two skills and they choose one, they are also choosing and attribute to add 1 to, i have the code for the attribute and have the selction box for theat i cant get the selection box for the skills to limit the selection
Last edited by davystyles; September 7th, 2017 at 08:48 PM. |
#6 |
Senior Member
Join Date: May 2016
Posts: 608
|
Quote:
Quote:
For skills it will look something like (component.BaseSkill & (thingid.skAnimHand | thingid.skArcana)) That expression limits the dropdown to things in the base skill set and have an ID on them that are Animal Handling or Arcana. The parentheses are important here. The second set of parentheses around the skill define the list in the dropdown more than anything. You could also make an Array based menu, but then you have to know how to manipulate things by using the index number of the array, which a bit more tricky but you control things like sort order since you entered the array. |
||
#7 |
|
|