playMaker

Author Topic: Audio Stop Issue  (Read 1037 times)

Flamehead

  • Playmaker Newbie
  • *
  • Posts: 7
Audio Stop Issue
« on: May 13, 2022, 02:51:01 PM »
Hi,

I created an FSM that plays an audio clip in each state. The following state uses an audio stop action to stop the previous audio clip. Everything works perfect the first time through, however when it loops back through the states again the audio clip won't play.

It seems like audio stop is negating the audio play action the 2nd time around. Why would this be and how do I fix this?

Thanks,
Flamehead

Roger Lee

  • Playmaker Newbie
  • *
  • Posts: 31
Re: Audio Stop Issue
« Reply #1 on: October 03, 2022, 10:05:52 PM »
I know this is a late response since I haven't been around for awhile but this action doesn't function properly as stock.  It fades the volume out but never sets it back to it's initial state.

I fixed this a while ago and for anyone in the future who runs into this, this post will serve as help.

I added a new private float to get the original volume of the audio source before it fades out and then it resets it to that volume after the sound is finished processing.

The new action is attached below.
« Last Edit: October 03, 2022, 10:08:34 PM by Roger Lee »