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

Putting a background color on a token

Hello, I am using Roll20 for my Dragonlance Campaign and use top down views of battlefields, dungeons, etc.  I use tokens that have a transparent layer as the background so that they show up well in the dungeon maps I create.  However, some of the adventures involve mass combat rules.  Using these rules "necessitates" using "bases" on tokens so you can see when a unit's figures are close or far apart, a la old miniatures rules from the 60's and 70's onward.  So, the question is, is there a functionality in Roll20 that allows you to add a background color to a token?  I know how to use GIMP to add layers and color them fine, so I could create these individually, but that's a fair bit of work for armies on the scale I'm dealing with, and if there's a simply checkbox or button, or something like it could be added, or maybe there's an API script for something like that, it would save a lot of work.  Thoughts?  Should I drop this into the suggested improvements and watch it die a slow death in that forum instead? :P
1720579010
timmaugh
Pro
API Scripter
Will auras not work? Even if they don't extend beyond a token's "boundary", they fill in the transparent space of a token within their footprint. Here is a screenshot of a 0ft radius aura in both circle and square shape: Unless you have another requirement for the auras, they seem well suited to what you want to do. You can find the controls on the Token Properties pop up. You can control the aura with any number of scripts, but many of them might tie it to HP, a curse, or a spell effect. If you just need to set the aura to a certain size/color and turn it on, you can do that with TokenMod: !token-mod --on showplayers_aura1 --off aura1_square --set aura1_radius|5 That turns on player visibility for a token's aura1 while also making sure that the aura is a circle and at a radius of 5 (the start of the radius is the outside of the grid cell origin. If you needed to set multiple at once (with individualized values that could be drawn from data on the token, then something like the command, above, could be expanded and agnosticized to work with more tokens at once by incorporating metascripts, but I'll stop here, for now. If you like this idea and want to explore such expansion, post back with where we could find the data for each token that would let us get individualized values for each.
That, mostly, took care of it.  I've used aura's before for spell effects and things, but hadn't considered setting the radius to zero to generate an "in token" back color.  However, while it worked great on square tokens, on cavalry units (in boardgame speak, 25mm by 50 mm, but in roll20, i have them set to 1x2 squares in the attached pic), the coloration went outside the bounds of the tokens actual size, even at a zero radius.  Any ideas why this might be, or how to limit the non-square coloration to the bounds of the token itself?
Oh, also, I'm not sure why you would need to use a mod to make the aura visible to players... just set the player permissions on that aura to "see" and they should be able to do so, unless I'm missing something obvious (or perhaps less obvious) about the token mod point you were making. In any case, this is nearly exactly what I was looking for, so long as I can figure out how to get the non-square tokens to work "correctly" for my purposes.  
1720807433

Edited 1720807691
Gold
Forum Champion
Tricky issue there, with the Square Aura on a 2x1 token.  Unfortunately the Aura is square (must be square or circle), no option for Rectangle when using Auras. Also the AURA feature will always be centered on the centerpoint of the token.  You can set NEGATIVE values in the aura size. You may try Aura size of -1 and see if you like the effect. I'm afriad it will be closer to what you want but not exactly what you want. Alternatively try the Aura Size of 2, and see if that's useable.  If those don't work your next option is to Re-create those calvary tokens in a Graphics editor. You'd put transparent padding around the sides, leaving the calvary horse in the middle, forcing the Token Size to become square, with 2x2 shape instead of 2x1 shape. Then try the aura again, this time on a 2x2 calvary token. See if that's the effect you want?  But if you're taking every calvary into a Graphics Editor anyway, then another option/idea is apply the BASE that you want under the calvary in your graphics editor (such as a green grass square base). Then you won't need the Aura method.  Otherwise if THOSE ideas don't work, another approach entirely (not as good), put a separate BASE TOKEN (a plain green square token) underneath your calvary token, instead of using aura. Use 2 tokens stacked (1 as the base, 1 as the calvary layered on top). Roll20 would let you "GROUP" them, but you won't want that because Grouped tokens don't show their Bars/Nameplates that you are using. So you'd have to drag-to-select the Base and the Calvary at the same time, every time you want to move them.  As a PRO subscriber, you could then use a Mod script like one called MOUNT which lets your Base-Token always keep up with your Calvary (top-token). This would fix the inability to use the GROUP feature.  Using any Mod for this is totally optional, and I haven't thought of any Mod that would solve your core question. The reason Timmaugh explained TokenMod is a faster way to apply your preferred Aura settings to many tokens at-once. So you don't have to go into each individual token settings to set-up all the auras, if you have a lot of tokens on a page.  Hopefully someone else will come with a better answer, because I'm not satisfied or certain that any of these methods will perfectly suit your use-case. There must be a better way. 
1720807644
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
It may help to remember that going strictly by the rules, a horse, being a Large creature, does indeed take up four squares, despite its general shape.
1720809449

Edited 1720809542
Not sure what the background colors are for, another suggestion is to add a color to the token from the drop down (sorry the official name eludes me currently).  Not sure if this is a option for you.  The background would stay the same, but you could identify by the various colors, and it would stay on the token itself and not the surroundings.
1720811744

Edited 1720811825
What kiethcurtis says is true, because in D&D (and I'm assuming your Dragonlance campaign is based on D&D) the 10x10 area is not the size of the creature, but how much space it controls, so the aura would still work. Of course, if your game uses different rules for creature size, then Gold's advice on creating tokens without transparent backgrounds would apply. If you do go with new tokens and only want the opaque backgrounds for certain conditions (such as large scale battles as mentioned in your original post, you could create multi-sided tokens, then use either manually change between transparent and opaque background or use a TokenMod script: !token-mod --set currentside|+ "+" will change the token to the next slide in the list. If there are only two sides available, it will toggle between the two. The TokenMod help, as well as this message thread gives more options keithcurtis said: It may help to remember that going strictly by the rules, a horse, being a Large creature, does indeed take up four squares, despite its general shape.
Thanks to all... my comments collectively below: 1 - I tried the negative aura, just to see what would happen, and it didn't help much. 2 - The sizing in this case is based on the battlesystem rules for ad&d, both 1st and 2nd edition sets, so the ratios are correct as displayed for cavalry. 3 - I'll be using the colored buttons for various other effects (regular/irregular order perhaps, morale, etc.)  That said, the original idea is to give the players the visibility into the edges of the token, so they can keep units in regular or irregular order visually.  It's also quite pertinent as the distance between tokens matters a lot to what units figures are allowed to attack the opposing units figures.  And also, to keep units from "overlapping" one another, which isn't as readily available visually without some sort of colored box to give that at a glance. 4 - I'm very familiar with GIMP and use it quite frequently for modifying tokens colors, weapons, etc.  It was my original plan, but put up the query just in case there was something that might allow me to reduce the time/effort needed. So, the current plan is, I have all the square figures in the units colored w/ the square aura's.  Roll 20 conveniently includes the http color coding for those.  Helpful, because I have all the units in a brigade back colored w/ the same color, so who can command what is a bit more obvious immediately too.  I'll load up the cavalry units' tokens in GIMP, add a layer and put that underneath the main token layer.  Color it in using the http codes, and give it a opaqueness setting (probably somewhere in the 40 to 60% range will get to the auras in roll20.)  Then I just export them back into a png file and load it up in roll20.  Putting up the query and getting your collective answers was quite helpful, as it saved me about 60 or 70% of that work, as I only have to deal with the cavalry units, and Lord Soth's chariot unit (2 Banshees on a chariot being pulled by ghostly horses :) If anyone that posted in here is interested, I'll post the finished product, probably some time tomorrow as I'm headed off to a concert with my sons in an hour or so... In the meantime, thanks for sharing your thoughts! v/r B
Found the time to finish the good guy side of things... Here's how the layer add turned out.  Looks like roll20 uses a 35% opacity on those aura, btw. :) The square units are purely roll20 aura's.  The cav is my work in gimp.  I figure the colors by brigade are handy as noted before too.
1720835559
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Brian O. said: Found the time to finish the good guy side of things... Here's how the layer add turned out.  Looks like roll20 uses a 35% opacity on those aura, btw. :) Little known fact: When you specify the color, you can input the values as rgba, with the fourth value being an alpha transparency.
Thanks for that tidbit Keith!