Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×
Create a free account

Help with recursive tables

I'm trying to make a rollable wild magic surge and wild barbarian table and each entry is a 5e OGL sheet atkdmg template.&nbsp; I figured out that the initial &amp; entry of the template has to be outside the table which was fine, but every single attribute call in the rollable tables is failing to be red by the recursive tables API.&nbsp; I feel like theres suppose to be some sort of substitute for @ symbols in the syntax but I see no documentation from recursive tables stating as such.&nbsp;&nbsp; The command I'm using is "!rt &amp;{template:atkdmg} [[1t[WildMagicBarb]]]" When I get the option below, the spell save stays at 8 instead of the proper number: {{mod=}} {{rname=WildMagic1}} {{r1=}} {{r2=}} 0 {{range=30ft radius}} {{damage=1}} {{dmg1flag=1}} {{dmg1=[[1d12]]}} {{dmg1type=Necrotic}} {{damage=1}} {{dmg2flag=1}} {{dmg2=[[1d12]]}} {{dmg2type=Temp HP}} {{crit1=}} {{crit2=}} {{save=1}} {{saveattr=Constitution}} {{savedesc=Save for no damage.}} {{savedc=[[8+@{selected|pb}+@{selected|constitution_mod}]]}} {{desc=[x](<a href="https://media.giphy.com/media/1xooNqTDq9RdurNvuo/giphy.gif" rel="nofollow">https://media.giphy.com/media/1xooNqTDq9RdurNvuo/giphy.gif</a>) Each creature of your choice takes the necrotic damage on failed save. You gain temp hp regardless.}} {{spelllevel=}} {{innate=}} {{globalattack=}} {{globaldamage=}} {{globaldamagecrit=}} {{globaldamagetype=}} ammo= {{charname=}}
1639949273
The Aaron
Roll20 Production Team
API Scripter
Hmm. Can you post the contents of the row you're expecting to be expanded?
I wound up changing my whole method of attack on this project but I think what you are asking for is in the code entry above, that is one of the table results that is giving the error, specifically when I do the above command, the saving throw is 8, if I run that template without !rt and a rollable table, the save DC is 15.&nbsp; Its specifically ignoring the attributes for PB and Constitution mods.&nbsp;&nbsp; I abandoned this method and instead made all the wild barbarian table options a simple npctraits entry in a rollable table and didn't use any attribute calls to sheets in them.&nbsp; Then on each barb its up to them to have the templates for the various wildmagic stuff.
1639961597
The Aaron
Roll20 Production Team
API Scripter
Ah. @{selected|...} wouldn't make sense at the point where it's getting expanded in the API. That's likely the issue.&nbsp;
1640010544
timmaugh
Forum Champion
API Scripter
ZeroFrame handles table recursion a little differently than Recursive Tables, so if this structure was important, you could accomplish this by installing ZeroFrame (and maybe SelectManager). The main difference is that ZeroFrame initiates a behind-the-scenes message that invokes the Roll20 parsers again (catching the @{select...} structures), until it doesn't detect a change in the command line. Then you'd use a {&amp;simple} tag to output the final message to the chat. If you want an example of that, I can provide one.
I appreciate the help guys but I wound up remaking it all differently working around it, plus I kinda realized after the fact that you don't really want the wild barb magic tables templates in the rollable table as you need to be able to recall them every turn.&nbsp; So I opted for generic messages in the table and then specific macro templates called via a macro for each one if they roll it.&nbsp;&nbsp;