+1 vote
by (160 points)
edited by
(Harlowe v1.2.4)

Can someone let me know how this can be possible?

Instead of navigating to a complete different page/thread, I want the new phrase to just display below the existing phrase that user resides. (almost like a thread). The new phrase will be dependant on the option/link that user clicked on in the original phrase.

I am using this for an educational tool.

Thank you in advance.

2 Answers

0 votes
by (2.2k points)

You can use the History and Passage macros to go about these things I think.

By using the history like so

(if: (history:) contains "passage1")[this will only show if they've visited the named passage]

And passage like this, I think

(passage: "passage2")

Will show whatever is in passage2

I hope this answers your question

by (160 points)
This is along the lines of what I want. The history macro just shows the title of the phrases, how can I show everything that's in the phrase box as well?

The point is to show and allow a student to be able to follow a concept & see how it connects to another concept. Almost like clicking your way through a concept map, but actually being able to scroll-up and see how you got there.

Thank you!
by (2.2k points)
edited by

That's where you'd use the passage macro, it shows whatever text is in the named passage. I've never used it myself, but I haves to use it so I've looked into it, so I hope it works how I've stated.

(print: (passage: "passage2")'s source)


(display: "passage2")

both work the same apparently, one just uses the passage macro I talked about

by (160 points)

so can i do

(for: each (history:)) [(display: "passage2")]

- for each item in the history array, display the contents of the passage.

by (2.2k points)

So, I don't yet know how to use for macros as I'm really new, like yesterday I signed up, so I changed the first macro to an if since I know how to use that one.

(if: (history:) contains "passage2")[(print: (passage: "passage2"))]

this is what I used, when using history you need a contains modifier so it knows what it's looking for.

I couldn't get the display to work, it just displayed a link to the passage. I don't know why that is, but I'm new to this so maybe I missed something in the explanation.

I got some weird errors with this in which it printed, but, technically, it worked. 


sourcethis is passage 2

I don't exactly know what happened here, but hopefully someone sees this and can clear it up, if not, you can make another question about the error if you can't get around it

0 votes
by (159k points)

You need to state the name and full version number of the Story Format you are using, as answers can be different for each one. I will assume you are using the Twine 2 default story format which is Harlowe v1.2.4

If I understand your question correctly you are asking how to implement a Chat/Message like dialogue flow, if this is correct then the Chat like Conversations for Harlowe thread on the Old Forums may help you.

note: Because this Q/A site is still new I suggest also searching the Old Forums when looking for potential solutions, as there is years worth of answers over there.