Sum Variables or Test conditions for completion

Oct 01, 2018

Hi

I'm trying to test that all layers have been visited (in any order). To do this I've been setting a unique variable as true for each layer. Then I have a "Continue" button appear  (or Complete Course) when all the layer variables = true. 

But I can't work out how to do the trigger for when my whole list of boolean variables = true, ie the sum of = true. I can use the "On Condition:" part of the trigger to test each true/false variable, but what do I put in the "When:" & "Object:" criteria?

 

I could do:

When: Variable Changes To  (True)

but that variable might be the first one to change, or the last one.

 

Any suggestions? Is there a way? Or an easier way?

Thank you.

7 Replies
Wendy Farmer

Hi Paul

I add a trigger to each layer:

Not sure if you are changing the state of next button or what your action is but here is an example

Change state of next button to normal when timeline starts/ends on the layer on condition that layerA = True and layerB=true and layerC=true...make sure your trigger to adjust the layerA/B/C variable is before this trigger.

Here is a link to a demo I did in SL2

Paul Tottle

Here is my current solution for firing a trigger when all layers have been visited or a certain number have been visited (CountUnder_K). This way I can keep adding layers and I only have to change the default value of the variable "Scenario1Count" to equal the number of layers. These triggers are added to every layer.

This also allows for feedback to learners about how many layers are still to be visited.

Any easier solutions welcome. Just keeping in mind I can't use "visited" button states.

This discussion is closed. You can start a new discussion or contact Articulate Support.