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

[Help} New Exhaustion Tracking In 5th Edition OGL Doesn't Respond Correctly to API

I am trying to track exhaustion on my PCs. When I use the API to add or remove a level of exhaustion, the number increases or decreases, but the effect information does not change. Here are a couple of screen caps to clarify. Here I manually change the exhaustion level. The effects are listed to the right of the exhaustion value. When I add the exhaustion level through the API it does not include the same information. The first API I tried to use was the CharSetAttr command:  !modbattr --modb --name Example Character --exhaustion_level|+1 . It does successfully increase the level, but there is no response from the effects field. I did read a comment that The Aaron made about a similar issue, where he mentioned that certain functions only respond to a manual event rather than one triggered by the API. This gave me the idea to set the exhaustion level to bar3 and use TokenMod. The problem is that the effects field does not even respond to a manual entry via adding or subtracting into the bar3 bubble. I was wondering if anyone has experienced this, and if they have found a solution. Is there a way I can work around this? It would be cool to see this function become part of the 5th Edition OGL Companion script. Thank you, Tim
1555117664
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
Hmm, weird. It certainly should work. I went and tested on a fresh game. Using the command  !setattr --name Test --exhaustion_level|3  I had it working. Then I tried  !setattr --name --mod Test --exhaustion_level|1 , and it didn't just not work, it reset the display to as if there wasn't any exhaustion. After that point, I couldn't get it to work again on any character. So the issue certainly isn't a problem with the sheet not updating from API triggered events, it's that something is going wrong with the setting. Of course, now I can't get it to work properly even on another new fresh game, but it does reset the exhaustion display to base state when you use the API to change the exhuastion level. This is either a bug in the character sheet, or a bug in CSA. I think the character sheet is more likely because of how the API interfaces with the sheets, but could certainly be either one.
Thank you for the fast response. I feel better knowing that it wasn't just me. Should I submit a bug report or something along those lines. I have only been playing with the scripts for a couple of weeks so I am not sure of the SOPs.
1555119987
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
I've found the error, the problem is with an event object that character sheets rely on. I'll submit the bug report since I've got the info.
Awesome. Thank you for your help.