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

New to macros, could use some help

1626887561

Edited 1626887799
As the title says, I'm new to macros and I have very little experience coding. I have been having an issue setting up a basic status report template in my game. The functionality of it is fine but I think because I'm using Giffyglyph's  D&D 5e Darker Dungeons (Character Sheet v2), I'm not getting the right keywords or something to get the formatting working.  My current macro is: /w gm &{template:default} {{name=Health Check}}  {{PC1= AC @{ PC1 |ac} - HP @{ PC1 |hp} / @{ PC1 |hp|max}}} {{ PC2 = AC @{ PC2 |ac} - HP @{ PC2 |hp} / @{ PC2 |hp|max}}} {{ PC3 = AC @{ PC3 |ac} - HP @{ PC3 |hp} / @{ PC3 |hp|max}}} {{ PC4 = AC @{ PC4 |ac} - HP @{ PC4 |hp} / @{ PC4 |hp|max}}} and, it works fine, but the formatting is all over the place and just looks ugly as heck.  Can anyone with more experience help a poor smooth brain out?
1626890211
David M.
Pro
API Scripter
Try removing the line breaks between your double bracket items: /w gm &{template:default} {{name=Health Check}}  {{PC1= AC @{ PC1 |ac} - HP @{ PC1 |hp} / @{ PC1 |hp|max}}}  {{ PC2 = AC @{ PC2 |ac} - HP @{ PC2 |hp} / @{ PC2 |hp|max}}}  {{ PC3 = AC @{ PC3 |ac} - HP @{ PC3 |hp} / @{ PC3 |hp|max}}}  {{ PC4 = AC @{ PC4 |ac} - HP @{ PC4 |hp} / @{ PC4 |hp|max}}}
You just need to put them all on a single line: /w gm &{template:default} {{name=Health Check}} {{PC1= AC @{PC1|ac} - HP @{PC1|hp} / @{PC1|hp|max}}} {{PC2= AC @{PC2|ac} - HP @{PC2|hp} / @{PC2|hp|max}}} {{PC3= AC @{PC3|ac} - HP @{PC3|hp} / @{PC3|hp|max}}} {{PC4= AC @{PC4|ac} - HP @{PC4|hp} / @{PC4|hp|max}}}
oh my god... I can't believe it was that simple.  This is why I could never wrap my head around coding Thanks guys
CHRIS said: oh my god... I can't believe it was that simple.  This is why I could never wrap my head around coding Thanks guys in virtually all coding languages whitespace is ignored. so the issue here is not your logic but rather roll20's syntax being extremely crude.