Widget switcher

I use widget switcher to switch images and understand how to switch between two images.

But how can I switch more than two images using just two buttons (next and previous)?

???

Create an int variable to track current index, increase / decrease it:

Just remember not to exceed bounds or it will start throwing errors.

1 Like

Helped a lot, thanks!
I’ve been trying to connect the increment node to the wrong place all this time :))

1 Like

Everything was fine, but now for some reason it flips from 1 picture to 3 at once. But if I scroll back and then forward again, then everything is flipped in order. What could this be related to?

You’d need to show the script. Add clamps so you do not exceed values.

The solution is found immediately after you ask a question, this is the law… :grin: I messed up the default value, but thanks for the quick response!

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.