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

Powercards + Dungeon Draw crashes API

Anyone else having the problem where Power Cards works fine and Dungeon Draw works fine but putting them together crashes the API? I kinda need Power Cards for my monsters to make running games more efficient but I would love to also be able to use Dungeon Draw to it's fullest.
1435984340

Edited 1435984347
I pretty much only use my own scripts and do not do any compatibility testing. Especially when it comes to massive scripts like Dungeon Draw. If you could, post the error message that comes up when it crashes for you.
1436005237
The Aaron
Pro
API Scripter
What is the error you get?
Unexpected Token s
1436016014

Edited 1436016234
Hi, I think I've found the problem in this - I was going to make a topic for this exact bug that I spent half an hour trying to figure out what was crashing my scripts, and I saw this. Grabbed a copy of Power Cards and Dungeon Draw, set them up in a very specific layout, and I got the error... or at least, one close, 'Unexpected Token )' Long story short, I think the problem lies in the API's automatic semicolon insertion between scripts. I'm not sure exactly what's going on, but it seems to occur when any script that does not end in a semicolon precedes other scripts. In both the cases of my scripts, and PowerCards+DungeonDraw, I've been able to get them working by putting a semicolon at the very, very end of a script. In the case of PowerCards, it had to be past the 'end functions' comment, which was a bit odd. Anyway, hopefully this fixes it for you, and hopefully one of the devs can fix this on the back end so I can go back to being lazy with semicolons.
Maybe adding a semi-colon at the end of each function would work at preventing this error.
that appears to have fixed it, thanks
1436165708
The Aaron
Roll20 Production Team
API Scripter
Probably there is no carriage return after the final comment in powercards, leading to the comment commenting out the beginning of the next script.