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 "Show as token action" show only for PC and hide from npc tokens?

I have set up a bunch of macros for my players. But I don't want those token action macros to show up for NPC tokens. Is there a way to do this?  Using 5e OGL if that matters. 
1541531795
GiGs
Pro
Sheet Author
API Scripter
Unfortunately no.  Since your a Pro user, you could use a script to add the macros as Abilities to character sheets, and set them as token actions. Then they'd only show up on the character sheets you add them to. I think the script to make Abilities is called setAbility, if you want to search for it.
1541712197
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
You could set up your tokens to run in a chat menu . Then you would only have one Ability to add to PC sheets, or save it as a global token macro and have only one "extra button" on NPCs. The downside is that it would add a bit of extra traffic on the chat log.
keithcurtis said: You could set up your tokens to run in a chat menu . Then you would only have one Ability to add to PC sheets, or save it as a global token macro and have only one "extra button" on NPCs. The downside is that it would add a bit of extra traffic on the chat log. That's a great idea, thank you. A pain because I'm dealing with macros that have html elements, but at least it works. 
1541716000
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
If you are dealing with a lot of HTML elements, consider building your macros as abilities on a Macro Sheet . The syntax is much more forgiving, and they become extremely portable Just remember to give your players edit and control access to be able to run them. If you do not put the sheet in their journal tab, and never put a token instance of it on the table, you won't have to worry about them disturbing the code, either. Finally, if you build your actual chat menu as a Collections Macro that calls the Macro Sheet Abilities, you can make that one macro a universal token macro. Preface it so that so that it whispers to the GM. It won't cut down on the chat traffic you see, but it will for your players.