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

5e NPC action macro

Hello, I am trying to make a macro for NPC actions. So far I came up to this: {template:npcfullatk} {{attack=1}} @{damage_flag} @{npc_name_flag} ?{Action?| @{selected|repeating_npcaction_$0_name},0|@{selected|repeating_npcaction_$1_name},1} {{rname=@{selected|repeating_npcaction_$?{Action?}_name}} {{r1=[[@{d20}+(@{selected|repeating_npcaction_$?{Action?}_attack_tohit}+0)]]}} @{rtype}+(@{selected|repeating_npcaction_$?{Action?}_attack_tohit}+0)]]}} {{dmg1=[[@{selected|repeating_npcaction_$?{Action?}_attack_damage}+0]]}} {{dmg1type=@{selected|repeating_npcaction_$?{Action?}_attack_damagetype}}} {{dmg2=[[@{selected|repeating_npcaction_$?{Action?}_attack_damage2}+0]]}} {{dmg2type=@{selected|repeating_npcaction_$?{Action?}_attack_damagetype2}}} {{crit1=[[@{selected|repeating_npcaction_$?{Action?}_attack_crit}+0]]}} {{crit2=[[@{selected|repeating_npcaction_$?{Action?}_attack_crit2}+0]]}} {{description=@{selected|repeating_npcaction_$?{Action?}_show_desc}}} @charname_output} That is just a try, assuming only two actions. It's not working and I cannot figure out what my mistakes are... 
I used to want this myself too and even had a workable version of it, but I discovered that I was still looking at the sheet plenty so it felt redundant having 1-8 extra token actions cluttering up the top of the screen.  I also cannot stand queries for speed macros I will tolerate 1 sometimes in a macro but 2-3 drop down choices before anything fires is tedious when I'm the DM taking 12 turns in combat.  I get what you want, but I feel like in the end the whole point of the npc sheet and pc sheet was to not need these token actions but you are entitled to your own thoughts on this too, just speaking from a standpoint of someone who once wanted what you want, got it, and changed back to having every sheet open and minimized.
frons79 said: Hello, I am trying to make a macro for NPC actions. So far I came up to this: {template:npcfullatk} {{attack=1}} @{damage_flag} @{npc_name_flag} ?{Action?| @{selected|repeating_npcaction_$0_name},0|@{selected|repeating_npcaction_$1_name},1} {{rname=@{selected|repeating_npcaction_$?{Action?}_name}} {{r1=[[@{d20}+(@{selected|repeating_npcaction_$?{Action?}_attack_tohit}+0)]]}} @{rtype}+(@{selected|repeating_npcaction_$?{Action?}_attack_tohit}+0)]]}} {{dmg1=[[@{selected|repeating_npcaction_$?{Action?}_attack_damage}+0]]}} {{dmg1type=@{selected|repeating_npcaction_$?{Action?}_attack_damagetype}}} {{dmg2=[[@{selected|repeating_npcaction_$?{Action?}_attack_damage2}+0]]}} {{dmg2type=@{selected|repeating_npcaction_$?{Action?}_attack_damagetype2}}} {{crit1=[[@{selected|repeating_npcaction_$?{Action?}_attack_crit}+0]]}} {{crit2=[[@{selected|repeating_npcaction_$?{Action?}_attack_crit2}+0]]}} {{description=@{selected|repeating_npcaction_$?{Action?}_show_desc}}} @charname_output} That is just a try, assuming only two actions. It's not working and I cannot figure out what my mistakes are...  The issue is the Roll20 Order of Operations - nested macros break when there are certain symbols in them (, | } ), and attribute calls (@{selected|____}) are resolved before queries (?{QueryName}), so what is happening is the system sees an incomplete attribute call and it fails, then  it resolves the query to add the result of ?{Action?}.  Chat Menus are an easier to maintain alternative, if your chat log isn't too cluttered already.