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

Dice are not being rolled with token actions.

Trying to make a token action for a sample attack. For some reason it refuses to roll the 1d6 for damage and add the dex mod to it. I don't understand why as above with the attack roll it rolls dice and adds just fine. <a href="https://i.imgur.com/SGEQoqj.png" rel="nofollow">https://i.imgur.com/SGEQoqj.png</a>
1587101441

Edited 1587101519
Kraynic
Pro
Sheet Author
I don't know what sheet you are using since you didn't specify (different sheets have different attribute labels), but I expect that @{DEX MOD} isn't a valid attribute.&nbsp; There should never be any spaces in an attribute, though it might contain underscores.&nbsp; It is also much easier for people to check on code if you post it here (copy/paste) rather than an image which requires retyping everything to test.
The game does not use a premade character sheet and all the attributes are correct (since I defined them myself and their values are correctly being represented). This is the code you can see in the image: &amp;{template:default} {{name=Sample Attack for @{selected|Name}}} {{Range=[[20]] / [[60]]}} {{Attack= [[?{Attack Type|Standard, 1d20|Advantage, 2d20kh1|Disadvantage, 2d20kl1}+@{Dex Mod}+@{Prof}]] }} {{Damage= [[1d6+@{Dex Mod}]]}} I don't understand why it is breaking with the damage, especially when everything is working perfectly in the Attack roll. ( @{Dex Mod} becoming -5 and correctly being added to the roll.) I've also tested just manually putting in the value and that seems to fix it, but that's not the solution I want. It's acting as if attributes can only be referenced once per token action, even though I have other token actions that do reference the same attribute more than once and work fine. <a href="https://i.imgur.com/WiEFEA3.png" rel="nofollow">https://i.imgur.com/WiEFEA3.png</a>
1587155608
Kraynic
Pro
Sheet Author
Yeah, you can use the same attribute call more than once in a macro for sure.&nbsp; You might try replacing the space with an underscore, so that Dex Mod becomes Dex_Mod.&nbsp; I know that when writing character sheets, you can't have spaces in attribute names.&nbsp; Whether that is just an html limitation, or if it can cause issues with macro behavior, I don't know.&nbsp; Another thing you could try would be to put another set of square brackets in there to make the attribute call resolve to the number before doing the calculation: [[1d6+[[@{Dex Mod}]]]]. Personally, I would remove the space or replace it with an underscore first.&nbsp; Extra spaces can really make for strange macro behavior sometimes.
I've tried both of those things and neither of them work. I'm going to go with the last one because it does make the dice roll, it just doesn't add the values together. It's an acceptable bug for me because it's just simple addition. Changing the attributes to underscores didn't change anything. Thanks for trying to help.