# Audio Between Levels: Possible on Game Instance?

**URL:** <https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009>\
**Category:** Audio\
**Tags:** unreal-engine\
**Created:** [May 10, 2019, 8:43pm UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009 "2019-05-10T20:43:34Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![Wild\_Koala](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Wild\_Koala](https://forums.unrealengine.com/u/Wild_Koala)\
**Post date:** [May 10, 2019, 8:43pm UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/1 "2019-05-10T20:43:34Z")

</div>

Hello,

Preface - I have used Unreal in the past, but I am extremely rusty as several new projects I am working on use it.

I am currently implementing some audio for a game, and I am wondering what the best method to implement music between maps. In the past, it was suggested that I use a persistent level and level streaming to accomplish this; however, the current projects are not set up in this manner, and I fear the amount of work involved to convert them to the streamed levels.

I had an idea about calling the audio from the GameInstance, as I believe this persists between levels. Has anyone gotten a system like this to work?

---

<div class="post-metadata">

**Author:** ![ArthurBarthur](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ArthurBarthur](https://forums.unrealengine.com/u/ArthurBarthur)\
**Post date:** [May 12, 2019, 9:40am UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/2 "2019-05-12T09:40:02Z")

</div>

Yeah, if you pass an audio component to the Game Instance it will persist between levels.

---

<div class="post-metadata">

**Author:** ![Wild\_Koala](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Wild\_Koala](https://forums.unrealengine.com/u/Wild_Koala)\
**Post date:** [May 13, 2019, 12:14am UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/3 "2019-05-13T00:14:10Z")

</div>

Awesome, thanks for comment!

Would you happen to be able to point me in the direction of an efficient way to do this? I am essentially having to relearn how to work in Unreal after so long. I’m assuming there is something regarding this function in the doc?

---

<div class="post-metadata">

**Author:** ![ArthurBarthur](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ArthurBarthur](https://forums.unrealengine.com/u/ArthurBarthur)\
**Post date:** [May 13, 2019, 9:54am UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/4 "2019-05-13T09:54:03Z")

</div>

I will quote Dan, epic audio god:  
“You play music on an Audio Component, you pass the Audio Component Reference to something that persists between levels, like the Game Instance, the Game Instance passes the Audio Component back to the next level.”

So it’s very doable in normal blueprints, either create your own gameinstance and hook it up to game, or for example cast to the pre-existing one through other BPs. Many ways to go about it.

---

<div class="post-metadata">

**Author:** ![Wild\_Koala](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Wild\_Koala](https://forums.unrealengine.com/u/Wild_Koala)\
**Post date:** [May 15, 2019, 9:09am UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/5 "2019-05-15T09:09:15Z")

</div>

Got it. Thanks a lot!

---

<div class="post-metadata">

**Author:** ![ttm1st](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ttm1st](https://forums.unrealengine.com/u/ttm1st)\
**Post date:** [November 3, 2019, 8:15pm UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/6 "2019-11-03T20:15:10Z")

</div>

i’ve tried it but the music stops as soon as i change maps. what could be the problem,

i’ve created a custom event inside the game instance and hooked it to the (play sound 2d) and created a public boolean variable so i can cast the events once.  
here is what i have in games instance :

 ![20191103-22_13_37SKY_LEVEL_selection_--Level-Blueprint-Editor.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/3X/9/3/9387c5c338ed894c09428ed663e1a6aaa738fd5d.jpeg)

i hope to hear from u soon, thanks

---

<div class="post-metadata">

**Author:** ![ArthurBarthur](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ArthurBarthur](https://forums.unrealengine.com/u/ArthurBarthur)\
**Post date:** [November 4, 2019, 9:49am UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/7 "2019-11-04T09:49:56Z")

</div>

> [@ttm1st](#):
>
> custom event inside the game instance and hooked it to the (play sound 2d)

‘Play Sound 2d’ is like a fire and forget thing. You need to add/spawn an audiocomponent(a sound), and ALSO promote that spawned sound/audiocomponent to a variable. Then it’s this variable that gameInstance keeps track of.

---

<div class="post-metadata">

**Author:** ![SuperApe33](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@SuperApe33](https://forums.unrealengine.com/u/SuperApe33)\
**Post date:** [November 7, 2019, 3:02am UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/8 "2019-11-07T03:02:23Z")

</div>

Hello,

Thank you for this thread!

I’m trying to use this method for a game.

I’ve created an audio component on a dedicated blueprint named BP\_Music\_System, and I fire the component on event begin.

But how to promote that as a variable and what type of variable would it be?

---

<div class="post-metadata">

**Author:** ![ArthurBarthur](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ArthurBarthur](https://forums.unrealengine.com/u/ArthurBarthur)\
**Post date:** [November 7, 2019, 6:00am UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/9 "2019-11-07T06:00:43Z")

</div>

> [@SuperApe33](#):
>
> But how to promote that as a variable and what type of variable would it be?

Variable would be type of itself, “audio component”, and if it’s in the bp as a component, it is already stored as a variable. To create more variables/references to it, plop it into the graph and drag out of the right side. On top of the big list that popups it should say “promote to new variable”! Would have to f.ex cast to game instance and have it store the variable at some point.

---

<div class="post-metadata">

**Author:** ![KimLaughton](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/kimlaughton/32/979013_2.png) [@KimLaughton](https://forums.unrealengine.com/u/KimLaughton)\
**Post date:** [November 25, 2019, 3:16pm UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/10 "2019-11-25T15:16:00Z")

</div>

Also trying to figure out how to do this - It seems fairly simple, but just can’t work out how to do it ;\_;

Anyone in the thread actually managed to get it going?

---

<div class="post-metadata">

**Author:** ![AshimShakya](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AshimShakya](https://forums.unrealengine.com/u/AshimShakya)\
**Post date:** [April 8, 2020, 6:57am UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/11 "2020-04-08T06:57:44Z")

</div>

Hi All,  
You can do it like this (Attached Screenshot)  
Spawn sound on GameInstance, promote it to a variable, make sure you have checked the ’ persist across level transition ’ on spawn sound function.

---

<div class="post-metadata">

**Author:** ![sabibo67](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@sabibo67](https://forums.unrealengine.com/u/sabibo67)\
**Post date:** [September 27, 2021, 1:52pm UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/12 "2021-09-27T13:52:40Z")

</div>

I am trying to do this also - cannot see a screenshot here…

---

<div class="post-metadata">

**Author:** ![elguapador](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@elguapador](https://forums.unrealengine.com/u/elguapador)\
**Post date:** [February 1, 2024, 2:09pm UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/13 "2024-02-01T14:09:25Z")

</div>

Thanks bud, I’d missed the persist across level argument. Solved my issue 🙂

---

<div class="post-metadata">

**Author:** ![DarkGate4](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@DarkGate4](https://forums.unrealengine.com/u/DarkGate4)\
**Post date:** [April 5, 2024, 5:31pm UTC](https://forums.unrealengine.com/t/audio-between-levels-possible-on-game-instance/126009/14 "2024-04-05T17:31:24Z")

</div>

![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/4/5/4/454fe8b31ef1cfaffd478d092a3f45191b6ff2a4.png)

Here is a screenshot to show how it is done.
