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's and handouts

1487065890

Edited 1487066037
roll20 ogl sheet and compendium, both are really nice, thank you. However i have noticed that compendium is giving out strange damage calculations (like long sword, damage drawing from intelligence not strength or dex, or initiative drawing from intelligence not dex for level 1 characters ect). since I have not seen a way to correct this (including the setting for the item). Skills work fine though. With that being said, and I have atleast 1 new player, it would be handy VERY VERY HANDY.  If macros could be used in handouts and be clickable, without going through the custom character sheet fiasco.  Yes I am aware that they have a way to make macros in other ways, but in handout sheet form would be best, for me and learning various aspects for the players. I have been scowering roll20 wiki, which assumes you know more than what it says. On the subject of macros. at this time i am up to 10 tabs with no luck.
1487066694

Edited 1487066752
Richard B. said: However i have noticed that compendium is giving out strange damage calculations (like long sword, damage drawing from intelligence not strength or dex, or initiative drawing from intelligence not dex for level 1 characters ect). Issues with incorrect modifiers can occur when switching over to the 5e OGL sheet from another Character Sheet (see the note in Adding the Character Sheet to a Campaign ). On the Attributes & Abilities Tab of the affected Characters, try locating and deleting all Attributes which have a name similar to: "PB" or "pb" " <skill> _bonus"; e.g. "deception_bonus" " <ability> _mod"; e.g. "strength_mod" To delete an Attribute, hover over it and press the x button that appears. Richard B. said: it would be handy VERY VERY HANDY.  If macros could be used in handouts and be clickable This can be accomplished via Journal Command Buttons .
Silvyre said: Richard B. said: However i have noticed that compendium is giving out strange damage calculations (like long sword, damage drawing from intelligence not strength or dex, or initiative drawing from intelligence not dex for level 1 characters ect). Issues with incorrect modifiers can occur when switching over to the 5e OGL sheet from another Character Sheet (see the note in Adding the Character Sheet to a Campaign ). On the Attributes & Abilities Tab of the affected Characters, try locating and deleting all Attributes which have a name similar to: "PB" or "pb" " <skill> _bonus"; e.g. "deception_bonus" " <ability> _mod"; e.g. "strength_mod" To delete an Attribute, hover over it and press the x button that appears. Richard B. said: it would be handy VERY VERY HANDY.  If macros could be used in handouts and be clickable This can be accomplished via Journal Command Buttons . Option bottom it is. thank you...
Also, is there a macro for dummies? Your wiki does an excellent job at explaining things assuming you know what your reading, from grammer, content and context point of view.
To learn more about macros in general, I recommend reading through some of the pages listed on the Roll20 Wiki's Main Page , including: Macros & Text Chat Sheet Roll Buttons & Command Buttons Dice Reference & Rollable Tables Journal Attributes Abilities Roll Templates Tokens & Token Actions
1487124527

Edited 1487124780
Again, helpfull if you know what the full or most of context (basically, good for those having a strong grasp of concept (likly with disposition of programming background), which I don't. Thus asking for the dummies version) This is becoming circluar conversation.
1487126509
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Hi Richard, I don't think there is a reference like you are looking for. The macro system requires diligence, experimentation and study to fully master (or if you're like me, you half-master it and then spend a lot of trial and error for anything complicated.) If you are just looking for a low level of automation (example: rolling specific dice rolls), check out the Dice Reference link in Silvyre's post. That's about as basic as the macro code gets. You could also choose a character sheet with a high degree of automation. Many of the more popular game systems have clickable areas for commonly used abilities. Any time you use one of these, you should be able to go into the chat field, pres the up arrow and have the macro text revealed that was used to produce the result. You can either copy that wholesale into a button (say for a commonly used attack), or look at it and see if you can piece out the code and what it does, so that you can modify it for your own use. Some of them get quite complicated, so that might be more than you are looking for. Out of curiosity, what sort of thing are you wanting to do with macros? That might allow one of the amazingly helpful people here in the forums to give you more directly useful advice.
1487129034

Edited 1487132119
The low level stuff, I have forwarded to my players. The wiki as written, is rather hard too follow beyond basic rolls. What would help alot if there was a grammar (when/if can be use here"x" and proper placement) and usage (meaning) breakdown (especially since more than half of a macro text is symbols some i can piece together the rest is well... could be written Korean, figuratively speaking). Once I have that framework and a decent explain on that. More advance macros would be much easier. Soo a reference, with examples on grammar and usage, that works on a minimum level of "in theory". Then the rest of the wiki would make much more since.
1487136508
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
The dice reference pretty much is the grammar and alphabet of macros. Aside from this it is the "simplest use case" of all the roll expressions. If you need help understanding it, which is totally understandable as it's akin to trying to teach yourself Japanese from the textbook alone, then can you give a specific example of what you're trying to accomplish? There's a huge store of knowledge in the community. Addressing your specific mentions of what you're having trouble with: What symbols in the macro language are you having trouble understanding?
outside of words, and obviously dice. So i am going to steal from another post, its easy to see what it is accomplishing but not so much on how. &{template:5eDefault} {{title=@{classactionname1}}} {{subheader=@{character_name}}} {{subheaderright=Class/Racial/Other ability}} {{freetextname=@{classactionname1}}} {{freetext=@{classactionoutput1}}}} its easy enough to understand this in theory but in practice its typically messy right? No biggy, trial and error... However it would limit the amount trial and error by many hours actually understanding the grammar. when to use "&" vs "@" (other macros may start with @). Difference between "(" "[" "{" when to use them. what the hell is =@, let me guess there are variations on it. whats the difference between "=" between "=@", why use one verses the other. Why is "template:5eDefault" using ":", I am assuming based off wiki reading that this is typically before titles, however it is sometimes used in conjunction with other operators? Couldn't find what "|" means at all from other macros, this appears to get shoved in the middle of two complete macro's which causes me all kinds of confusion when trying to read what the macro is suppose to do. Especially when it does nether and doesn't appear follow any logic, it almost say screw the macro before and after and does something else.. I am sure if i spend 10 more minutes on this post, i would be beating a dead horse lol, soo I hope I am being understood. If its not a reference of 1d20 and the like or words. I have no idea how to use them let alone how to properly manipulate. So, Grammar of the language being used. A location for the grammar alone would be nice. >-vv +o+ <> "thank you";? --V ^_v %& i/o ../0 ... To illustrate via thank you, on how this reads for me. Its fun reading when you dont understand the parts of a sentence.
1487153215

Edited 1487153632
Richard B. said: &{template:5eDefault} {{title=@{classactionname1}}} {{subheader=@{character_name}}} {{subheaderright=Class/Racial/Other ability}} {{freetextname=@{classactionname1}}} {{freetext=@{classactionoutput1}}}} This is an example of a macro using a Roll Template . Specifically, the &{template:5eDefault} Roll Template is one provided by the D&D 5E " Community Contributed " Character Sheet. Documentation for the &{template:5eDefault} Roll Template can be found here . &{template:default} {{name=My Roll Template}} {{Hello=World!}} {{Try playing around with this!}} Roll Templates are advanced features. You'll probably want to at least become familiar with the syntax for Inline Dice Rolls and  Attribute calls before you look too much into Roll Templates, especially custom Roll Templates like &{template:5eDefault}. @{character_name} This is an Attribute call . Try entering @{selected|token_name} (a similar Attribute call) into the Text Chat to see what it does. You can also read more about using Attributes here: Attributes Attribute Macros Using a Selected Token with a Macro Using a Targeted Token with a Macro The D&D 5E "Community Contributed" Character Sheet provides its own set of Attributes, the names of which are listed here .
1487157189

Edited 1487158395
 All that is said on the wiki, not addressing the question. Define: @ & {{}} [[]] (()) | =@ (and the list goes on) After this, if i dont get an answer, Im going to assume no one knows the answer and look else where. Your continuing to define whole functions not operators.
Richard B. said: @ & {{}} [[]] (()) | =@ None of the above are operators or meaningful syntax per se. Some of the above characters combine with others to form meaningful syntax. For example, Attribute calls.
1487158504

Edited 1487158700
focus on that "per se" part thats what im wanting to know. Silvyre said: Richard B. said: @ & {{}} [[]] (()) | =@ None of the above are operators or meaningful syntax per se. Some of the above characters combine with others to form meaningful syntax. For example, Attribute calls. Focus on that "per se" part thats what im trying to understand. They have to mean something or attribute something. They have to be adding something.
1487158847

Edited 1487158993
Per se means "it and of itself"—most individual characters (e.g. the vertical bar |) are not meaningful syntax in and of themselves. (However, the vertical bar is a piece of many of Roll20's functions, such as Attribute calls; check out  Advanced Usage for Targeted Attribute Calls for an example of this.)
1487160506

Edited 1487161675
Silvyre said: Per se means "it and of itself"—most individual characters (e.g. the vertical bar |) are not meaningful syntax in and of themselves. (However, the vertical bar is a piece of many of Roll20's functions, such as Attribute calls; check out  Advanced Usage for Targeted Attribute Calls for an example of this.) Thank you for the chuckle, I do know what "per se" means, and thank you for the meaning of "per se". Given what you have said, you are note'ing thats something is still being adding wether it be something directly or indirectly, in this case using the vertical bar, has a indirect meaning. What is its meaning? If thats to hard too answer how does it set up meaning for others (i am not asking for result, instead about its behavior)? The examples ASSUME you know what these symbols mean and how these symbols work. All these examples do, is how to copy paste and minor modification. To be clear I am wanting to learn this not just copy, paste and modify. For me it very important to understand this.
1487163260

Edited 1487164480
@, %, #, & are most commonly used to delimit/prefix functions. Curly braces {} are most commonly used to open and close functions and are usually prefixed by one of the aforementioned delimiter (with the exception of Grouped Rolls ). Square brackets [] are most commonly used to open and close other functions (e.g.  Inline Dice Rolls and Inline Labels ) and are usually not preceded by a delimiter. Square brackets and parentheses () are syntactically relevant to Markdown links (which is what Command Buttons are). Vertical bars (and/or commas) are most commonly used to split arguments within functions, e.g. Attribute / Ability calls, Roll Queries , Grouped Rolls . Equals signs =  are used to split arguments within Roll Templates .
1487164517
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
Here's the meaning of each of those characters: @: denotes an attribute call, which calls whatever attribute is specified in between the curly brackets. You can also use a keyword (selected, target, or a character name) by preceding the call with the keyword and separating the attribute name from the keyword with "|". See the links from Silvyre above for more details as there are some additional options. &: only used in one place, in the declaration of a roll template. This defines which roll template's formatting to use. Other than the default template, these are sheet dependent. {{}}: Denotes the contents of a roll template field. Format is {{field name or left column text=field value or right column text}} [[]]: These are inline roll brackets. Anything you can do with "/r" you can instead put inside these. You can also nest them. If you want a roll inside a template, you will need to use these. (()): has no meaning, if you're seeing this, it's likely because of nested grouping of math operations. |: Separates the keyword, attribute/ability name and any other specifications of the call (like target name or max) from each other. Also separates options in a roll query. =@: forget the @ part of this. "=" Is used to separate the two parts of a roll template field as explained above or for an equivalency success fail(1d6=6 will return 1 on a 6, a 0 otherwise) and because you'll probably be wondering soon, here're two you missed: %: Denotes a character ability call. Same syntax as an attribute call, but no max option #: A global macro call. Has unique syntax (#macro-name) all of these are explained in more detail in the wiki pages Silvyre has already linked to, but hopefully that clarifies things.
Richard B. said:  All that is said on the wiki, not addressing the question. Define: @ & {{}} [[]] (()) | =@ (and the list goes on) After this, if i dont get an answer, Im going to assume no one knows the answer and look else where. Your continuing to define whole functions not operators. Symbol Brief Explanation Example More information @ Used to specify attribute calls, can use tokens by target/selection or directly access journal information. This is the most common call inside of a macro @{selected|character_name) Attributes Tab & This simply is used to tell roll20 that a roll template is being used &{template:default} Roll Templates {{}} This specifies a field used inside a roll template. Templates using have two columns, you would use a = to set each column. Most templates have a specific string needed on the left side of the equal whereas the right side holds the value for the field. {{Title=My template}} {{roll1=[[1d20]]}} Roll Templates [[]] This is used for inline calculation. Can perform thing from simple addition to even more complicated formulas. If nested, you can put a string next to a calculation to tell you what it is doing [[1d20+[[@{selected|attribute}]][ATTR] ]] Inline Rolls (()) As far as I know this is just to help with math principles of Order of Operations | I am assuming this is in regard queries ?{Name|Value}, in which case this is just the separator between the text that is output to the user, and the default value or possible options for the user to input. These are great for acting as conditionals in macros. ?{Modifier|0} Macro Queries =@ This is not a special thing, but a combination of attribute calls and roll templates. {{Title=@{character_name}}}
1487165924
Andrew C
Marketplace Creator
Oh and when you want to nest a bunch of this stuff you need to HTML replace all sorts of bits but usually the prefixes, except @. It gets messy. Trial and error works best.
Andrew (Halfling Gypsy) said: Oh and when you want to nest a bunch of this stuff you need to HTML replace all sorts of bits but usually the prefixes, except @. It gets messy. Trial and error works best. It's a terrible rabbit hole that will invade your dreams.
1487167206
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
Andrew (Halfling Gypsy) said: Oh and when you want to nest a bunch of this stuff you need to HTML replace all sorts of bits but usually the prefixes, except @. It gets messy. Trial and error works best. This is only for nesting inside roll queries (commas, bars, and curly braces as long as they aren't part of an attribute/ability call) and to some extent in API command buttons (described in the API command button wiki).
1487172219
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Thanks especially to Kyle G. and Scott C. A page that contained the basic symbols in the macro language and their usage would be a great addition to the wiki. I had to learn much of this by trial and error, and deconstruction. All of this info is to be found in the various pages Silvyre linked, but a page dedicated to the symbols and general syntax would be very helpful, particularly if there are reference links like in Kyle G.'s post.
1487177558
vÍnce
Pro
Sheet Author
keithcurtis said: Thanks especially to Kyle G. and Scott C. A page that contained the basic symbols in the macro language and their usage would be a great addition to the wiki. I had to learn much of this by trial and error, and deconstruction. All of this info is to be found in the various pages Silvyre linked, but a page dedicated to the symbols and general syntax would be very helpful, particularly if there are reference links like in Kyle G.'s post. Great idea.  These questions come up constantly on the forums.
I understand what Richard B. is saying. The wiki often does not explain the general case and applicability of a feature; it just gives you an example as the sole explanation of how a feature works. Let me illustrate with a simple example of my own. In the section on  Rolling for Initiative , we are told to select a token and then use the macro: /roll 1d20 + 5 &{tracker} It gives us a few consequences of using the "'tracker' roll option," but it doesn't tell us important things about this option. It must be part of a /roll or an inline roll. It can appear anywhere in the roll. If multiple tokens are selected, it will only update the turn tracker of one of the tokens. (Which one?) The tracker element itself will disappear from the text output. These issues are important, but we never get a general explanation of its syntax, just examples. I had to learn these things through trial and error. The fact that you can put the tracker element anywhere, for instance, affects attempts to nest macros and abilities, where the tracker part may not end up as the final element of a roll. In programming, when a book explains the if() control structure, it might start with examples, but at some point it will present the general case like so: if ( boolean-expression ) statement-block if ( boolean-expression ) statement-block else statement-block The Roll20 wiki only does this occasionally. Ideally, it would explain the general use of a feature, then give examples to illustrate how that general case is made specific. Examples should be supportive, not primary.
1487185487
Andrew C
Marketplace Creator
Scott C. said: Andrew (Halfling Gypsy) said: Oh and when you want to nest a bunch of this stuff you need to HTML replace all sorts of bits but usually the prefixes, except @. It gets messy. Trial and error works best. This is only for nesting inside roll queries (commas, bars, and curly braces as long as they aren't part of an attribute/ability call) and to some extent in API command buttons (described in the API command button wiki). And all sorts of stuff if you stick roll templates inside API Command Buttons with inline rolls and queries inside the template and...
1487185594
vÍnce
Pro
Sheet Author
Don't forget that the wiki is primarily a community effort.  Please make improvements as needed.
1487194438
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Vince said: Don't forget that the wiki is primarily a community effort.  Please make improvements as needed. I would if I were remotely qualified. :D
1487198898

Edited 1487199448
THANK YOU SOO MUCH Everyone, and yes a wiki page would be great. I would volunteer but as you have probably seen. My writing ability leaves much to be desired. I dont have an issue with trial and error, but I like to at least feel like I have a ball park idea of whats going on. I have bookmarked this page, if a wiki page gets made could you please post link. I would love to give it a read through. Much to be learned yay!!! Again thank you very much everyone, I really hope the wiki page gets made.