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 With making Advantage selectable with Script Cards

I am trying to make a new script card that allows someone to select what type of advantage they have and for the chat to display it. Below is what I have at the moment. What I am aiming for is for someone to click it, they choose how the dice are being rolled, then when it pops, up in chat it says X character rolled with advantage, or disadvantage. Then also if they managed to get a critical hit it displays them getting a critical hit as well. So the message would be like X character got a critical hit, or something along those lines. I remember there was a way to do it, but I can't seem to find the old thread, or video that I found explaining it. Any help would be much appreciated and I hope you have a great day. !scriptcard {{     --#overridetemplate|scroll     --#title|Character's Name     --=Modifier|?{Mod|0}     --=Skill Check| ?{Skill Check|Standard,1d20|Advantage,2d20kh1|Disadvantage,2d20kl1|Double Advantage, 3d20kh1| Double Disadvantage, 3d20kl1} + [$Modifier]     --+Skill Check|[$Skill Check] }}
Hi Michael O, I am by no means the best Scriptcard writer and there may be efficiencies to be had here, but how does this work for you? !scriptcard {{ --#overridetemplate|scroll --#SourceToken|@{selected|token_ID} --#emoteState|off --=Modifier|?{Mod|0} --&SkillRoll|?{Skill Roll|Standard,1|Advantage,2|Disadvantage,3|Double Advantage,4|Double Disadvantage,5} --c[&SkillRoll]|1:&Roll;1d20|2:&Roll;2d20kh1|3:&Roll;2d20kl1|4:&Roll;3d20kh1|5:&Roll;3d20kl1 --c[&SkillRoll]|1:&Type;Standard|2:&Type;Advantage|3:&Type;Disadvantage|4:&Type;Double Advantage|5:&Type;Double Disadvantage --#title|[*S:t-name] [&Type] Roll --=SkillCheck|[&Roll] --=Result| [$SkillCheck] + [$Modifier] --?[$SkillCheck.Base] -eq 1|>Fumble --?[$SkillCheck.Base] -eq 20|>Crit --?[$SkillCheck.Base] -ne 1 -and [$SkillCheck.Base] -ne 20|>Standard --:Standard| --+|[*S:t-name] rolls a [$SkillCheck] plus Modifier of [$Modifier] for a total [$Result] -->End| --:Fumble| --+|[*S:t-name] Fumbled their Skill Check -->End| --:Crit| --+|[*S:t-name] scored a Crit! Rolling [$SkillCheck] plus Modifier of [$Modifier] for a total [$Result] -->End| --:End| --X| }}
1732298362

Edited 1732298465
and if you would like the Crit to show green, Kurt added that late last month !scriptcard {{ --#overridetemplate|scroll --#SourceToken|@{selected|token_ID} --#emoteState|off --=Modifier|?{Mod|0} --&SkillRoll|?{Skill Roll|Standard,1|Advantage,2|Disadvantage,3|Double Advantage,4|Double Disadvantage,5} --c[&SkillRoll]|1:&Roll;1d20|2:&Roll;2d20kh1|3:&Roll;2d20kl1|4:&Roll;3d20kh1|5:&Roll;3d20kl1 --c[&SkillRoll]|1:&Type;Standard|2:&Type;Advantage|3:&Type;Disadvantage|4:&Type;Double Advantage|5:&Type;Double Disadvantage --#title|[*S:t-name] [&Type] Roll --=SkillCheck|[&Roll] --=Result| [$SkillCheck] + [$Modifier] --?[$SkillCheck.Base] -eq 1|>Fumble --?[$SkillCheck.Base] -eq 20|>Crit --?[$SkillCheck.Base] -ne 1 -and [$SkillCheck.Base] -ne 20|>Standard --:Standard| --+|[*S:t-name] rolls a [$SkillCheck] plus Modifier of [$Modifier] for a total [$Result] -->End| --:Fumble| --+|[*S:t-name] Fumbled their Skill Check -->End| --:Crit| --+|[*S:t-name] scored a Crit! Rolling [$SkillCheck] plus Modifier of [$Modifier] for a total [$Result] --:SetCrit|(rollvar) --~|roll;sethilight;[%1%];crit -->End| --:End| --X| }}