0 votes
by (710 points)

I've decided to try using TweeGo for my next project, using Notepad++ as an editor. I'm using the latest version of the SugarCube story format.

Is there a Notepad++ language definition for Twine/SugarCube anywhere, so I can get my code appropriately coloured? There was one mentioned in the old Twine forum but the dropbox link in that post is dead.

If there isn't one I'll try making my own, but I thought I'd check first.

1 Answer

0 votes
by (64.2k points)
selected by
Best answer

I don't recall if I have Claretta's contact info, however, if I do I'll see if she still has a copy of her Notepad++ language file.  Beyond that one, a quick Google turned up a different, incomplete, Notepad++ language file for SugarCube, which may be able to serve as a starting point.

Tangentially, there's also a SugarCube language plugin for the Atom editor.

PS: I cannot personally vouch for any of these files.

PPS: If someone comes up with a complete Notepad++ language file and wants me to save it for posterity, I'm willing to host it on SugarCube's website.

by (710 points)
Thank you! I've downloaded the partial SugarCube language you linked to so I'll use that as a starting point. If I create a complete language definition I'll let you know so you can host it.
by (710 points)

I've made my own language definition.

I'm hosting it on my own site and I'm happy for people to get it from there, but you'd like to also host it on the SugarCube page then that might make it easier for people to find.

by (64.2k points)

Just looking at the XML—I don't have Notepad++ installed at the moment—there seem to be an issue with the JavaScript strict inequality/non-identity operator.  In the file it's defined as !=== when it should be !== —basically, you gave it an extra equal sign.

I'll reinstall Notepad++ and take a more in-depth look at it later.

by (710 points)
Thank you! I've fixed that now.

Also: I only included JavaScript operators, not TwineScript ones, because I didn't want the words "is", "not" etc. to be highlighted when they appeared in normal text.
Welcome to Twine Q&A, where you can ask questions and receive answers from other members of the community.

You can also find hints and information on Twine on the official wiki and the old forums archive.

See a spam question? Flag it instead of downvoting. A question flagged enough times will automatically be hidden while moderators review it.