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

Select Option for fillable Text

Is there a way to have a select option be fillable text? (Examp Pic Below)Example i have a drop down to select a saving throw stat for an attack that is based off a stat, but if the player has a item that has a flat difficulty bases that is not from a players stat. like a throwable potion that explodes. the difficulty for that is not based on the characters Stats. is there a way to select a option where the player can type the DC value?
1689253785

Edited 1689258814
GiGs
Pro
Sheet Author
API Scripter
It's not possible with a select. But you can use an optlist with an input to get this effect. The list is unique to each character sheet. You can create an optlist which has the default options in each character, then players can add their own which then show up in the list for them. You need to be using modern CSE code (not legacy code). If you just want the option of players choosing a different stat, the stats will be predefined so you could use a select for that. Likewise if the range of DCs is fixed, it's always one of a preset list of numbers, you can do it with a select - you just have to include every one in the select.
Well pooh thats what i thought but i was just checking. thanks  What is modern CSE?
1689258623

Edited 1689258720
GiGs
Pro
Sheet Author
API Scripter
Character Sheet Enhancement. To answer specifically: some time ago, Roll20 added some features to the HTML and CSS they supported and allowed, and that is CSS. But older code remained supported and is called legacy code. The two main methods to know which you are using: when creating a sheet, do you have to put "legacy": true anywhere, or tick a checkbox marked Legacy Santisation. When writing code, do you ever prefix CSS classes with sheet-. If the answer to either of these questions is no, or simple bewilderment, you are not using legacy code. You can't use that now withotu a deliberate intention to do so - it's there just for older sheets that were written before CSE was introduced. You can learn more here: <a href="https://wiki.roll20.net/Character_Sheet_Enhancement" rel="nofollow">https://wiki.roll20.net/Character_Sheet_Enhancement</a>
Thank you ill check that out