Howdy, Stranger!

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

Multicharacter story technical problem

edited July 2015 in Help! with 2.0
Heya!

I'm making a story with two characters that you can swap between. In my init, I've initialized the location of both characters, as well as set the current character's point of view var to true (so that I know which passage/location I need to render):
(set: $a_location to "boat")
(set: $b_location to "boat")
(set: $a_pov to true)
(set: $b_pov to false)
(goto: "main")

My main simply renders the appropriate passage:
(if: $a_pov)[(display: $a_location)]
(if: $b_pov)[(display: $b_location)]

In the "boat" passage, I've got a hook that changes the location variable to "wall":
You're in a boat.
[approach the wall]<move|
(click: ?move)[
	(if: $a_pov)[(set $a_location to "wall")]
	(if: $b_pov)[(set $b_location to "wall")]
	(goto: "main")]
$a_pov[[change to Balter]<b|]
(click: ?b)[
	(set: $a_pov to false)
	(set: $b_pov to true)
	(goto: "main")]
$b_pov[[change to Arun]<a|]
(click: ?a)[
	(set: $b_pov to false)
	(set: $a_pov to true)
	(goto: "main")]

Start point's at init.

When I run this, however, if I click "approach the wall", which should change the current character's location to "wall", main still renders the "boat" location.

What am I doing wrong and how can I get main to display the correct location?

Thanks in advance,
Michael

Comments

  • The two (set:) macros within the first (click:) macro of your boat passage are missing their colons, so Harlowe does not know they are macros and does not do the assignments.
  • Doh! Thanks, greyelf!

    Reminds me of this:

    KEeK4iR.png
Sign In or Register to comment.