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

Every Sheet Author Should Read This

1693516102

Edited 1693516978
GiGs
Pro
Sheet Author
API Scripter
I just found what appears to be an error in the official documentation for useroptions. According to the wiki page , when entering a default value for useroptions (Default Sheet Settings), several options uses default and others use value . Text, Number, and Checkbox use value: for entering default values. Others use default . Based on my testing, you should always use default . value is not recognised, but default is recognised. This means every example of the wiki page is in error. Were other people aware of this? It's news to me. NB: Checkbox is a special case. It does use value.
1693519043

Edited 1693519128
vÍnce
Pro
Sheet Author
Good to know. I often refer to other sheet code on the repo when I'm not sure about something.  I think some of the wiki editing/update was probably done after I had already created my sheet.json files. So no need to refer. Your post got me second guessing though.  lol  Just did a quick check and I personally haven't used type: text or number . Lots of checkbox and select though...  and these appear to have the appropriate keys (ie value for checkbox and default for select ).
1693519359

Edited 1693519468
GiGs
Pro
Sheet Author
API Scripter
It looks like only Text and Number have changed. I think it's actually a good change - it harmonises across the settings. All use default now, instead of some using value and some using default). Checkboxes are different - they still use value, but you aren't setting a default value there, so it means something different (you aresetting what the value will be if you check it). The issue IMO is that there was no announcement about this change that I'm aware of, and both the wiki and the official help documentation are now incorrect. (Official help: <a href="https://help.roll20.net/hc/en-us/articles/360041542554-Default-Sheet-Settings" rel="nofollow">https://help.roll20.net/hc/en-us/articles/360041542554-Default-Sheet-Settings</a> ). It also means that any sheets on the github that use text and number are probably now not working properly for new characters. Aleady created characters will be fine.