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 .
×

Housing multiple macros in a drop down list

Hello! I currently have a number of macros setup, shown as token actions, that adjusts the tokens light variables. (They use the 'Torch' API script) Examples: #Darkvision = !torch 60 1 no @{selected|token_id}|360 #Bullseye-Lantern = !torch 120 60 yes @{selected|token_id} --53 I have roughly 6 or 7 different lighting setups that players can choose between to reflect different torches, spells etc. and I'd ideally like to house these in a single drop-down macro called 'Light' that then allows you to select one of these choices. I've tried calling the existing macros as below, but this doesn't seem to work: #Light = ?{Select a light level|None, !snuff |Torch, !torch|Lantern, #Lantern|Hooded Lantern,#Hood-Down|Bullseye Lantern, #Bullseye-Lantern|Flame, #Produce-Flame} Pretty sure I've missed something ridiculously simple. Any help appreciated! Odd
According to the Wiki for  Macros , you are missing a space after the macro inside the query in order to get it to work properly.
1502127338
The Aaron
Pro
API Scripter
I'd probably suggest setting up a single macro that has each of the arguments as possible choices: !torch ?{Light Type|Darkvision,60 1 no --360|Bullseye Lantern, 120 60 yes --53} Torch operates on the selected token automatically, so no need to specify a token id. I use a similar macro for light in my own games, but using TokenMod instead.
Kyle G. said: According to the Wiki for  Macros , you are missing a space after the macro inside the query in order to get it to work properly. Aha... thank you. That got everything almost working, and with another pass through I finally managed to parse everything correctly!
The Aaron said: I'd probably suggest setting up a single macro that has each of the arguments as possible choices: !torch ?{Light Type|Darkvision,60 1 no --360|Bullseye Lantern, 120 60 yes --53} Torch operates on the selected token automatically, so no need to specify a token id. I use a similar macro for light in my own games, but using TokenMod instead. This would definitely be the tidier way of doing it. I have a fair bit of cleaning up to do after the trial and error approach I used setting everything up.
1502150431

Edited 1502150465
Nighthawk
Sheet Author
I wasn't even aware this was a thing. Looks like I'll be playing around with this on my sheet. Could prove useful later on.