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

Need Help with a Macro using multiple rollable tables

Hey all, I have been beating at this for waaaay to long, so its time to ask for help.  I have multiple rollable tables for critical hits and failures that are dependant on the type of weapon.  Here is what I would like to do. Have a pop up where you select the type of weapon (spell, slashing, bludgeoning for now) The selection would then roll the corresponding rollable table.   I have been able to do something like this, but all I get is just "0" in the output instead of the actual text.  Here is what I have [[ ?{Attack Type|Spell, [[ 1t[Critical-Hit-Spell] ]]|Slashing, [[ 1t[Critical-Hit-Slashing] ]]|Bludgeoning, [[ 1t[Critical-Hit-Bludgeoning] ]]} ]] When I test the macro, I can get the pop-up.  But the output is 0 instead of the results from the table. Any help would be greatly appreciated! Thanks!
1570176232

Edited 1570176316
Ziechael
Forum Champion
Sheet Author
API Scripter
What are the contents of the tables, all text? Could we get a shot of those bad boys as well as the tooltip you get when hovering over the 0 output? Actually, on reflection it could be the double [[ ]] you have, it will be taking the text output of the table and attempting to make that inline but since it is NaN it will be defaulting to 0 most likely, try removing the outer [[]] on your macro and see if that helps. Technically you could get rid of all the [[]] BAR the outside ones since the query is contained within and will summarise like it should... no mechanical benefit other than less repetition needed on your part :)
Thanks Ziechael, that did it.  I removed the bars and its working as it should.
1570209976
Ziechael
Forum Champion
Sheet Author
API Scripter