Forum rules - please read before posting.

Music Editor not saving that "No Music" is playing (only after quitting game)

AC v 1.80.4

So I have this scene where I stop the music. I can save, and then load, and the music remains stopped. But, when I save. Quit the game, boot it back up. Load into the scene thats supposed to have no music playing, and it will be playing whatever music from whatever other scene/location I just loaded from. Is there an easy fix for that besides setting a variable to track whether its supposed to be silent or not?

Comments

  • I can't recreate such an issue. Does this occur if you import the latest release after backing up your project?

    To force-stop any music before loading a save-file, you can hook a custom script into the OnBeforeLoading custom event:

    using UnityEngine;
    using AC;
    
    public class ForceStopLoading : MonoBehaviour
    {
    
        private void OnEnable() { EventManager.OnBeforeLoading += OnBeforeLoading; }
        private void OnDisable () { EventManager.OnBeforeLoading -= OnBeforeLoading; }
    
        private void OnBeforeLoading (SaveFile saveFile)
        {
            if (KickStarter.music) KickStarter.music.Stop();
        }
    
    }
    
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.