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

Different Colors for Blocked Line of Sight

I'm looking for a way to show blocked line of sight areas with colors other than black. So if your line of sight is blocked by a tree the color the player sees in that direction is green or brown. The purpose is to allow players to know they can't see because of foliage  (green) or a wall (black) or whatever. This way, for example,  if the line if sight is blocked by UDLpasswall representing a forest (green) then the players would know they can continue to move, even if their line of sight is blocked.  Is there a way to do this or do I need to figure out a new API? I figure that UDLpasswall, UDLwindow, and doorknocker can change dynamic lighting interactions that this should be possible. I just don't know where to begin. 
1632675791
The Aaron
Roll20 Production Team
API Scripter
It's not possible for the API. We can only create lines and we do things to the line representation that cause the emergent effects of UDLPasswall and UDLWindow. We don't have any access or control over the shroud color.  I'd suggest drawing a transparent green circle around trees/foliage that players can recognize as representing an area of foliage blocking their sight. You could even draw several to give a feeling of the shape of the tree.  Note: you can make transparent shapes by adding a number between 00–ff to the end of the color in the color picker. Here's a transparent green: #33ff33 99
Could you make a dynamic lighting line that projects light? Then control the direction and distance of that light?
1632697775
The Aaron
Roll20 Production Team
API Scripter
No.  You could make a light on the DL layer on a token (tokens on the DL layer don't show up, but their light does) and color it. You could set it's directionality, but you couldn't reasonably adjust it based on the players, and even if you did that, if it only shined where they couldn't see, they'd never see the light.
1632698082
The Aaron
Roll20 Production Team
API Scripter
Here's kind of what I'm talking about with the drawing:
1632796024

Edited 1632796046
Beat that dead horse. What about mixing udlpasswall with one way dynamic lighting?
1632798698
The Aaron
Roll20 Production Team
API Scripter
LoL. There's no one-way Dynamic Lighting option on Roll20.  There's only: Blocks Sight and Movement Blocks Sight [API Hack Only] Blocks Movement [API Hack Only] One problem with doing anything more complicated via the API (such as just drawing obscuring shapes) is that you can only affect the game as a whole, not a single player's perception of it.  If you wanted to go all out and had to have it, the only option would be to split every player to their own copy of the page, then use the API to draw obscuring shapes on each map for the player that was on it and the tokens they control.  That would probably take about 30–40 hours of work and it would likely be very slow to update, meaning players would get a flash of what is back there every time they moved. You could draw a network of smaller blocking shapes around the foliage to get a less solid blocking shape.
I take it that the OneWayDynamicLighting api in the one click install menu no longer works then?
1632804026

Edited 1632804035
The Aaron
Roll20 Production Team
API Scripter
That doesn't actually create one way dynamic lighting, it creates an invisible token on the other side of a dynamic lighting line when players enter a zone and assigns those players in the zone to control it, which gives them vision from its perspective.
I feel deceived. You figure working in Army Marketing that wouldn't surprise me.
1632836950
The Aaron
Roll20 Production Team
API Scripter
Yeah, sorry about that!  I'm hoping now that we have UDL, they can start advancing the tech on the Dynamic lighting to new and wonderful capabilities.