3 choices in a link?

Please specify version and format if asking for help, or apply optional tags above:
Twine Version: 2.3.14
Story Format: Harlowe 3.2.2.

Hello everyone !

Is it possible to put 3 choices in alink somehow ? With If and Else ?
I tried :

This is the text. Here is a door for example.

(if: $PlayerHasApple is true)[ [[You go in]] ](if: $PlayerHasBread is true)[ [[You go in->You go in2]] ] (else:) [ [[You go in>You go in3]] ]

i put two IFs in the command but its not working. If player has the apple he has two choices visible. Its important that he sees the same answer every time, but gets to a different place, based on what kind of item he has. So is it possible to put 3 choices in one line ?

Thank you for your help ! Andrew

“else-if” is what you want for more than 2 choices.

(if: something is true)[do this]
(else-if: some other thing is true)[do that]
(else:)[do something else]

You can have as many "else-if"s as you want in the list: Twine will simply work through them in order and do the first one that passes the test. If none of the tests work then it will do the “else” clause.

The “else” clause works as a “catch all” response. If you only want something to happen as a result of specific tests, it’s OK to leave it out. That’s the equivalent of saying:

(else:)[ ]
1 Like

Thank you very much !

1 Like