How do I debug in Quest?

0 votes
67 views
asked Mar 31 in Authoring by AndrewS (250 points)
edited Mar 31 by AndrewS

I'd be interested in reading about basic debugging techniques beyond just throwing in text you need to remove later so the player doesn't see it. Because debugging is one of those 5 dollar words that are not so bad once you know a few tricks.

Is there a parser command authors can use in a debug build? Is there something in Quest source that may say "print to debug" but not "print?"

2 Answers

+2 votes
answered Apr 6 by jaynabonne (141 points)

There is a built-in Log command in Quest, which writes to a log separate from the normal text output the player sees. You can access the log by clicking the Log button or pressing F11 while playing a game. If you add this command to the "enter" script for a room:

Log("Entered room")

then you will see this in the log:

06/04/2015 21:10:06 Entered room

The Debugger allows you to view objects, exits, command, turn script, etc along with all of their attributes, dynamically as the game progresses. It's handy especially if you're using a number of state variables (flags, etc.) and wish to see what the current state of them is. The only problem I have had with the debugger is that, with scripts touching a lot of objects and attributes, there can be a noticeable game slowdown if the Debugger window is open.

0 votes
answered Mar 31 by hegemonkhan (161 points)

I'm new to coding (been learning to code using quest), so I'm not that familiar with all the ways~tricks of debugging and etc, but quest does have a 'debugger' menu option (at the bar at the top during game play mode), but I've not played around with it, so I'm not sure what it does and doesn't do.

Others, who're more knowledgeable in coding will give a much better answer on what quest can do in debugging.

This site is now closed.
As of 1st November 2015, this site is a read-only archive. For more information see the intfiction forum post

Welcome to IF Answers, a site for questions and answers about Interactive Fiction.

Technical questions about interactive fiction development tools such as Inform, Twine, Quest, QuestKit, Squiffy, Adrift, TADS etc. are all on-topic here.

Non-technical questions about interactive fiction are also on-topic. These questions could be about general IF design, specific games, entering the IF Comp etc.
...