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

[API] TokenCondition - ability to set layer of condition

Has anyone found a way to have the Conditions to move to another layer once linked.   I am thinking to keep the Token layer clean of extra tokens.  I know this would require all conditions to be bigger then the tokens to be visible.  I can manually move them to the map layer once applied but that is an extra step.  I was going to look at the code to try to edit myself but figured if someone else has done it already why redo the work.  Also May be something other would want added to the main script.    This will become a even better option once the Weather overlay layer is added to roll20 as putting the conditions on that layer would be a big win for this API.
1654054907
Victor B.
Pro
Sheet Author
API Scripter
What are you trying to use this for?  
Trying to get the Effects to show on the map layer or have the torch on the Lighting layer.  Having them on the same layer causes my players to get confused.  If I Manually move the condition it works but it requires another step.
1654059473
Victor B.
Pro
Sheet Author
API Scripter
Token Condition isn't about effects.  It's about tying a torch or mount to a token and have that torch or mount follow the character underneath your main token.  The torch can be configed to be tiny upper right on the token with dynamic lighting setup for it.  Sweet tool for these sort of things.  I think you are thinking that tokencondition is something diff?   And what effects?  If there's fireballs or whatever I drag some spell caster templates onto map.  Not following what you are after?  
1654059853

Edited 1654059921
Victor B.
Pro
Sheet Author
API Scripter
If you have dynamic light setup correctly, you don't need to push the torch to dynamic lighting layer.  It happens when you pull the torch onto the token layer.  I think you need to read up some more on dynamic lighting.  Any token on token layer can have dynamic lighting setup to provide light.  Doesn't require the dynamic lighting layer
Spell effects that follow the token. Just like the sample Spirit guardians or some of the effects from guardian of nature or other following effects.  My main issue is that the condition token is on the object layer. Using Animated condition circles would also be good to not have on the token layer.
1654060434

Edited 1654060659
Victor B.
Pro
Sheet Author
API Scripter
You are expecting a movie.  Not going to get it.  You could build an API to do that.  Welcome it.  I personally don't want it.  Everyone here contributes to Roll20 for free. You aren't going to get exactly what you want.  Fill the gaps.  
1654060572

Edited 1654060773
Victor B.
Pro
Sheet Author
API Scripter
But spell "animations" which is far cry from your original post I do believe is out there someone in Roll20verse.  Your expectations aren't in sync with TokenCondtition
1654061412
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
For torches, I would suggest forgoing TokenCondition. I simply have the character token emit the light and apply a torch token marker. What you are asking could be done (having the other token follow the original, but on a different layer). The Bump script does this, for instance. You are likely to run into some issues with token behaviors that change depending on layer. GM layer tokens don't affect dynamic lighting, and a lot of scripts like FX generators assume a default layer). It can be done, but it would likely require a non-trivial amount of tweaking to more than one script.
1654061586
Victor B.
Pro
Sheet Author
API Scripter
Keith I use token condition for torches and mounts and works great.  Torches provide lighting.  Mounts are for visuals.  Easy.  There is something out there Keith that show animated spells, I just don't remember what it is.  This is what he's looking for.  
1654062737
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Ah, I missed that post in the middle. I was thinking Effects as in "FX". I can see value for having Spirit Guardians follow a token on a non-selectable layer for example. But I'd be far more likely to use an aura for that. 
1654062868

Edited 1654062876
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Hmm. I just ran a quick test. If you assign a token condition to follow  token, it continues to do so, even if you move the condition to another layer. A carefully design condition could appear in the corner area not obscured by a round token, or in the case of something like spirit guardians, would probably be best if left behind the token on the map layer anyway. I.e. It looks like Token Condition already does this?
1654062998
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
More testing. You'll want to define a condition as a "Condition" rather than a "Mount" if you want it to appear in front of the map on the map layer.
Yea it works but I would need to move the token after the link is made.  What I was thinking was adding layer:map   to the settings of the condition when setting it up.  So if I want one to be on the token layer I just leave that option off or for the lighting layer I add  layer:wall    This would make the associated token move to a layer once it is linked if the setting is used.  For that matter if any additional layers are added it is ready to use them.  
1654063878
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Yeah, but it doesn't seem that involved to right click and change the layer. Even if you want players to have that ability, you can give the condition a token action to move it to the proper layer. It's one extra click, but it does what you want without modifying the script.
Just trying to automate as much as possible the extra step will work for now. I can also string the move into the setting macro I was working on.   Thanks
1654065339
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Makes sense. By the time I had made the gif, you had already posted your requirement, but dangit, I went to the trouble of making it! :D Oh well, it's there if anyone else following along needs to know how to do it.
1654095224
The Aaron
Roll20 Production Team
API Scripter
Totally possible and even pretty easy to add.  The biggest challenge will be that then only the GM will be able to remove the condition, whereas normally the player can just delete the token they dragged in.  I can probably add an interface to query what conditions are on a token with a handy dandy change layer or delete button. I'll see if I can work that in somewhere...
wouldnt marching order work for this - attach the spiritual guardian sheet / token to the player??