Last active
May 6, 2023 10:43
-
-
Save benblo/d8b31eab90195208cc38 to your computer and use it in GitHub Desktop.
Disable AudioManager from build script
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var audioManager = AssetDatabase.LoadAllAssetsAtPath("ProjectSettings/AudioManager.asset")[0]; | |
| var serializedManager = new SerializedObject(audioManager); | |
| var prop = serializedManager.FindProperty("m_DisableAudio"); | |
| prop.boolValue = true; | |
| serializedManager.ApplyModifiedProperties(); |
Author
only editor?
Yes, it's meant to be done during a build.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
only editor?