0 votes
by (270 points)
The default text is 'Double-click this passage to edit it' - I'd like to change that so that whenever I create a new passage, I don't have to type out all of my macros that set up the scene. Note that the parameters will change almost every passage.

2 Answers

+1 vote
by (159k points)
selected by
Best answer

There is no built-in option for changing the default Passage Template used by the +Passage option.

You could try using one of the Passage Events & Task Objects like suggested by @idling, however that may not solve your issue if the scene initialisation code changes with every Passage.

by (63.1k points)
I second this and idling's answer. It seems like you need to set up some boiler plate or reuse code. It's much easier / better to do that through widgets, <<include>>, custom functions or macros, special passages, task objects, or events. There are many features that help with code re-use in SugarCube.
by (270 points)
Like I said, the parameters will change in most passages, so it's not an issue of re-using code. No problem though, I just wanted to know if it was possible.
+1 vote
by (23.6k points)

If you have things you want to be executed in every passage, you can out make use of the special Passages like PassageReady. Read more about those here.

This site has been placed in read-only mode. Please use the Interactive Fiction Community Forum instead.