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

Is there a way to write a macro so that it comes up with a roll based result? Like it rolls a d4 and on 2-4 it rolls damage and on a 1 it says fail? My 5e party is making grenades and explosive ammo using gun powder, but I don't want it to work every time due to it being a very crude system. 
1593312116
Oosh
Sheet Author
API Scripter
There is - what's the damage of the grenade? Logic statements do not exist, so you have to do something a bit messy like this: &{template:default}{{name=Grenade Attack}}[[[[ceil(([[1d4]]-1)/3)]]d6]] {{Throw=$[[0]]}} {{Damage=$[[2]]}}
Was thinking of something like 2d8 force damage with a 75% chance to actually explode. There is an Artificer in the group, so the odds are better than average of it actually going off.
1593315634

Edited 1593315954
Oosh
Sheet Author
API Scripter
Righto, probably a bit more like this then: &{template:default}{{name=Grenade Attack}}[[[[2*ceil(([[1d4cs5]]-1)/3)]]d8]] {{Mechanism Roll=$[[0]]}} {{Damage=$[[2]] force damage}} or you could display [[1d4-1]] for the mechanism roll, that way it would be an angry red 0 for failure: &{template:default}{{name=Grenade Attack}}[[[[2*ceil([[1d4cs5-1]]/3)]]d8]] {{Mechanism Roll=$[[0]]}} {{Damage=$[[2]] force damage}}