Choices within labels

Posted: 12 Jun 2022 22:56
by BWLGeorge

Hey all, anybody know how to have choices within labels after a choice brings you to that label in the same script? For example let's say I did:

@choice "Pick pencil" goto .pencil
@choice "Pick apple" goto .apple

pencil

You pick up the pencil
#apple
You pick up the apple

And that works all fine and well and good, but when I try to put choices within those labels, like so:

pencil

You pick up the pencil
@choice "throw pencil" .throw
@choice "write with pencil" .write
#throw
You throw the pencil
#write
You write your name

The second choices end up displaying along with the original choice list between the pencil and apple instead of when they've been placed within the label. Do I just have to goto new scripts or is there a way to pull this off within one script?


Re: Choices within labels

Posted: 13 Jun 2022 07:57
by idaot

I'm not sure what you mean by pulling it off within one script, commands occupy one line most of the time like in both of the examples you provided. If you mean that you want to skip writing goto in @choice lines, then that's not possible. Commands can only have one (optional) nameless parameter and for @choice it's choiceSummary (https://naninovel.com/api/#choice) while the other parameters have to be explicitly stated in order to work.


Re: Choices within labels

Posted: 25 Aug 2022 17:36
by gradstein

I feel like I do this a lot and don't see the nested choices showing up with the originals. Are you forgetting to put an @stop after the choice?