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

Macro Questions

Hello, I was making a global macro for sneak attack is there a way to set the Name to pull the damage type of the attack like @{Name|something}? I'm using:  5th Edition OGL by Roll20 v 2.3. I'm also curious about what people think of macro buttons? I just noticed that's a thing, and not sure how to use them or if it'd be worth setting them up.
1530452103

Edited 1530453053
Hi there!&nbsp; With the new sheet it has a built in global damage modifier that may suit your needs, just ensure the checkbox in the options (the gear icon on the char sheet) for "Show Global Damage Modifier Field" is toggled on. Then, below the 'Attacks &amp; Spellcasting' field on the main char sheet should be a global damage modifier area that, coincidentally, defaults to sneak attack.&nbsp; This can be called and calculated independently of an attack made from the 'Attacks &amp; Spellcasting' field the with: [[@{name|global_damage_mod_roll}]] The downside is if you have multiple global damage mods it will roll them all at once. If you're trying to get the name of a damage type from an attack in the 'Attacks &amp; Spellcasting' section, try: @{selected|repeating_attack_$X_dmgtype} where 'X' is the number of the entry in the section counting from top to bottom, starting from 0 If you're trying to get the name of a damage type for a custom macro, I suppose it depends what template you're using. I'd recommend checking out: <a href="https://wiki.roll20.net/D%26D_5e_OGL_Roll_Templates" rel="nofollow">https://wiki.roll20.net/D%26D_5e_OGL_Roll_Templates</a> Possibly the Damage template. If you just want the damage type to display that it was sneak attack damage when mousing over a roll just add something like [[ 1d6[Sneak Atk] ]] Lastly: Macro buttons.&nbsp; I'm a big fan of these.&nbsp; These allow one to add a button pretty much anywhere you can add text that can be clicked on to call other macros, attacks, spells, traits... anything with a 'repeating section' really.&nbsp; Say you have a blank template macro on a character sheet, are entering text and want a list of buttons to call...: Other macros on your character sheet:&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; [Name Displayed on Button](~MacroName) Macros from your 'Collection' tab in the right hand window: [Name Displayed on Button](!&amp;#13;#MacroName) A repeating section like a cantrip from the Spell list:&nbsp;&nbsp;&nbsp; &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; [@{repeating_spell-cantrip_$0_spellname}](~repeating_spell-cantrip_$0_spell) Or an attack from the 'Attacks &amp; Spellcasting' list:&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; [@{repeating_attack_$0_atkname}](~repeating_attack_$0_attack) If you're calling sections or macros to or from a differerent character or the macro is in your 'Collections' tab macro list, be sure to add "selected|" before the called thing, for example: [Name Displayed on Button](~selected|MacroName)