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

ChatSetAttr help

So i'm attempting to do something that I would believe would be simple to test out this api !setattr --sel --other_resource|1|1 but it doesn't work and I have no idea why. I did an inspector and verified that the resource is named @{other_resource} in the source viewer <== attempting to change this one The token is selected and putting the above in chat doesn't give an error message but it does make the chat display a blank line.
1632648825

Edited 1632648925
Andreas J.
Forum Champion
Sheet Author
Translator
Have you checked that the token is linked to the sheet? Have you made any other chatsetattr command work? Did you try to use --name Nameofcharacter instead of --sel ? --charid @{target|character_id} should work as an substitute for --sel Check this page if there are any clues to what's going on: <a href="https://wiki.roll20.net/Script:ChatSetAttr" rel="nofollow">https://wiki.roll20.net/Script:ChatSetAttr</a>
Hey, sorry for the super late response but work and life has been crazy busy. Reply in underline below. Andreas J. said: Have you checked that the token is linked to the sheet? yes the token is linked to a character sheet Have you made any other chatsetattr command work? Yes I was able to alter hp just fine, it seems to be just the "other resource" that it is having trouble with Did you try to use --name Nameofcharacter instead of --sel ? Yes I tried using name instead of select but still the issue persist --charid @{target|character_id} should work as an substitute for --sel. I haven't tried this, but I don't think selecting is the issue as other commands work just fine using the --sel parameter Check this page if there are any clues to what's going on: <a href="https://wiki.roll20.net/Script:ChatSetAttr" rel="nofollow">https://wiki.roll20.net/Script:ChatSetAttr</a> . This is what I was using as a guide to find out what the ID of the resource is
1634930968
timmaugh
Pro
API Scripter
Is your sandbox "stale" (a soft crash)? Restart it and refresh the Script page to be sure. Do you have ZeroFrame installed and do NOT have SelectManager installed? Is the attribute really named that? I know you did the inspection, but sometimes it reports as one case (all lowercase), but you have to actually retrieve it with another case (title case). You can try various case arrangements, and/or you could install InsertArg and run !xray to walk the character sheet and see what the attribute reports as.