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

Characters as sides in a rollable table???

Hello Everyone - I want to create a rollable table that has creatures as the sides. The results of the roll would then drop the tokens of the creatures chosen on the map. Is this doable? I have been looking around for a way to do this. But I haven't even found people asking this question. Thank you. 
1649863308
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
The rollable table tokens create un-affiliated tokens. In other words, a random token from a table of tokens can be generated on the VTT, but it won't by default represent a character. There are ways to accomplish this with the API, but that is a pro perk. In case there is another way to solve your problem, ignore the "how" for a second and describe "what" you want to accomplish.
Thank you keithcurtis. I am looking to recreate a sealed pack miniature based skirmish game over roll20 so I can continue to play with people I have moved away from. I have created the figures as characters and linked tokens to those characters. The characters have all the stats and relevant info on their sheet. So a quick shift+double click on the character token will pull up the relevant info.  I can create tables to generate a list and show images of the tokens in the chat menu. I would then just need to go find the characters in the journal and drop them on the battle map.  What I am looking to do is skip the find the figures the table selected for me and drop them on the battle map and instead just have the table drop them on the battle map. I hope this makes sense.
1649877538
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Ah, so you are trying to automate placing a "random" (procedurally generated) list of default tokens. That would almost certainly require the API. There is a summon script that can do this. The best I can come up with (and it's not much) is to have a "Token Page" where one of each unit is already deployed. Rather than hunt for each one in the journal and drag it onto the VTT multiple times, you could use your list as a reference to quickly select one of each required unit from the token page, copy, and then paste on the deployment page. Then select ones that need multiple copies and copy-paste until you have the right amount. Not automatic at all, but should be much faster than going through the journal tab for so many tokens.
Keithcurtis you have been very helpful. Thank you.  I now know that I cannot tie a character to an option on a rollable table so that the table will place the selected character on the map. I am going to make tables that list out the names of the figures in the set. I ended up making several tables for each set to represent opening a sealed pack of this game. The tables are: common, uncommon, rare, extra. The macro I made for opening a "pack" is to roll 2 times on the common table and then once each for uncommon, rare, and extra. Just like the distribution of the physical products.  I have poked around the forum looking for the answer to my next questions and I couldn't find it. So I am asking... Can I create a macro that will prompt the player to make a selection from a list of options I provide. Each option would then roll a pack opening macro from a different set.  Example: You open a sealed pack. Choose from these packs: Set 1 Set 2 Set 3 Then when the player chooses a set option it will roll out and list out the 5 figures the player would then need to find. I know each set would need to be a macro itsself that would roll the separate tables. So choosing set 1 would then be the command to engage Set 1 macro.  I just do not know how to make that prompted list of options. 
1649888877

Edited 1649888989
robert t. said: Keithcurtis you have been very helpful. Thank you.  I now know that I cannot tie a character to an option on a rollable table so that the table will place the selected character on the map. I am going to make tables that list out the names of the figures in the set. I ended up making several tables for each set to represent opening a sealed pack of this game. The tables are: common, uncommon, rare, extra. The macro I made for opening a "pack" is to roll 2 times on the common table and then once each for uncommon, rare, and extra. Just like the distribution of the physical products.  I have poked around the forum looking for the answer to my next questions and I couldn't find it. So I am asking... Can I create a macro that will prompt the player to make a selection from a list of options I provide. Each option would then roll a pack opening macro from a different set.  Example: You open a sealed pack. Choose from these packs: Set 1 Set 2 Set 3 Then when the player chooses a set option it will roll out and list out the 5 figures the player would then need to find. I know each set would need to be a macro itsself that would roll the separate tables. So choosing set 1 would then be the command to engage Set 1 macro.  I just do not know how to make that prompted list of options.  You could create a chat nest message that lists off a bunch of buttons that will assign the statistics ad control to you of an npc sheet in the journal, and you can also spawn blank tokens to modify with that script.  Sadly all of this would be alot of work and require a pro subscription.  And that chat nest could be many many randomized options put into a rollable table and displayed, but again needing api access.  Off the top of my head, the cookie cutter scripts that could perform some of this task would be Recursive tables for table displayage, spawndefaulttoken to get a token to plop down to select for said message buttons, and most definitely tokenmod to change the properties of the blank tokens to become attached and present the stats of the sheets.  
1649891062
David M.
Pro
API Scripter
As the others have pointed out, a Pro subscription would be required to click a button and have something appear on a map. The SpawnDefaultToken script is made specifically for this. Assuming all tokens are the same size, you would just select a token on the map and run something like this macro: !Spawn {{   --name|[[1t[UncommonPackTableName]]]   --offset|1,0 }} Where the rollable table contains just the names of the potential character sheets in each pack. This will spawn the default token of a character sheet one square to the right of the selected token. If there are multiple copies of the same token needed, just add a --qty|<some number> line to it. Note, you would need to run this macro as many times as there are characters in the pack. You could further automate this using Scriptcards and dynamically generating a series of !Spawn api calls based on conditional logic. This would be pretty straightforward, and would allow for spawning all of the tokens in the pack with one click and also proper token sizing, etc. during runtime if that was required. Without the api, though, you're unfortunately going to be stuck with manually dragging tokens from the journal.
1649894229
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
For a prompted list of options, it is almost certainly easier to make a  Chat Menu . The syntax is simpler and it is easy to make a laundry list of macros for players to click.
Wow guys thanks! The Chat Menu option looks good. I'll have to figure that out.  I was thinking more of this scenario: I make a character that has a pack as a token, we will call it Pack. I drag Pack onto the map. Then any player can click on Pack and have a character macro button that says "Open Pack". Clicking that button will present a drop down list of sets. The player picks a set, and that rolls on that sets table, listing out the results in the chat menu.  Is this an option?
1649912669
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
I think you are looking for headaches trying to code rolls and macros into a dropdown query. The choice is what is presented in a chat menu. That's why it is a menu — it has a list of clickable buttons for each set. The user clicks a button that calls an Action (a macro stored on the same Pack sheet) that sends a report to chat. &{template:default} {{name=Pack}} {{Sets to choose=[Set 1](~Set1Macro) [Set 2](~Set2Macro) [Set 3](~Set3Macro)}} Set1Macro is the name of another Action on the same sheet. It could be: &{template:default} {{name=Set 1}} {{Rare=[[1t[Rare-Table]]]}} {{Uncommon=[[2t[Uncommon-Table]]]}} {{Common=[[3t[Common-Table]]]}} All of your Actions should be written on the same sheet. It makes the syntax very simple and keeps you from having to use any HTML substitutions. It allows you to make buttons in the Chat Menu that are simply [name of button](!name-of-Action) Your rolls and Actions will likely look different from what I have here, I'm just making simple guesses. For more info about how to use actions this way, look up  Macro Character Sheet . Avoid drop down queries for anything other than asking for a value if you can. They are terrible for automation. They work, but they can quickly become very complicated to code. Chat menus are simple.