Essentially, I want to achieve something like this:
However, it is my understanding that until the passage exits, the variable "secondPerson" is treated as a reference to "activePerson" instead of its own object, which leads me to believe that I'm doing it wrong.
So how do I copy an object properly within a single passage?
where the print statement prints "David" and not "Jane".<<set $activePerson to { name : "David" }>>
<<set $secondPerson to $activePerson>>
<<set $activePerson.name to "Jane">>
<<print $secondPerson.name>>
However, it is my understanding that until the passage exits, the variable "secondPerson" is treated as a reference to "activePerson" instead of its own object, which leads me to believe that I'm doing it wrong.
So how do I copy an object properly within a single passage?