I created a SugarCube Linting/Devtool that helps you find bugs in your game

Hi,

I recently made a tool that helps you automatically find bugs in SugarCube games. Someone suggested I should share it here also.

What does this tool do?

  • It detects all widgets and macros in your game
  • shows an error when you <<somethingthatdoesntexist>>
  • shows an error if you have a macro or widget that should be closed but wasn’t, or vise versa
  • shows an error if you have widgets in a passage that doesn’t have a widget tag
  • validates your if structures and shows errors if you’re missing opening or closing tags, or if for example an elseif comes after an else
  • Shows errors if there isnt the same number of << as >> in a passage
  • Shows warnings for uneven numbers of double-quotes in a passage
  • shows warnings for deprecated syntax

Find it here:
https://goctionni.github.io/SugarValidator/

Did this help? Do you have suggestions? Did you find any bugs in this tool? Please let me know.

1 Like

Yeah, I definitely recommend this for Twine/SugarCube developers.

FYI - In this forum you need to put macros inside a “preformatted text” marker (the </> button), otherwise it eats the content of the macro.

Fixed it, thanks for the heads up

Great work.

Does your site persist (permanently or temporarily) the story HTML file it uploads? If it does then you may want to state that fact and make it clear how long that persistence is for.

Also I see you are using Github as a hoster, you make need to check (and inform the end-user) of any limitations (bandwidth, content types, etc…) that site has…

It does not, in fact the file is not at all uploaded to the server. The file-validation happens completely client-side.