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

[Question] Getting tokens that represent a character

Is it possible to get the tokens that represent a character? It seems like the character object does not have anything similar to the "represents" property of tokens. And some follow-up questions: Is there a way to listen for the change of a specific attribute or attribute changes overall? Or would I need to listen to any changes of the character. Now the background: I consider linking attributes that take small numbers to markers on the tokens, e.g. a character can have at most three wounds, if the Wounds attribute in the character sheet changes, I update the tokens to reflect the change by adding or removing markers. It looks like it would work the other way around, if the status markers change, I can update a specified attribute. That is a start, but if it would work both ways would be even nicer. Or course, I could use bars but those are already used to track other things.
Use a findObjs look with .get("represents") on tokens.