Change state of a button after trigger is fired

Dec 07, 2022

I am trying to get a set of buttons to go from visited to completed.

I have a main slide with a bunch of buttons that jump to difference scenes. These are the ones that aren't changing.

Main setup - dashboard to scenes

Each button jumps to a scene that has two parts: View and Practice. At the end of each segment, a variable changes from false to true, ie ViewComplete and PracticeComplete. That is working fine, so the scene dashboard won't let them move on until they have completed both parts.

Scene Setup - two branches to complete

I have variables in the main dashboard to change the state of the button to completed if the variables set in the scene are true and the state of the button is visited, which I think automatically happens when the button is clicked. But the buttons stay at visited.

What am I missing?

Here are the variables.

Scene Dashboard

 

Main dashboard triggers

Thanks for any insights!

9 Replies
Tom Kuhlmann

I assume you are leaving the dashboard slide to go to a slide to set the variable. And then you are returning the dashboard.

If that's the case, the trigger should be to change the state of the button to complete when the timeline of the slide starts on the condition that var = X and state = visited.

See if that works.

Walt Hamilton

There are sooo many things that could cause this, it is foolish to guess without being able to look at everything. (For example, what initiates the triggers in the last picture?)

Nevertheless, I will suggest that you don't need the condition to find the button in the visited state and the variables set to true. The way you describe it, you want the variables to be set true only under the circumstances of the learner clicking the dashboard icon and completing the actions.So if there is any method for them to get to the View and Practice besides clicking the dashboard icon, take it out. If the variables are True, the icon has been clicked.

If that doesn't help, click Add Attachment, and attach your .story file.

Walt Hamilton

You are on the right track, except for a couple of small things.

One is these triggers:

Once the system encounters a "Jump" trigger, it jumps, cutting off the execution of any trigger below it in the list. So the variable will never be set until you move it above the Jump trigger.

The other problem is on the main dashboard. I found triggers like this:

for all the options except COP. Add it, and change the order of the others, and I think you'll be all right.

Walt Hamilton
You're welcome. PIAWYC  (Pass it along when you can). 
 
The only priority triggers have is that they are executed in the order they appear. So to troubleshoot them, you start with the first one on the list and ask "What does it do? Now what has changed , what is the situation (states, variables)? Now in that new situation, what does the second one do?" Unless they have conditions that keep them from executing (or a jump to break the chain), they all execute in order, from top to bottom.