WHEN does, "When state is" trigger?

There is an option to set a trigger to, "When state of anObject is..."

WHEN does this trigger actually fire?

I'm looking for a way to set the value of a variable to true or false based on the state of an object on each slide without multiple event driven triggers (when timeline starts, when media completes, when button is clicked).

I was hoping this trigger would allow me to simply have a variable set based on whether a slide had been visited or not, based on the state of an object on the slide. However, the variable is not changing as hoped.

I have a sample to upload if that would help.

3 Replies
Blake Griffin

From what I understand this is similar to the "When Variable Changes" trigger.  That being that when the requirement of the Objects state is met, the trigger fires.  I am not entirely sure about that.  But that is my understanding.  I tested it out (see attached). 

Is this what you were trying to accomplish?

Alexander Covan

Thanks

It does seem to function as "When state of objectX changes to thisState..."

I was experimenting with building a restricted navigation solution for compliance that wouldn't rely on a lot of variables and had as much functionality as possible built into the master slide.

First I tried 3 duplicate slides with the following

  • When state of buttonName is Disabled set var navLock == False
  • When state of buttonName is Visited set var navLock == True
  • When timeline ends buttonName button state == visited

When the first slide timeline of slide 1 finished the variable was set to true.

However, entering slide 2  or 3 (where buttonName  was in the default state) didn't reset the variable

I changed to

  • When timeline starts, set var navLock == False IF state of buttonName == Disabled
  • When state of buttonName is Visited set var navLock == True
  • When timeline ends buttonName button state == visited

This worked. So yes, I think "when" means "when changed".

The reason I did this is that if each slide has buttonName and the 3 script lins, I don't need to have varibles tracking completion of each slide and I can set certain navigation controls based entirely on value of var navLock