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

sudden "SyntaxError" occurs

Hi, can somebody help me solve this problem? I've been using same api script+html+css custom sheet set for 2years with no problem, and suddenly syntax error messages came out since last 2weeks. <a href="https://gist.github.com/MeowLKW/28b3f372740b73c56c666e82ba7a7bdc" rel="nofollow">https://gist.github.com/MeowLKW/28b3f372740b73c56c666e82ba7a7bdc</a> as you see api script has not changed for years so maybe i guess there's problem on html or css but I don't know what exactly I have to do... and this link is my html and css files FYI. Here's error messages below. SyntaxError: Expected "(", ".", "[", "abs(", "ceil(", "d", "floor(", "round(", "t", "{", [ |\t], [+|\-], [+|\-|*|\/|%] or [0-9] but ")" found.
1619963114
The Aaron
Roll20 Production Team
API Scripter
Is that the only script you have installed? &nbsp;What command are you running when the error occurs?
Hi, Aaron! Yes. 1 api, html and css for custom sheet are everything I installed.&nbsp; Every dice roll I made with the button on image causes same errors.
1620058312
The Aaron
Roll20 Production Team
API Scripter
Click in the chat after clicking one of those buttons, then push the up arrow to load the previous command.&nbsp; Copy that and paste it here so we can see what it's sending to chat.
&amp;{template:dx3rd} {{name=@{Johnny Doe|character_name} | @{Johnny Doe|knw_01}}} {{roll=@{Johnny Doe|menadd}dx@{Johnny Doe|men_crit}@{Johnny Doe|knw_01_plus}@{Johnny Doe|knw_01_lv} | [roll](!sr @{Johnny Doe|menadd}dx@{Johnny Doe|men_crit}@{Johnny Doe|knw_01_plus}@{Johnny Doe|knw_01_lv})}} Hi, Aaron! Here's the command! and I found if I input any whole numbers in HP or Corr. tap, chr sheet works well without errors. Johnny Doe's sheet with no numbers in the marked area causes syntaxerrors and John Doe's sheet with any numbers in the marked area works well. Here's John's command FYI. &amp;{template:dx3rd} {{name=@{John Doe|character_name} | @{John Doe|knw_01}}} {{roll=@{John Doe|menadd}dx@{John Doe|men_crit}@{John Doe|knw_01_plus}@{John Doe|knw_01_lv} | [roll](!sr @{John Doe|menadd}dx@{John Doe|men_crit}@{John Doe|knw_01_plus}@{John Doe|knw_01_lv})}}
1620131622
The Aaron
Roll20 Production Team
API Scripter
So, it sounds like the character sheet needs to be initializing those attributes to 0. &nbsp;Right now when they are blank, it's causing an error because places in the formula where it expects a number are getting nothing leading to something like (3+).&nbsp; The easiest fix would be for you to make sure there aren't any blank entries.&nbsp;