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

Showing dice result in a rolltemplate

1481120633

Edited 1481120703
Michael C.
Sheet Author
Hey guys, I'm having some problems with my roll template and the google search and forum search haven't really given me a clear answer though I think it's (currently?) not possible: Inside my roll button I use 3 different 1d20 and a formula to calculate differences between the thrown dice and skill values to calculate a value XY. Based on the value XY i format the roll template and decide if the ability check has failed or succeded. My question is: Is there any way to show the values of those 3 dice inside the rolltemplate itself? Right now the result of the formula is stored inside XY but the formula is rather complex and if the user hovers over the result in the chat he won't be able to understand which numbers belong to the dice. Down below I included the button in a very simplified version. bttn type="roll" value="&{template:Z} {{XY=[[ @{skill_value} - {1d20 - ((some modificators)) } - {1d20 - ((some modificators)) } - {1d20 - ((some modificators)) } ]]}} "> Is something like this possible? bttn type="roll" value="&{template:Z} {{roll1= 1d20}} {{roll2= 1d20}} {{roll3= 1d20}} {{XY=[[ @{skill_value} - {roll1 - ((some modificators)) } - {roll2 - ((some modificators)) } - {roll3- ((some modificators)) } ]]}} "> This way the dice results would be stored in different variables and I could show those variables inside the roll template AND use those same results to calculate the formula XY to show XY in the roll template as well but I'm either screwing up the syntax or this isn't possible at all. Maybe someone can help? The only solution so far I've found is the power cards api but since it's a script that needs pro subscription I can't include it in my charsheet for everyone since only many people won't be able to use it.
1481122576
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
You could do something like this using roll tags to denote which numbers are from the roll: bttn type="roll" value="&{template:Z} {{XY=[[ @{skill_value} - {1d20 [d20] - ((some modificators)) } - {1d20 [d20] - ((some modificators)) } - {1d20 [d20] - ((some modificators)) } ]]}} ">
1481127952

Edited 1481128062
Michael C.
Sheet Author
I'm not entirely sure what you mean with the roll tag. Wouldn't that just highlight the number inside the hover tooltip? Or am I missunderstanding the roll tag? I'm trying to find a way to write the roll result into the chat window via the roll template, not try to modify the tooltip.  The tooltip is already too messy for the average user to understand meaning he will only see this:   Trying to highlight the dice results inside that tooltip is not exactly the solution I'm hoping for since the user of my character sheet will not understand the formula I'm using to determine the end result and isn't even supposed to understand it.
1481129770
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
Yep, but that's the only way I know of to do it short of using an API script. Powercards may be able to do what you want (I haven't used it, but I think it has some functionality to display/use rolls multiple times), or it may require a custom companion script for your system. There's no way using the standard dice engine available from chat, and I believe that the resources available to the sheet don't allow this either.
1481146102
Tetsuo
Forum Champion
Powercards can do this. It has an expand option that will expand rolls in the output
1481158650

Edited 1481159431
Michael C.
Sheet Author
But since Powercards is an API script, doesn't this mean that everyone using the charsheet will need a pro subscription for api access and it won't work for free users? I'm searching for a way to solve this problem for all users of the charactersheet, not just the paying ones.
1481160316
vÍnce
Pro
Sheet Author
Michael C. said: But since Powercards is an API script, doesn't this mean that everyone using the charsheet will need a pro subscription for api access and it won't work for free users? I'm searching for a way to solve this problem for all users of the charactersheet, not just the paying ones. Only the GM needs Pro.  Players reap the benefits of the GM when playing in that GM's game.  ;-)
1481171629
Finderski
Pro
Sheet Author
Compendium Curator
I think what Michael means is that he's working on a sheet that he wants to make available to the public, and so doesn't want the sheet to rely on the API.  In which case, there's no way to do that.  You can certain have it show each individual roll, but you couldn't do anything special with them, interpreting the roll would need to be manual at that point.
1481192407

Edited 1481192444
Michael C.
Sheet Author
Finderski said: I think what Michael means is that he's working on a sheet that he wants to make available to the public, and so doesn't want the sheet to rely on the API.   Exactly this. As much as I love roll20 and am a pro subscriber myself I can't expect everyone who will use my public sheet to pay for it. :( Michael C. said: bttn type="roll" value="&{template:Z} {{roll1= 1d20}} {{roll2= 1d20}} {{roll3= 1d20}} {{XY=[[ @{skill_value} - {roll1 - ((some modificators)) } - {roll2 - ((some modificators)) } - {roll3- ((some modificators)) } ]]}} "> If something like that would be possible I'd be amazing as I could show the variables 'roll1' , 'roll2' , 'roll3' AND the result 'XY' where I'm using the variables roll1,2,3 to calculate the result all inside the same rolltemplate. However I get the feeling something like this isn't supported at the moment