Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Audio in Harlowe

Hi.

I'm trying customize my audio in Twine 2.0 (Harlowe 1.2.2.).

1- I would like to add a piece of music that always plays in the background even if you change passages. Is that possible?

2- Is there a way to add fades? I find the cuts between passages are particular jarring.

3- Can you add an audio effet when someone clicks on a link that plays even if you transition to another passage?

Cheers

Comments

  • The Harlowe story format does not have any built-in audio related features, it relies on you handling it yourself via either the HTML audio element or using Javascript.
    If you are just starting to create your story then you may want to look at the SugarCube story format which has built-in Audio macros.

    If you want to keep using Harlowe then:

    re: point 1 & 2
    Reading all of the Fading out/Stopping Looped Music in Passage(s) thread may give you an idea about how to use Javascript to do what you wish.

    re: point 3
    Yes, you could use a (link:) macro to display a link and call your audio related Javascript code with its associated hook. Something like the following
    (link: "Next Passage")[
    	<script>... Javascript to play audio goes here ...</script>
    	(goto: "Next Passage")
    ]
    
Sign In or Register to comment.