[Solved] How can I iterate through a list?

I’d like to make a list of narration where a new piece of text appears once Label1 is clicked. Currently nothing happens when I click label 1. I’d like it so that for example, label1 is clicked and the text “Hey you.” appears, then the next time you click label one the text “What are you doing?” appears. Any help is appreciated.

1 Like

You will need to use a list index value to do this. If the idea of a list index is unfamiliar to you, you can name this variable anything you like (“Narration speech count” or “dialogue sentence number”, etc.).

Note: this will return “undefined” if the narration index is larger than the number of items (3) in the list. You can prevent that using an if/then block:

2 Likes

this worked, thank you so much

1 Like