link-repeat adds rather than replacing
Created originally on Bitbucket by eveames (Emily Eames)
According to the documentation, link-repeat "creates a link which is visually indistinguishable from normal passage links. Each time the link is clicked, the text and macros printed in the previous run are removed and replaced."
I'm finding that each click re-runs the text and macros without replacing (sample below). It would be great to be able to get the replace behavior.
This code
#!
(link-repeat: "Click when ready")[(set: _answer1 to (prompt: "Enter your answer, with the correct unit abbreviation, such as '10 m/s^2':",""))(set: $tries to $tries + 1)You have tried $tries times.
(if: _answer1 is '450 J')[[[Correct!|microscale intro]]]
(else-if: _answer1 is not '450 J' and $tries < 3)[Try again!]
(else:)[]]
produces the following when clicked 3 times: Click when readyYou have tried 1 times. Try again! You have tried 2 times. Try again! You have tried 3 times. Correct!
I was hoping for (and expecting, if I read the docs right), that if I made 3 attempts, the last one correct, I'd get: Click when ready. You have tried 3 times. Correct!
Thanks for all your work on Harlowe, and I'm sorry if I've misunderstood the intent! I'm new to this.