[generic] VTT dice rolling help?

MartinP

Rune Priest
#1
I'm looking for suggestions.

I want to do complicated things automatically with dice rolls in a VTT, like post-roll analysis of the dice to see if they match, or add them up in different ways. Does anyone know of a web-based VTT that offers this capability? I know Roll20 doesn't, you don't have any visibility of the dice result in the program, it only appears to the user. So if the particular dice manipulation you want isn't coded into the dice engine, you are out of luck. I've looked at Astral Tabletop and Fantasy Grounds and Let's Roll as well, without any indication that such a thing is possible. I am willing to spend a modicum of money to get this capability, investigating it was one of the main reasons I went Pro with Roll20.

What do I actually want to do?

The most straightforward thing is Mongoose Traveller 2nd Ed roll, where you can roll with a Boon (3d6 take highest 2) or Bane (3d6 take lowest 2) or just normal (2d6). The "official" character sheet puts this all in one roll, by rolling 2d6, and then an extra d6 for the Boon/Bane die. You have to do the working out yourself, and you have to use the mouse-over tip to find out the values of the 2d6 before manually working out if you should swap the Boon/Bane die for one of them. My players weren't impressed, and I wanted to know why it couldn't just offer the three possible combinations of the dice up front. But Roll20 doesn't let you do that.

The other thing is Simon's Manifold (or any of his Code games as well). The mechanic is roll d6*d6, and on a double something special happens. Again, you can't get Roll20 to tell you automatically, because it's doing each die as a separate roll. You can manage to get it to colour double 1 and double 6 if you try hard enough, but that's all. So the players have to mouse-over every roll to see if they got a double.

Anyone know of a web-based VTT that will let the (GM-written) macros access the dice roll results?

For stand-alone applications I'm pretty sure The Foundry VTT will do it for me (only $60 for a licence), but if I'm going that route I'm already slightly familiar with MapTool, which will also do everything I want for free.
 
#2
I'm pretty certain a Roll20 macro would work for the Traveller version. Create an input for Boon and an input for Bane dice and program the macro to roll the number needed (i.e. 1 or 0)

Similarly, a lot of the R20 dice rolling widgets I have seen (say, for BitD) have LOADS if conditionality on them, highlighting the dice and whether it is a success or not. It would be possible, I think, to see the dice and have the roller flag a double, or make it visually obvious.

I'm not an expert at all in these things but I've seen Roll20 do far more complicated things so I assume it can do relatively simple ones.
 

MartinP

Rune Priest
#3
I'm pretty certain a Roll20 macro would work for the Traveller version. Create an input for Boon and an input for Bane dice and program the macro to roll the number needed (i.e. 1 or 0)
You can get Roll20 to do a Boon or a Bane roll (3d6h2/3d6l2 or something like that) if you choose in advance. That either has to be 2 more buttons for each skill on the sheet or another choice to make between pressing the button and getting the dice roll. There is already an annoying popup window that appears asking if there is any additional modifier, so probably the easiest thing would be a Normal/Boon/Bane radio button on there. You can't do what the current macro seems to want, which is roll the dice and calculate the 3 different outcomes.

Similarly, a lot of the R20 dice rolling widgets I have seen (say, for BitD) have LOADS if conditionality on them, highlighting the dice and whether it is a success or not. It would be possible, I think, to see the dice and have the roller flag a double, or make it visually obvious.
Roll20 has a lot of common operations built in to the dice roller. If you are making a single roll, you can do all sorts of cool things with the dice, including indicating matching dice. 2d6m (or whatever the actual code is for 'show matching') would highlight doubles in a roll of 2d6. But as far as I can find, Roll20 only supports adding not multiplying, so d6*d6 is 2 rolls that have been combined using maths and I can't see an option to do comparisons between them.

I can use critical highlighting to show me double 1 or double 6, because Roll20 will highlight the output based on the critical status of all the rolls in it, so red for all critical fail (double 1), green for all critical success (double 6) and blue otherwise. The blue otherwise is because to make it match double 1 and double 6 but not any 1 and any 6, you have to set the critical success threshold at 2+ and the critical fail threshold at 5-. It's a bit complicated, and didn't actually seem to work properly anyway, despite the assurances of the gurus.

I'm not an expert at all in these things but I've seen Roll20 do far more complicated things so I assume it can do relatively simple ones.
That is where I came in as well. Roll20 can do some really cool things with dice, as long as it's been coded into the dice roller. If it hasn't, then you just can't. There is no access to the result of a dice roll that I can see. I was looking for something like MapTool's "number = roll(dice code)" function that returns a dice roll to the macro, but it doesn't seem to be there. I had hoped the script API would do the job, but that seems just to be a JavaScript wrapper to the ordinary macro functions.

My apologies @Vodkashok, this has become a bit of a rant. I spent about a week coding up a Roll20 character sheet for an online Manifold game, and the memories of banging my head against the wall of the dice roller have come flooding back!
 

Guvnor

The Guvnor
Staff member
#4
1: As GM you can see the dice result breakdown by anyone, and I am sure that applies to all players, just hove
2: The results are hidden by the way the macro is coded to hide them, you can write a macro that displays them, or just write the code directly.
3: The standard Traveller 2e sheet doesn't seem to have Boon/Bane support built in, maybe it foxed them too or they hated the rule? EDIT: It is in there, it's somehow borked to always roll a BANE!
4: The Boon/Bane thing is quite easy to do in roll20:

BOON
/roll 2d6kh2
is "roll 2d6 and keep highest 2"
or if you want it hidden
[[3d6kh2]]

I bet you can work out BANE..
/roll 3d6kl2
[[3d6kl2]]

Now to 'fix' the Traveller (not official) sheet for 2e one really needs to add a button that shifts the skill rolls between BANE/NORMAL/BOON in the same way that the Roll20 5e sheet does for advantage/disadvantage. I have never looked at that personellment.. but this is where to go and ask meeples.. https://app.roll20.net/forum/category/277980

OR ask the author directly: he can then send you the latest code: https://app.roll20.net/users/869232/fabian-d

OR add 2 more roll buttons to the 2e sheet, one before for BANE and one after for BOON.. that'd work since the skills are a repeating item so the code only has to be tweaked once and then everytime you add a skill it will copy it along.

I'll do this before my Traveller game, but right now I don't have the time.

There are also multiple API scripts and some of them are almost sub systems in their own right:
viz Powercards and Powercards macro helper..

EDIT You can suppress the "annoying popup window" at user or game setting level. I can't find it, looks like it's a rewrite the script/macro thing again..
 
Last edited:

MartinP

Rune Priest
#5
3: The standard Traveller 2e sheet doesn't seem to have Boon/Bane support built in, maybe it foxed them too or they hated the rule? EDIT: It is in there, it's somehow borked to always roll a BANE!
...
Now to 'fix' the Traveller (not official) sheet for 2e one really needs to add a button that shifts the skill rolls between BANE/NORMAL/BOON in the same way that the Roll20 5e sheet does for advantage/disadvantage. I have never looked at that personellment.. but this is where to go and ask meeples.. https://app.roll20.net/forum/category/277980

OR ask the author directly: he can then send you the latest code: https://app.roll20.net/users/869232/fabian-d

OR add 2 more roll buttons to the 2e sheet, one before for BANE and one after for BOON.. that'd work since the skills are a repeating item so the code only has to be tweaked once and then everytime you add a skill it will copy it along.
I guess that was your post on the Roll20 forum I replied to just now?

I had a look at how the 5e sheet works adv/dis and it's quite clever, but unfortunately relies on being able to compare two complete rolls to see which is higher or lower (uses template functions RollGreater() and RollLess(), which compare the d20 rolls and displays the appropriate one). It's a beast of coding, over a megabyte of HTML. I shudder to think how many hours went into that!

The way to do it for Traveller boon/bane looks to be to add a couple of extra buttons next to the main skill button for those occasions you want it.

There are also multiple API scripts and some of them are almost sub systems in their own right:
viz Powercards and Powercards macro helper..
Indeed! I looked at what scripts other people have done, and found out how to access the result of a roll after the fact.

The way to do it (I found it in the Cusotomizable Roll Listener, but it seems to be generic) is to set a JS callback on the event that adds text to the chat-box, then parse the contents looking for a match for the text you want ("Roll with Boon" or "Roll with Bane" for example), then do whatever processing you want and re-write the contents of the chat-box. Not the easy solution I was hoping for!

You can suppress the "annoying popup window" at user or game setting level.
Is that the 5e adv/dis query? That setting uses some very cool (and lengthy) code in the 5e sheet to pre-select the advantage roll setting and remove the roll query. It could work for boon/bane in the same way, I don't think it would be much help for the modifier dialog the Trav sheet uses.
 

Guvnor

The Guvnor
Staff member
#7
I guess that was your post on the Roll20 forum I replied to just now?


Is that the 5e adv/dis query? That setting uses some very cool (and lengthy) code in the 5e sheet to pre-select the advantage roll setting and remove the roll query. It could work for boon/bane in the same way, I don't think it would be much help for the modifier dialog the Trav sheet uses.
Yup that me on Roll20.
When I have worked out how to fork the Qin sheet and then submitted a pull request I may look at Traveller.
@First Age I would also like a tripod sheet.
The pop up is in settings, I think. Not on a computer right now.
 

First Age

D&D h@ck3r and Hopepunk
Staff member
#8
Yup that me on Roll20.
@First Age I would also like a tripod sheet.
I'd love one too! I'm sure it is doable. Your flexibly select an Attribute, a personal Trait, some equipment, possible helping dice from a mate, and an external scene trait. Then a simple dice success count.

I'd love one on let's-role but the complexities of the system have eluded me so far.
 
Top