This is how previous() is used, and it does work as intended: [[Back|previous()]] or <<set $foo = previous()>>. I'm posting real quick from school, but I believe one can also use <<back>> to create a link that will display the last passage.
You can also set the name of passages to a variable like so: <<set $foo = "Name of Passage">>, or use <<set $foo = passage()>> to set it to the current passage's title.
After doing so, you can add the variable to a link or macro like this: [[Link|$foo]] or <<display $foo>>.
Again, I don't have twine, but to force the last passage to display, you might try this and see what happens:
Like I explained in my post, but then neglected to put "display" in my code, if you <<set $foo = previous()>> then <<display $foo>>, I'm fairly certain <<display $foo>> will display the last-visited passage.
Are you using Twine 1.4.x? The previous() function isn't available in 1.3.x.
Copy and paste the code you're using or post a TWS or HTML file and we'll take a look.
Comments
You can also set the name of passages to a variable like so: <<set $foo = "Name of Passage">>, or use <<set $foo = passage()>> to set it to the current passage's title.
After doing so, you can add the variable to a link or macro like this: [[Link|$foo]] or <<display $foo>>.
Again, I don't have twine, but to force the last passage to display, you might try this and see what happens: Here are a couple links to read:
http://twinery.org/wiki/function
http://twinery.org/wiki/macro
Are you using Twine 1.4.x? The previous() function isn't available in 1.3.x.
Copy and paste the code you're using or post a TWS or HTML file and we'll take a look.
Based solely on the "Twine 2 Alpha" in the subject, I'm guessing that they're using Twine 2, not Twine 1.x.
Just tested the following in Twine 2 and it works the same as in the other versions:
Yes, some macro works. But not previous()