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

Struggling with ability command buttons.

Apologies if this is a silly question, or if there is an obvious answer I'm missing. New to Roll20 & new to DMing. Not a Roll20 Subscriber. D&D 5e system. Character Sheet: D&D 5E by Roll20 I've recently had time to explore using macros and other tools and, through these forums, have learnt how to create Abilities to generate attacks and spells from Character sheets, and use these as Token Actions. I like this set-up, but when using a character with spells, this results in a lot of Token Actions. I would like to be able to create an Ability which, when run, generates some Ability Command Buttons for the charcaters spells (like being able to choose a spell from a spellbook). I have looked through the forums and tutorials but have run into some issues: In the character (NPC in this case) - I have created abilities for each Cantrip/Spell, hopefully demonstrated in the photo. "Cantrip:Light" generates the spell as desired. The "Cantrips" ability however, which should generate a Button in chat, simply generates the word in chat, which underlines when hovering over, but cannot be pressed. Am I doing something wrong? Should the scripting for Ability Command Buttons be different when put in an ability? Should I be using a Query for a drop down menu? Apologies for the wall of text. Thanks for any suggestions in advance!
1586289726
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Three things: 1) if all abilities (both the called ability and the calling ability) exist on the same sheet, the syntax is much simpler. You don't need the selected keyword: [buttonname](~AbilityName) 2) Try getting rid of the colons in the name. Use "Cantrip-Light" or similar. 3) Finally, you're probably going through more steps than you need to, unless you also want token action buttons as well as chat buttons. An ability that is baked into the sheet has yet another syntax, and can be called directly within a button. In this case, it does need the selected keyword. Try: [Light](~selected|repeating_spell-cantrip_$0_spell) You could even get really fancy and turn this into a  Chat Menu : &{template:npcaction} {{rname=Spells}} {{description=[Light](~selected|repeating_spell-cantrip_$0_spell) [Cantrip 2](~selected|repeating_spell-cantrip_$1_spell) [Cantrip 2](~selected|repeating_spell-cantrip_$2_spell) [Cantrip 2](~selected|repeating_spell-cantrip_$3_spell)}}
Am I the only one who goes through the laborious process to find the exact ID for each attack and/or spell in case I rearrange things later?
1586300870
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Some folks prefer that method, especially for their own PC character builds. I like to make things generic and reusable as possible for less maintenance down the road.
keithcurtis, that is really helpful, thanks! Im at work at the minute but will try out your suggestions next time I get chance.  Nice to see such a helpful community 😊. 
Works perfectly, thanks!