Twine - harlowe: Getting a message to appear and disappear after a second

0 votes
asked 5 days ago by valdavaux (250 points)
Using online editor of twine, Harlowe (not sure where I check the version...there's no "about")

So I'm trying to figure out a way when someone clicks a link, a message would appear for a few seconds then disappear. I'm trying to play with the "live" function but my solutions are really awkward. How would you approach it?

1 Answer

0 votes
answered 5 days ago by greyelf (27,360 points)

You can used the Formats option on the Story List screen to see a list of the story formats (and their versions) currently installed in the Twine 2 are running, and you can use the Change Story Format option on a particular story project's Story Map screen to see which story format (and it's version) is currently selected for that story project. I will assume you are using the default version of Harlowe, which is v1.2.4

You don't state how you are displaying the message just what action causes it to appear, so I am going to assume you are using a combination of a named hook and the (replace:) macro to display the message.

The following uses the (live:) macro to delay the execution of a (replace:) macro which updates the named hook with an empty value, it also uses the (stop:) macro to stop the (live:) macro after it has been triggered once.

(link: "Show Message")[
	(replace: ?messages)[Hi there!]
	(live: 2s)[
		(replace: ?messages)[]



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.