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

Drop Down Saving Throws Macro Question

August 25 (4 years ago)

Edited August 25 (4 years ago)

Hey there world!

I thought I would throw myself at the mercy of the courts and ask for help.I've found some neat posts on this, but can't get a macro featuring a drop-down Ability selection to work, that then outputs a saving throw. I'll try and clearly outline what I hope such a macro can do.

The game is systemless and uses just the basic character sheet.

I have created Abilities as follows:
• Str, StrBns,StrFav
• Dex, DexBns, DexFav
• Con, ConBns, ConFav
etc.

Dex contains the stat, DexBns contains the modifier for a high or low stat, and DexFav contains a modifier for if the stat is favoured but is otherwise blank or 0. What I hope can be done if for the Character to run the macro, pick an ability, and for the chosen ability the macro outputs 1d20+nnnBns+nnnFav.

Any chance this is feasible?

Kind regards form Australia — Chris

August 25 (4 years ago)

Edited August 25 (4 years ago)
Oosh
Sheet Author
API Scripter

Does this do what you want?

&{template:default} {{name=Saving Throw}} {{?{Ability?|
Strength,Strength save=[[1d20+{@{selected|StrBns},@{selected|StrFav}|
Dexterity,Dexterity save=[[1d20+{@{selected|DexBns},@{selected|DexFav}}}k1]]}}


Just the two stats, but it should roll 1d20 + the higher number out of {StrBns,StrFav}.

I'm assuming Fav will be either 0, or will be higher than regular Bonus. Is that correct? Or does Fav not already include Bonus, so you need to add both? That's a bit simpler:

&{template:default} {{name=Saving Throw}} {{?{Ability?|
Strength,Strength save=[[1d20+@{selected|StrBns}[BNS]+@{selected|StrFav}[FAV]|
Dexterity,Dexterity save=[[1d20+@{selected|DexBns}[BNS]+@{selected|DexFav}[FAV]}]]}}


August 25 (4 years ago)

Edited August 25 (4 years ago)

Ahhh, Thanks for that. And no, the Fav is similar to an optional rule that allows a character to be proficient in two Ability saves. In this case it adds an extra Proficiency Dice such as d4, d6 or d8 to the roll. So two of the six stats have a nnnFav value of d6 (for example), while the other xyzFav are 0. Luckily, 1d0=0 in roll20!

For example:
Str=10, StrBns=0, StrFav=0,
Dex = 12, DexBns=1, DexFav=0
Con=14, ConBns=2, ConFav=d6

In all cases the Saving Throw = 1d0+nnnBns+1d(nnnFav)
Strength Saving throw = 1d20+0+1d0
Constitution Saving throw = 1d20+2+1d6

I've worked out that [[1@{Beren|ConFav}]] (for example) will roll the favoured dice in a macro.

I've loaded that example you provided, Oosh! It's nice but the dropdown populates with more than the Abilities

i.e. 

Again thanks for looking at this.

August 26 (4 years ago)
Oosh
Sheet Author
API Scripter

It looks like you're running the macro either with a token that is not linked to a character sheet, or the character sheet doesn't have those Attributes set. Try replacing "selected" with "Beren" while you're building the macro, it's easier to test if you don't need to worry about making sure you have a linked token selected every time you run it.

You'll just need to change it back to "selected" once it's finished, if you want it to be a universal macro for all players to use.


August 26 (4 years ago)

It works! Awesome. I was sure the token was linked, I'll treat the issue of getting it to be a universal macro as a separate issue.

Many thanks, Oosh.