Skip to content
This repository has been archived by the owner on Aug 18, 2021. It is now read-only.

starts incorrectly #2

Closed
lucidrapture opened this issue Jul 30, 2017 · 1 comment
Closed

starts incorrectly #2

lucidrapture opened this issue Jul 30, 2017 · 1 comment

Comments

@lucidrapture
Copy link

yarn

Here is a test file I made and saved as .json

When I open the file inside YarnWeaver, the text windows "hello" followed by "bye" are displayed, and then the next click presents the choice while on "bye", like this:
yarn2

if i understand correctly the choice should be present on the first window?

@radiatoryang
Copy link
Owner

radiatoryang commented Jul 30, 2017

This is an intentional YarnSpinner implementation decision, see their Usage documentation: "When all of the lines in a node have been displayed, the dialogue system gives your game the list of available options. You then let the user choose an option, and then continue loading lines of dialogue, one at a time."

I understand it'll seem unintuitive if you're coming from Twine, but I think it's the result of Yarn's purpose as a dialogue system. By waiting until the end of a passage before displaying choices, you could, for example, "accumulate" possible choices based on scripting logic.

I think you have two options: (1) separate your passages more, and try not to do so much in one passage, or (2) if you want to offer choices in the middle of a passage, you should use the "shortcut choice" syntax instead, where you indent and type "->" for each choice... here's the example from their documentation:

Bob: What would you like?
-> A burger. <<if $money >= 5>>
	Bob: Nice. Enjoy!
-> A soda. <<if $money >= 2>>
	Bob: Yum!
-> Nothing.
Bob: Thanks for coming!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants