LoginSignup
0
1

More than 1 year has passed since last update.

[Unreal Engine 4] レベルを遷移しても、BGMを継続して再生する方法

Last updated at Posted at 2022-11-16

目次

  1. BGMを継続して再生する方法
  2. 参考文献
  3. その他

BGMを継続して再生する方法

※Unreal Engine 4.14以前のバージョンについては、Spawn Sound 2Dに「Persist Across Level Transition」の項目がないため、本記事の方法を利用できません。

Game Instanceに、Audio Componentの変数を追加します。
image.png

レベルブループリントなど、BGMを再生・停止したいところで以下の処理を追加します。
image.png

参考文献

その他

Unreal Engineのバージョン:4.26
Googleで検索していた際に、「パーシスタントレベル・サブレベルを設定しなければならない」といった情報がありましたが、そのような設定をせずに、本記事の方法で解決できると思います。
何か質問などありましたらコメントしていただけると助かります。m(_ _)m

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1