Need sound clip to stop if returning to the slide

I am working on a course with 4 lessons and a Main Menu.  On the main menu, I have a sound clip that I want to play when the user first accesses the course.  At the end of each lesson, the user is asked to return to the main menu.  How can I set up a trigger so that the sound clip will not start over every time the user returns to the main menu?  Also, the user does not have to complete the lesson to return to the main menu...they can return at any time.  I just don't want the clip to play every time the user returns to the main menu. 

Any help would be appreciated!

12 Replies
Nancy Woinoski

Hi Kathy, I think you will need to create a variable to do this.

Here is one way to do this.

1. Create a true/false variable called AudioPlayed and set the inital value to false  (note: you create variables by clicking the x icon at the bottom of the Triggers panel).

2. Add a slide trigger to the menu page that say as follows:

Action: Stop Media

Media: soundclip

When: Timeline Starts

Object: this is the name of the slide

Condition: AudioPlayed=True

3. Add the following trigger to each of the slides the user can jump to by clicking the a menu option on the menu pages. (sounds like you have 4 lessons so the first screen in each of the lessons should have this trigger.

Action: adjust variable

Variable: AudioPlayed

Operator: = Assignment

Value:  Value True

When: Timeline Starts

Phil Mayor

Nancy's will work, another way which is the way I always use

Is to add you audio to a layer.  Add a trigger on timeline start show layer (with audio) with a condition that a variable (audio t/f) is equal to false.

The on your layer add a trigger on timeline start to set the variable to false (you could do theis on media completes if they must hear the whole thing

Does the same thing

Phil

Rebecca Fleisch Cordeiro

So I have a question. I was looking at this and decided to first try Phil's option. For some reason I couldn't get it to work. I must not be understanding the directions.

But in the process, I began messing around and this is what I did:

  1. placed some audio (e.g., Learner instructions) on the base layer of the "Main Menu" Slide - no layers.
  2. created an audio variable, set to False.
  3. inserted a shape offstage and added a selected state.
  4. created a trigger to change the state of the shape to selected when the timeline starts if audio is equal to true
  5. adjusted the variable to set the audio to true when the timeline starts

I created two more slides, one in the same scene as the Main Menu and one in a new scene.

There are buttons on the main menu to jump to the other 2 slides, and button on the slides to jump back to the main menu.

When I "begin the lesson" (preview) the audio instructions play. When I click on the "return to main menu buttons", no audio plays on the main menu.

So, my question: is this solution valid or would it break down somewhere? Would it work for what Kathy needed?

TIA

Rebecca Fleisch Cordeiro

Hi Kathy and Nancy,

Kathy, I'm glad Nancy's solution worked.

Nancy, thanks for corroboration. I truly wanted to know if this works as I think it should, so I appreciate your taking the time to reply. Can I ask why you don't like to have objects offstage? Need to step away for a while, but will check back later.

Phil Mayor

I dont have a problem with off screen objects, if it works, well it works.

I would probably try to find another way of doing it first, just to make it all seem cleaner. Often though the only solution is offscreen elements (sometimes I need to do this to bolt-on a fix because a client requested it).

I am always striving for the most elegant design and find that layers allow me to organise things.  I can build series of triggers and call them like functions.

My workflow is normally get it working, simplify and then make it elegant, this may be over a series of clients and months though

Nancy Woinoski

Rebecca Fleisch Cordeiro said:

Hi Kathy and Nancy,

Kathy, I'm glad Nancy's solution worked.

Nancy, thanks for corroboration. I truly wanted to know if this works as I think it should, so I appreciate your taking the time to reply. Can I ask why you don't like to have objects offstage? Need to step away for a while, but will check back later.


It is more a preference than anything - I think it is messy - and sometimes if you go back to a project after being away from it for a time, you might miss the fact that something is off screen.

It also kind of bugs me that we have to use objects like this to trigger actions on the  timeline.  We should be able to assign triggers directly to cue points on the timeline.

Rebecca Fleisch Cordeiro

Phil and Nancy,

thanks for your replies. I do use layers a lot, but for some reason I couldn't get that solution to work. It kept playing the audio.

And with the shape offstage, I didn't need to go to any other slides and add triggers.

Wish I was as slick with variables as the Super Heroes!