Linking or merging stories

Please specify version and format if asking for help, or apply optional tags above:
Twine Version: 2.3.5
Story Format: Sugarcube 2.30.0

I’ve been working on a story for a while and it has 480 passages with 64k words which is mostly just the outline. (Want a way to feel like something will never get finished? That’s taken me about 2 years.) It’s got several what I think of as “zones” different areas to explore, and was starting to feel unwieldy to work in directly. So, when I started a new zone that I wasn’t quite sure how I wanted to make work, I started a new story to make navigation and tracking easier, copying just the pieces of functional underlying code I had to (side bar, etc). That one is now at 160 passages and 12.5k words (I estimate I’m less than a quarter finished on this component) and I’m realizing that I need to figure out how to either merge this document into the other one or to make cross-links between the two.

Building links seems easy enough if there was a 1:1 in/out. But there is significant non-linear connectivity. It also won’t let any data be carried over between the two which isn’t an issue now but might become one later.

I’d prefer to be able to merge, but the only tool I’ve found is… not as user friendly as Twine. I’ve done passage-by-passage copy pastes on a smaller scale, but this is reaching the point of feeling a little ridiculous and I’m not quite ready to make that merge yet.

Suggestions? Comments? Thoughts? Am I just whining and need to break out the scissors and glue?

You might be able to just open up the HTML files in Notepad++ and just copy stuff over that way, since you can do a lot at once. If it’s hard to figure out, you might have to use the other tool (which I assume is Twee?)

I wouldn’t recommend Brian’s method, since there are too many ways copying and pasting HTML could break everything.

If none of the passage names in the two stories are the same and any there aren’t any problems with variables shared between them, then the simplest method would be to output both files as a Twee format text file using Tweego, merge the text files in a good text editor (like Notepad++), save that as a new Twee file, and then compile that into an HTML file using Tweego, which you could then import into Twine if you wanted to (though I’d change the story name and IFID first, so it isn’t a duplicate of any stories you already have in Twine).

However, if any passages share names between your two Twine stories or any variables are used differently between the two, you’ll need to fix those problems first.

That’s really the only good solution if you want to combine them into a single HTML file.

Once you’ve done that, then you’ll need to go in and correct any links between the two.

Hope that helps! :slight_smile:

2 Likes

You’ve effectively summarized what I had found.

I think I’ve done a good job of not replicating any names (that aren’t deliberately set aside as replicated underlaying functions to be deleted before merging). The biggest thing I’m worried about using text editors is going to be the position values and not ending up with a big train wreck of the two sections trying to superimpose on each other.

After a couple weird glitches I’ve taken to doing exports fairly regularly to keep snapshots. So, I’ll make sure to do that and even if I botch something I can just roll back.

Anyway, thanks for the feedback.