Howdy, Stranger!

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

Dan Cook's Candy Box example doesn't work after Twine 2.0.6

I've been migrating to Twine 2 and I found an example I really like that emulates Candy Box.

The proofing copy is here: http://videlaisstudios.info/teaching/twine/CandyBox.html

This example works with a looping counter in 2.0.6, but doesn't work in 2.0.7 or 2.0.8. I believe the Harlowe version where it works is 1.0.1. Does anybody have any insight on how you do loops like this in the newest Harlowe?

Comments

  • edited September 2015
    If you are asking about the code in the Earning per second passage then the reason it does not work is because it contains a syntax error, which the older version(s) of Harlowe were letting the Author get away with.

    The syntax error is that there is an illegal space character between the (live: 1s) macro and it's associated hook [], removing this illegal space character results in the code working.
    {|counter>[You have 0 candies]
    (set: $count to 0)
    (live: 1s)[
    (set: $count to it + 1)
    (replace: ?counter)[You have $count candies]
    ]}
    

    p.s. You may want to contact Dan Cook to let him know about the syntax error.
  • That was it! Thanks for the help.

    I've sent some information to him about it too.
Sign In or Register to comment.