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

Chaos Bolt trouble

1634266121

Edited 1634266180
Using Roll20 5e character sheets Chaos bolt is supposed to roll 2d8+1d6 for damage the damage type is determined by the d8 rolls, I can choose which dmg type from the 2 d8's rolled. When I try using the rollable table and macro set out from a previous post, my damage types are random and are not based on the dice rolled. I have built a rollable table called Chaos-Bolt I have not used the weights, I have weighted everything as 1, I have set the weights based on the dice roll, I have had the number in the desc instead, haven't got it to work right. and used the macro listed in post 6 here from David &amp;{template:default} {{name=Chaos Bolt (Select damage type)}} }{{Damage=[[2d8]]+ [[?{Spell level?|1}d6]]}} {{Damage Type 1 = [[1t[Chaos-Bolt]]]}} {{Damage Type 2 = [[1t[Chaos-Bolt]]]}} But the info displayed in the chat gives random damage type Previous thread referenced. <a href="https://app.roll20.net/forum/post/9671559/chaos-bolt-macro" rel="nofollow">https://app.roll20.net/forum/post/9671559/chaos-bolt-macro</a> I don't have access to API, just rollable tables and macros
1634269473

Edited 1634290125
Oosh
Sheet Author
API Scripter
So all the [[1t[Chaos-Bolt]]] does is roll once on the Chaos-Bolt table - there is nothing linking your two table rolls to the [[2d8]] part of the damage. So the two damage types getting printed at the end have nothing at all to do with the damage roll, you're effectively rolling 4d8, using 2 for the damage and the other two for the damage type. There is a round-about way to do this with rollable tables, though you won't be able to get the damage all totaled up (at least, not while using a roll template - you can do it with an /r roll though). First, you need to make 8 rollable tables, each with a single entry, and with the significant number at the start of the name. So the table 1chaosbolt contains a single entry, 'Acid', the table 2chaosbolt contains a single entry, 'Cold', and so on up to 8. You then reconstruct your macro thusly: &amp;{template:default} {{name=Chaos Bolt (Select damage type)}} [[1t[[[1d8]]chaosbolt] ]] [[1t[[[1d8]]chaosbolt] ]] {{Damage=$[[0]] + $[[2]] + [[?{Spell level?|1}d6]]}} {{Damage Type 1 = $[[1]]}} {{Damage Type 2 = $[[4]]}} You might need to juggle the indices - I've no idea why damage type 2 is $[[4]] .... it should really be $[[3]]. Must be some kind of chaos going on in the roll request queue when a roll table gets involved. So the Xd6 roll is somehow pushing its way in between the second [[1d8]] and the roll table it's nested in. Rude!
1634284223

Edited 1634285018
Ziechael
Forum Champion
Sheet Author
API Scripter
It might be resolving to $[[4]] because of the missing ] on the second chaosbolt table call which presumably causes that inline roll to fail and not be indexed: &amp;{template:default} {{name=Chaos Bolt (Select damage type)}} [[1t[[[1d8]]chaosbolt] ]] [[1t[[[1d8]]chaosbolt] ]] {{Damage=$[[0]] + $[[2]] + [[?{Spell level?|1}d6]]}} {{Damage Type 1 = $[[1]]}} {{Damage Type 2 = $[[3]]}} should do it :/ but doesn't... should have known better than to question the mighty Oosh! So in short, stick with Oosh but for my ocd sanity, here it is again but with the closing brackets ;) &amp;{template:default} {{name=Chaos Bolt (Select damage type)}} [[1t[[[1d8]]chaosbolt] ]] [[1t[[[1d8]]chaosbolt] ]] {{Damage=$[[0]] + $[[2]] + [[?{Spell level?|1}d6]]}} {{Damage Type 1 = $[[1]]}} {{Damage Type 2 = $[[4]]}}
1634290180

Edited 1634290233
Oosh
Sheet Author
API Scripter
Good grief, you're right! I swear I copied that back to the game to check it before I posted.... updated the post anyway, to avoid confusion.