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 .
×

Show as token action

Hi, I've been using the custom character sheet mode for my campaign and I'm trying to configure it to display token actions, just like in the attributes and skills tab. Does anyone know how I can add this feature to my character sheet?
1773374521
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
There is an html property that adds it, although I can't remember what it is and can't find the documentation. However, I would recommend not using it because it cannot be made dynamic. The buttons you denote as token actions will all be token actions, always. This doesn't seem like a big issue, but as soon as you put it on a button in a repeating section you wind up with your token action bar becoming too unwieldly. I would recommend creating a chat menu in your sheet instead that can be used to call the actions you want and then you just have to manually put a button call in your custom abilities for the chat menu button.
1773379932
vÍnce
Pro
Sheet Author
That took me way too long to find; <a href="https://wiki.roll20.net/Button#Token_Action" rel="nofollow">https://wiki.roll20.net/Button#Token_Action</a> BUT I agree with Scott.&nbsp; People tend to not like token buttons that they didn't create and that they cannot edit/delete. YMMV
1773411332
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
Heh, thanks Vince. I knew the documentation was somewhere.
It seems that it didn't work. If I show you the spreadsheet I made, could you give me some help?
1773455676
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
spreadsheet? or custom character sheet?
custom character sheet
1773504210
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
yeah, go ahead and share your code for the relevant section.
Here, you can only share text and images. Is there another way to do this?
1773598784

Edited 1773598942
vÍnce
Pro
Sheet Author
You can post code to the forums, but it should be a simplified example of the problem,&nbsp; if possible. ie I wouldn't try posting 1K+ lines of code here.&nbsp; ;-)&nbsp; &nbsp;Use the editors built-in code formatting option as well (see first top menu option in the editor).&nbsp; Otherwise, you'll need to share an external link to the code.&nbsp; Perhaps an alternate test branch, gist, pastebin, etc.&nbsp; Again, a smaller focused bit of the code is preferred if possible.
look here please&nbsp;&nbsp; <a href="https://drive.google.com/file/d/1sqK1c6lr55YKIdtyJtyq2d-PYYQysMhL/view?usp=sharing" rel="nofollow">https://drive.google.com/file/d/1sqK1c6lr55YKIdtyJtyq2d-PYYQysMhL/view?usp=sharing</a>
1773876787
vÍnce
Pro
Sheet Author
Thanks for posting the code.&nbsp; Given there's 6700+ lines of code... ;-)&nbsp; Can you point out one example in the code where you want to create a token action?&nbsp; Have you tried simply including the "tokenaction" class on a button?&nbsp; What happens? FYI: roll20 has a rather proprietary environment.&nbsp; Linking to an external style sheet, wrapping in html and body, etc. are not required and are ignored by the VTT.&nbsp; Just mentioning it.&nbsp; Not sure if would actually have any bearing on your sheet development.