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

Macros - Why isn't this working?!

Hi Everyone.  I created a series of dice macros for d4 through d100 that look like this: When I execute that, I get a prompt asking how many dice of that type I'd like to roll, followed by an ask for any modifiers, and then I get a result in the chat window.  I then wrapped all those into a macro that looks like this: Which, in the chat result, brings up the message, a silly picture, and the box of pink buttons referencing the dice types.  By pressing a pink button, I get the same prompt as i do from the dice specific macros asking how many dice of that type I'd like to roll, followed by an ask for any modifiers. When I execute THAT command, I get no results.  Am I missing something?  It calls the queries from the specific macros, but just wont execute the actual roll. Thanks for any help!
1605305888
GiGs
Pro
Sheet Author
API Scripter
It looks like it should work, but I  cant test it to see what's up. If you post the code as text, not a screenshot, it'll make it easier for people to figure out whats up.
1605306656

Edited 1605307182
Oosh
Sheet Author
API Scripter
Aha, took me a minute... the HTML escape needs to be 
 You're missing the # So in full, it's !
#MacroName: !  <== API control character 
   <=== HTML escaped carriage return (I think line break, 
 also works) #   <=== Collections Macro control character Also, look at using a Macro Character/Mule , it sidesteps alot of the HTML replacement issues like this.... and the code just looks nicer.
1605326314
GiGs
Pro
Sheet Author
API Scripter
Well spotted. That's the sort of thing that would be spotted pretty quickly if someone were able to copy the code and paste it into a macro to try it out. (Not that I'm harping on about posting code in screenshots or anything...)
Sorry GiGs, I was afk for the bulk of the day, but thanks for looking, and I'll remember to post the code in a similar situation!
1605356166
GiGs
Pro
Sheet Author
API Scripter
No problem, I'm just cranky because there were at least three posts just this week that posted code as screenshots, lol.
1605370398
vÍnce
Pro
Sheet Author
Thanks for the fix, Oosh!  I appreciate it, and it works like a dream!
1605398557

Edited 1605398577
Oosh
Sheet Author
API Scripter
No problem! ∇ince said: