# Transitioning looped audio to stopped

**URL:** https://qa.fmod.com/t/transitioning-looped-audio-to-stopped/22921
**Category:** FMOD Studio
**Created:** [May 8, 2025, 9:02pm UTC](https://qa.fmod.com/t/transitioning-looped-audio-to-stopped/22921 "2025-05-08T21:02:34Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![thelebaron](https://avatars.discourse-cdn.com/v4/letter/t/e274bd/32.png) [@thelebaron](https://qa.fmod.com/u/thelebaron)
#### Post date: [May 8, 2025, 9:02pm UTC](https://qa.fmod.com/t/transitioning-looped-audio-to-stopped/22921/1 "2025-05-08T21:02:34Z")

</div>

![Unity_XbW6eGuZno](https://canada1.discourse-cdn.com/flex036/uploads/fmod/original/2X/1/1b25478bec6db881dcfb41d21fddf0034b16921e.png)

Im not sure if Im understanding how looped audio works, but anyway I’ve been working on a custom fmod integration with entities in unity.

I have this simple audio of a looping gun sound. When I use `activeAudio.Instance.stop(STOP_MODE.ALLOWFADEOUT);`  
obviously the audio is allowed to fadeout, but the state stays at `PLAYBACK_STATE.STOPPING` but never fully reaches `PLAYBACK_STATE.STOPPED`.

Is this to be expected? Calling stop with `IMMEDIATE` obviously stops things immediately but I’m not sure if I’m doing whats ideal here, if I should always keep these looped audio in a state of limbo until they are started again or try to stop them fully and clear them.

I noticed in the editor(after checking out some threads) adding the fadeout condition to an empty space sort of does the same thing when setting fadeout to 1, the instruments no longer play, but the event still loops and playback doesnt stop on its own.

---

<div class="post-metadata">

### Author: ![joseph](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/joseph/32/264_2.png) [@joseph](https://qa.fmod.com/u/joseph)
#### Post date: [May 9, 2025, 4:38am UTC](https://qa.fmod.com/t/transitioning-looped-audio-to-stopped/22921/2 "2025-05-09T04:38:44Z")

</div>

Do any of the logic markers or instruments in your event have an event state trigger condition (such as “stopping” or “not stopping”)? I ask because if there is at least one event state condition in an event and the event instance is stopped with `STOP_MODE.ALLOWFADEOUT`, the event will only stop when it reaches a [natural end](https://www.fmod.com/docs/2.03/studio/glossary.html#natural-end).

If the event does contain at least one event state trigger condition, ensure that it is reaching a natural end, i.e.: that the timeline playback position ends up to the right of all instruments and markers on the timeline and that the event’s instruments are all untriggered so that they stop producing audio.

If the event does not contain any event state conditions and is stopped with `STOP_MODE.ALLOWFADEOUT`, it should stop as soon as the AHDSR modulator with the longest release period in the event reaches the end of its release period.
