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

Trying to find a template for a macro that randomly selects a macro from a list then executes that macro

for example if I made a macro that roll a set of tables to generate an item and I had four of these for four categories of item how could I make a macro that randomly selects one of the four macros I had made
1508811004
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
You might need the API and The Aaron's Recursive Tables script for a trick like that...
1508852581
The Aaron
Pro
API Scripter
Depending on what you want to do, there may or may not be a script for it.  Macros and Abilities on Characters are a hard class of object for the API to execute.  They must be preprocessed to replace any references to @{selected} or @{target} with things that make sense.  If you're just trying to select from a hierarchy of Rollable Tables, that can be done by the RecursiveTable API script.  The API requires a Game created by a currently active Pro Subscriber.
1508899845
Andrew C
Marketplace Creator
Didn't someone recently do a 'treasure roller' only using Rollable Tables and nested Compared Lists?
1508929098
The Aaron
Pro
API Scripter
This:&nbsp; <a href="https://app.roll20.net/forum/post/5636784/nesting-" rel="nofollow">https://app.roll20.net/forum/post/5636784/nesting-</a>... Not sure if it applies to this case, but give it a shot!