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

ChatSetAttr - Few 'simple?' settings

1554155673

Edited 1554158740
Hey girls/guys! I'm hoping for a little bit of help. I know that I can do this on a 'global scale' in the roll20 game menu somewhere, but I'm trying to create a short macro, using ChatsSetAttr that will update some of the settings for selected NPC's. Set selected NPC's to: Roll Queries: "Query Advantage" Whisper Rolls to DM: Never NPC Name in Rolls: Hide Could anyone help me out with the correct code for this please? Thanks! Edit: Sorry. Of course! I'm using the 5e Roll20 sheet. Is it still called OLG?
1554157409
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
To even begin, we would need to know which sheet you are using. Different sheets use different attribute names.
1554157946
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Hoping you are not talking about the Roll20 sheet. The option for query is actually a formula. You can see it on the attributes and abilities page. It would probably take some very specialized tweaking.
1554158726
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Assuming the Roll20 5e D&D sheet: This will hide the name: !setattr --sel --npc_name_flag|0 This will set the whisper type to never: !setattr --sel --wtype|1 These were easy because they are the default value of the sheet and you can just set them to 1. Setting them to anything else is setting them to a formula, and I don't know how to do that with ChatSetAttr without breaking things.
1554158861

Edited 1554158912
Thanks Keith. I presume it's something to do with rtype or something?  
1554159407
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
That would seem to be correct. The value to set it to is: {{query=1}} ?{Advantage?|Normal Roll,&#123&#123normal=1&#125&#125 &#123&#123r2=[[0d20|Advantage,&#123&#123advantage=1&#125&#125 &#123&#123r2=[[@{d20}|Disadvantage,&#123&#123disadvantage=1&#125&#125 &#123&#123r2=[[@{d20}} But that breaks ChatSetAttr. Perhaps Jakob can give some insight. You can PM him , or post the problem to the ChatSettAttr feedback thread .