# Table of Contents - [Sonity | Sonity Docs](#sonity-sonity-docs) - [Optimize AudioClip Settings | Sonity Docs](#optimize-audioclip-settings-sonity-docs) - [Debug Sounds and Performance | Sonity Docs](#debug-sounds-and-performance-sonity-docs) - [Rename A Lot of Assets | Sonity Docs](#rename-a-lot-of-assets-sonity-docs) - [Editor Tools | Sonity Docs](#editor-tools-sonity-docs) - [Force Resave Assets | Sonity Docs](#force-resave-assets-sonity-docs) - [Steam Audio Settings | Sonity Docs](#steam-audio-settings-sonity-docs) - [Modifiers | Sonity Docs](#modifiers-sonity-docs) - [SoundContainer | Sonity Docs](#soundcontainer-sonity-docs) - [Third Party Integrations | Sonity Docs](#third-party-integrations-sonity-docs) - [SoundEvent Functions | Sonity Docs](#soundevent-functions-sonity-docs) - [SoundManager Functions | Sonity Docs](#soundmanager-functions-sonity-docs) - [SoundManager | Sonity Docs](#soundmanager-sonity-docs) - [SoundEvent | Sonity Docs](#soundevent-sonity-docs) - [SoundTrigger | Sonity Docs](#soundtrigger-sonity-docs) - [Steam Audio Integration | Sonity Docs](#steam-audio-integration-sonity-docs) - [SoundParameterIntensity | Sonity Docs](#soundparameterintensity-sonity-docs) - [SoundParameter | Sonity Docs](#soundparameter-sonity-docs) - [PlayMaker Integration | Sonity Docs](#playmaker-integration-sonity-docs) - [SoundPicker | Sonity Docs](#soundpicker-sonity-docs) - [SoundTrigger Functions | Sonity Docs](#soundtrigger-functions-sonity-docs) - [Legacy Support | Sonity Docs](#legacy-support-sonity-docs) - [How To Guides | Sonity Docs](#how-to-guides-sonity-docs) - [Create Assets From Selection | Sonity Docs](#create-assets-from-selection-sonity-docs) - [SoundPhysics | Sonity Docs](#soundphysics-sonity-docs) - [Unity Native Audio | Sonity Docs](#unity-native-audio-sonity-docs) - [SoundPicker Functions | Sonity Docs](#soundpicker-functions-sonity-docs) - [Templates & Examples | Sonity Docs](#templates-examples-sonity-docs) - [Changelog | Sonity Docs](#changelog-sonity-docs) - [FAQ | Sonity Docs](#faq-sonity-docs) - [SoundVolumeGroup | Sonity Docs](#soundvolumegroup-sonity-docs) - [SoundMix | Sonity Docs](#soundmix-sonity-docs) - [SoundPolyGroup | Sonity Docs](#soundpolygroup-sonity-docs) - [SoundPreset | Sonity Docs](#soundpreset-sonity-docs) - [SoundDataGroup | Sonity Docs](#sounddatagroup-sonity-docs) - [SoundTag | Sonity Docs](#soundtag-sonity-docs) - [Getting Started | Sonity Docs](#getting-started-sonity-docs) --- # Sonity | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FomTXHxSTcpYYQR1d4eWg%252FSonity%2520Logo.png%3Falt%3Dmedia%26token%3D13f6666f-0e29-4d77-9a97-1f6a7aa33d80&width=768&dpr=3&quality=100&sign=85c6e95d&sv=2) Sonity is an audio middleware giving you full control of your sound, all within Unity. Balancing ease of use with advanced features it will help you to quickly make your game sound good. * **New in 1.1.0:** [Steam Audio](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration) & [PlayMaker](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration) integration. * **New in 1.0.6:** [Increase the volume of your sounds above 0dB](https://sonity.gitbook.io/docs/soundmanager#settings) . * [Components for triggering sounds without code](https://sonity.gitbook.io/docs/soundtrigger) . * Live-edit and multi-edit everything with scriptable objects. * Use [SoundParameters](https://sonity.gitbook.io/docs/soundparameter) to control your sound in real time. * [Automatic asset creation](https://sonity.gitbook.io/docs/sonity/create-assets-from-selection) and [reference finder](https://sonity.gitbook.io/docs/soundmanager/editor-tools#editor-tool-reference-finder) . * Music functionality like playlists, stems and intros. * [Visually debug sounds live in-game](https://sonity.gitbook.io/docs/soundmanager#debug) . * [Custom DSP filters and distortion per voice](https://sonity.gitbook.io/docs/soundcontainer#distortion) . * Highly optimized system with IL2CPP support. * Fully documented source code provided. * Developed and used in commercial games. * Crafted with my experience as a game audio professional. **Note about licences:** Sonity uses the standard [Unity Asset Store EULAarrow-up-right](https://unity.com/legal/as-terms) (read more in the [FAQ](https://sonity.gitbook.io/docs/sonity/faq#eula-licencing-and-seats) ) Contact me if you need a special license or have questions about licencing. Email - victor@sonigon.com ### [hashtag](https://sonity.gitbook.io/docs#helpful-links-and-info) **Helpful Links and Info** * [Websitearrow-up-right](http://www.sonity.org/) * [Free Trial - Unity Asset Storearrow-up-right](https://assetstore.unity.com/packages/tools/audio/sonity-audio-middleware-free-trial-244369) * [Paid Version - Unity Asset Storearrow-up-right](https://assetstore.unity.com/packages/tools/audio/sonity-audio-middleware-229857) * [Video Tutorialsarrow-up-right](https://www.sonigon.com/sonity-tutorial/) * [Documentationarrow-up-right](https://www.sonigon.com/sonity-documentation) * [Discordarrow-up-right](https://www.sonigon.com/sonity-discord) * [FAQ](https://sonity.gitbook.io/docs/sonity/faq) ### [hashtag](https://sonity.gitbook.io/docs#supported-unity-versions) **Supported Unity Versions** * **Unity 6, 2022, 2021, 2020, 2019 and IL2CPP** Tested, full functionality. * **Unity 2018.3.0** Tested, everything works except “[Draw SoundEvents (In Scene View)](https://sonity.gitbook.io/docs/soundmanager#draw-soundevents) ” and Terrain example. Minor GUI tweaks for compatibility. * **WebGL** Everything works except DSP (distortion/lowpass/highpass). * **Disabling Domain Reloading** Disabling domain reloading in the “enter play mode options” is supported since Sonity 1.0.3. * **Support for Addressables** Addressable AudioMixer support since Sonity 1.0.6. Object comparison with cached GUIDs is supported since Sonity 1.0.6. Adding and deleting [SoundEvents](https://sonity.gitbook.io/docs/soundevent) in runtime is supported since Sonity 1.0.5. [NextGetting Startedchevron-right](https://sonity.gitbook.io/docs/sonity/getting-started) Last updated 1 month ago * [Helpful Links and Info](https://sonity.gitbook.io/docs#helpful-links-and-info) * [Supported Unity Versions](https://sonity.gitbook.io/docs#supported-unity-versions) sun-brightdesktopmoon sun-brightdesktopmoon --- # Optimize AudioClip Settings | Sonity Docs Here are some settings you’d want for most games get lower RAM usage, disk read and CPU usage. Read more about the other settings here: [Unity Manual - AudioCliparrow-up-right](https://docs.unity3d.com/Manual/class-AudioClip.html) . #### [hashtag](https://sonity.gitbook.io/docs/how-to-guides/optimize-audioclip-settings#audioclip-overall-settings) **AudioClip - Overall Settings** **Compression Format:** Vorbis **Quality:** 60\. Which is ~192 kbit/s for Vorbis. You can go lower if you’d want to save space but it comes at a loss of quality. **Sample Rate Setting:** Should be the same as the sample rate of the platform, which today mostly is 48kHz (this is so that it doesnt have to do a sample rate conversion) when playing. Also, if the sounds are created in 48kHz there is more high frequency content which makes it sound better when pitching down vs 44.1kHz. circle-info ❕ Tip: If you select multiple AudioClips, you can see their total “Imported Size” which is the size they’ll have after all your format and quality settings are applied. #### [hashtag](https://sonity.gitbook.io/docs/how-to-guides/optimize-audioclip-settings#audioclip-vorbis-quality) **AudioClip - Vorbis Quality** Unity Vorbis Quality 1 is VBR Quality 0 (not -2). Mono is half the bitrate of stereo and 4 channel files (for surround) are twice the bitrate of stereo. **Unity Vorbis Quality** **VBR Target kbit/s stereo** **VBR Target kbit/s mono** **VBR Range kbit/s stereo** **Noise Test kbit/s stereo** **Size vs 10** **Size vs 60** **Comment** 100 500 250 500 - 1000 554 100% 260% Uneccessarely big, don’t use this 90 320 160 320 - 500 435 64% 167% Uneccessarely big 80 256 128 256 - 320 382 51% 133% Use if you want to mazimize quality & have the disk space and RAM 70 224 112 224 - 256 309 45% 117% 60 192 96 192 - 224 232 38% 100% Use this as a default, it is a good balance between quality and size 50 160 80 160 - 192 173 32% 83% [Sounds like near CD qualityarrow-up-right](https://xiph.org/vorbis/faq/#quality) 40 128 64 128 - 160 128 26% 67% 30 112 56 112 - 128 117 22% 58% [Smaller & better sound than .mp3 128kbpsarrow-up-right](https://xiph.org/vorbis/faq/#quality) 20 96 48 96 - 112 102 19% 50% 10 80 40 80 - 96 87 16% 42% Sounds acceptable. Use if you are desparate for saving space and RAM 1 64 32 64 - 80 71 13% 33% Looses a lot of quality, noticeably stereo separation and bass Notes: Noise test is calculated using VBR export & size comparison to CBR with a known bitrate. Sources: [Recommended Encoder Settingsarrow-up-right](https://wiki.hydrogenaudio.org/index.php?title=Recommended_Ogg_Vorbis#Recommended_Encoder_Settings) and [Vorbis Qualityarrow-up-right](https://xiph.org/vorbis/faq/#quality) . The bitrates are approximate. #### [hashtag](https://sonity.gitbook.io/docs/how-to-guides/optimize-audioclip-settings#audioclip-load-type) AudioClip - Load Type Stereo files are double the size of mono files. So a 60s 2 channel sound is the same size as a 120s 1 channel sound. The lengths are approximated with stereo files in mind. **Length Seconds ~** **Play Frequency** **Load Type** **Pros** **Cons** **Example Sounds** Short - Less than 1s High Decompress On Load Uses less CPU Uses 10x RAM so only use for short sounds. Player sounds, footsteps, impacts etc. Commonly used for mobile platforms Short - Less than 1s Low Compressed In Memory Uses less RAM Medium - More than 1s less than 60s High & Low Compressed In Memory Uses less RAM Long - More than 60s High Compressed In Memory Uses less disk read Try if you have problems with audio delays. Watch out for load times and RAM usage Localized 3D ambiences etc Long - More than 60s Low Streaming Uses less RAM Many platforms can only handle less than 10 simultaneously streaming sounds Music, background 2D ambiences etc Note: You want to stream the largest files you have, but not too many at the same time. So the 60s threshold for long sounds can be lowered to e.g. 30s or even lower if not many sounds are +60s. **AudioClip - Preload Audio Data** Makes the sound load at startup, which might create long load times on harddrives and slower systems. Is useful to combine with Load In Background so it doesn’t interrupt the main thread. **Length in seconds** **Play Frequency** **Preload Audio Data** **Pros** **Cons** **Example Sounds** Short - Less than 1s High Yes Less frequent disk read Use only for frequent & short sounds. Combine with Load in Background Player sounds, footsteps, impacts etc Short - Less than 1s Low No Medium & Long - More than 1s Low No Note: I’ve had problems where if I don’t Preload Audio Data, there might be clicks heard in the end of sounds. "Prevent End Clicks" in the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) mitigates this. **AudioClip - Load In Background** When enabled, the AudioClip is loaded without stalling the main thread and any playing is delayed until the AudioClip is loaded. Useful to combine with Preload Audio Data so it doesn’t interrupt the main thread. [PreviousHow To Guideschevron-left](https://sonity.gitbook.io/docs/how-to-guides) [NextDebug Sounds and Performancechevron-right](https://sonity.gitbook.io/docs/how-to-guides/debug-sounds-and-performance) Last updated 1 month ago sun-brightdesktopmoon sun-brightdesktopmoon --- # Debug Sounds and Performance | Sonity Docs If you want to debug audio performance or what sounds are playing, you can use: * [Unity built in Profilerarrow-up-right](https://docs.unity3d.com/Manual/ProfilerAudio.html) * [SoundManager Statistics](https://sonity.gitbook.io/docs/soundmanager#statistics) #### [hashtag](https://sonity.gitbook.io/docs/how-to-guides/debug-sounds-and-performance#unity-profiler) **Unity Profiler** [Read more here.arrow-up-right](https://docs.unity3d.com/Manual/ProfilerAudio.html) Because Sonity is built upon Unity native AudioSources, you can use the built in Profiler. Example of the profiler in “Detailed” mode (bottom left) with deep profile enabled: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FoNNWNTyekf9gS8DMDBY5%2Fimage87.png&width=768&dpr=3&quality=100&sign=57da42c4&sv=2) #### [hashtag](https://sonity.gitbook.io/docs/how-to-guides/debug-sounds-and-performance#soundmanager-statistics) **SoundManager Statistics** [Read more here](https://sonity.gitbook.io/docs/soundmanager#statistics) . Example picture of the the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) : ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FwJ4tQx6F5uugh1CMX3mv%252FHow%2520To%2520-%2520Debug%2520Sounds%2520and%2520Performance%2520SoundManager%2520Statistics.png%3Falt%3Dmedia%26token%3D6400f3a4-099a-4df0-bc64-92faf90f310b&width=768&dpr=3&quality=100&sign=ae2fdd30&sv=2) [PreviousOptimize AudioClip Settingschevron-left](https://sonity.gitbook.io/docs/how-to-guides/optimize-audioclip-settings) [NextRename A Lot of Assetschevron-right](https://sonity.gitbook.io/docs/how-to-guides/rename-a-lot-of-assets) Last updated 1 month ago sun-brightdesktopmoon sun-brightdesktopmoon --- # Rename A Lot of Assets | Sonity Docs If you need to rename a lof of assets in Unity I can recommend the free tool called “Mulligan Renamer”. Download at [Unity Asset Storearrow-up-right](https://assetstore.unity.com/packages/tools/utilities/mulligan-renamer-99843) or [Githubarrow-up-right](https://github.com/redbluegames/unity-mulligan-renamer) . Example of use: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FGPloD1hyd7t1NoUfikLE%2Fimage1.png&width=768&dpr=3&quality=100&sign=ff8173a8&sv=2) [PreviousDebug Sounds and Performancechevron-left](https://sonity.gitbook.io/docs/how-to-guides/debug-sounds-and-performance) [NextForce Resave Assetschevron-right](https://sonity.gitbook.io/docs/how-to-guides/force-resave-assets) Last updated 1 month ago sun-brightdesktopmoon sun-brightdesktopmoon --- # Editor Tools | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FKRLb6gLVxrHFPP8X5Lfw%2Fimage24.png&width=768&dpr=3&quality=100&sign=ef691c78&sv=2) In the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) there is a part which is dedicated to Editor Tools. This is a collection of nifty editor tools which you can use to speed up your workflow. They are enabled with the use of “Script Define Symbols” in Project Settings -> Player -> Other Settings -> Script Compilation -> Script Define Symbols. This way they can be bound to default hotkeys and they won’t hog up your toolbars if you don’t use them. #### [hashtag](https://sonity.gitbook.io/docs/soundmanager/editor-tools#editor-tool-reference-finder) Editor Tool - Reference Finder ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252F6iJsgcQg1rjv1404EJFh%252FReference%2520Finder%25201.2%252003.gif%3Falt%3Dmedia%26token%3D5f40e4fd-1e82-4294-adc6-a9e534daf5d7&width=768&dpr=3&quality=100&sign=893a5de2&sv=2) Reference Finder is an editor tool for finding where an asset is referenced by another asset. It is enabled with the use of the Script Define Symbol "SONITY\_ENABLE\_EDITOR\_TOOL\_REFERENCE\_FINDER". This is assigned in Project Settings -> Player -> Other Settings -> Script Compilation -> Script Define Symbols. "Find References for Selected Assets" is useful for e.g. figuring out to which (if any) prefabs a SoundEvent is assigned to, or any other kind of asset in Unity. "Open Reference Finder Window" is useful for figuring out e.g. which AudioClips (or other assets) are completely unreferenced and therefore unused. Thanks [Alexey Perovarrow-up-right](https://github.com/AlexeyPerov/Unity-Dependencies-Hunter) for making this amazing tool which I've expanded upon! **Version 1.2** (Sonity Version) Added support for Live editing Added buttons for selecting all and hiding empty Sorted selected object and references names Made so buttons you've clicked becomes greyed out Added copy references list to clipboard More compact viewing with less whitespace Added folder paths info **Version 1.1** (Sonity Version) Added CancelableProgressBar Fixed menu links & "New code" Added "Select all Unused Assets" button Commented out Debug "Total Assets Count" Rounded search time to seconds with one decimal Added label for find all references window Fixed debugs **Version 1.0** Original version by [Alexey Perovarrow-up-right](https://github.com/AlexeyPerov/Unity-Dependencies-Hunter) **Toolbar Actions** Tools/Sonity Tools 🛠/Reference Finder 🔍/Open Reference Finder Window Tools/Sonity Tools 🛠/Reference Finder 🔍/Find References for Selected Assets Assets/Sonity Tools 🛠/Reference Finder 🔍/Open Reference Finder Window Assets/Sonity Tools 🛠/Reference Finder 🔍/Find References for Selected Assets **Default Shortcuts** Ctrl+Shift+Alt+F - Reference Finder 🔍/Find References for Selected Assets Reference Finder is made by Alexey Perov and licensed under a free to use and distribute MIT license. [Link to Github pagearrow-up-right](https://github.com/AlexeyPerov/Unity-Dependencies-Hunter) #### [hashtag](https://sonity.gitbook.io/docs/soundmanager/editor-tools#editor-tool-select-same-type) Editor Tool - Select Same Type ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FgEp7KWg42uv0LgtY21hr%252FEditor%2520Tool%2520-%2520Select%2520Same%2520Type.gif%3Falt%3Dmedia%26token%3D2e650dc1-5c6c-4170-9f7d-6fca7577c288&width=768&dpr=3&quality=100&sign=6e674f7&sv=2) Select Same Type is an editor tool for quickly selecting all assets of the same type in a folder which enables you to quickly edit a lot of assets. It is enabled with the use of the Script Define Symbol "SONITY\_ENABLE\_EDITOR\_TOOL\_SELECT\_SAME\_TYPE". This is assigned in Project Settings -> Player -> Other Settings -> Script Compilation -> Script Define Symbols. **Toolbar Actions** Tools/Sonity Tools 🛠/Select Same Type 🤏/In Same Folder Tools/Sonity Tools 🛠/Select Same Type 🤏/In Subfolders Assets/Sonity Tools 🛠/Select Same Type 🤏/In Same Folder Assets/Sonity Tools 🛠/Select Same Type 🤏/In Subfolders **Default Shortcuts** Ctrl+Alt+A - Select Same Type 🤏/In Same Folder Ctrl+Alt+Shift+A - Select Same Type 🤏/In Subfolders #### [hashtag](https://sonity.gitbook.io/docs/soundmanager/editor-tools#editor-tool-selection-history) Editor Tool - Selection History ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FlRzeO3qeE0fvPmpewJNA%2Fimage9.gif&width=768&dpr=3&quality=100&sign=7bce021e&sv=2) Selection History is an editor tool for quickly undoing and redoing selections. This enables you to quickly move between objects you’ve previously selected. It is enabled with the use of the Script Define Symbol "SONITY\_ENABLE\_EDITOR\_TOOL\_SELECTION\_HISTORY". This is assigned in Project Settings -> Player -> Other Settings -> Script Compilation -> Script Define Symbols. **Toolbar Actions** Tools/Sonity Tools 🛠/Selection History 📜/Back Tools/Sonity Tools 🛠/Selection History 📜/Forward Assets/Sonity Tools 🛠/Selection History 📜/Back Assets/Sonity Tools 🛠/Selection History 📜/Forward **Default Shortcuts** U - Selection History 📜/Back Shift+U - Selection History 📜/Forward Selection History is made by Matthew Miner and licensed under a free to use and distribute MIT license. [Link to Github pagearrow-up-right](https://github.com/mminer/selection-history-navigator) [PreviousSoundManagerchevron-left](https://sonity.gitbook.io/docs/soundmanager) [NextSoundManager Functionschevron-right](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions) Last updated 1 month ago sun-brightdesktopmoon sun-brightdesktopmoon --- # Force Resave Assets | Sonity Docs If you want to force save all changes for any assets in Unity, you can use the tool "Set Selected Assets as Dirty (Force Reserialize for Resave)". This is useful when if you select all assets of a type eg. t:SoundEvent and want to force save them. ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FC4XzzuQ7z1rOvVWtygNz%252FHow%2520To%2520-%2520Force%2520Resave%2520Assets.png%3Falt%3Dmedia%26token%3D096d8d8f-a309-471d-821a-6b75511295df&width=768&dpr=3&quality=100&sign=43b4e374&sv=2) [PreviousRename A Lot of Assetschevron-left](https://sonity.gitbook.io/docs/how-to-guides/rename-a-lot-of-assets) [NextSoundContainerchevron-right](https://sonity.gitbook.io/docs/soundcontainer) Last updated 1 month ago sun-brightdesktopmoon sun-brightdesktopmoon --- # Steam Audio Settings | Sonity Docs ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer/steam-audio-settings#soundcontainer-steam-audio-settings) SoundContainer Steam Audio Settings Additional settings when Steam Audio is enabled in the [SoundManager Settings](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration) . ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FkT5sAodFVBtyUFl8Vz4U%2Fimage3.gif&width=768&dpr=3&quality=100&sign=34055ca4&sv=2) **HRTF Plugin Spatialize** Spatialize makes the sound be affected by Steam Audio with effects like occlusion, reflections and more. Disable Spatialize for 2D sounds like music etc. circle-info ❕ Steam Audio Source This part of the text is mostly as the one from the official Valve [Steam Audio Source Component Referencearrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/source.html) . I’ve added information which was missing on some parts. **Direct Binaural** If checked, HRTF-based binaural rendering will be used to spatialize the source. This requires 2-channel (stereo) audio output. If unchecked, panning will be used to the spatialize the source using the user’s speaker layout. Binaural rendering provides improved spatialization at the cost of slightly increased CPU usage. **Interpolation** Controls how HRTFs are interpolated when the source moves relative to the listener. Nearest: Uses the HRTF from the direction nearest to the direction of the source for which HRTF data is available. The fastest option, but can result in audible artifacts for certain kinds of audio clips, such as white noise or engine sounds. Bilinear: Uses an HRTF generated after interpolating from four directions nearest to the direction of the source, for which HRTF data is available. This may result in smoother audio for some kinds of sources when the listener looks around, but has higher CPU usage (up to 2x). **Perspective Correction** If checked, perspective correction (based on the projection matrix of the current main camera) is applied to this source during spatialization. This can improve the perceived positional accuracy in non-VR applications. See Steam Audio Settings for more details. Requires Enable Perspective Correction to be checked in Steam Audio Settings. **Distance Attenuation** If checked, distance attenuation will be calculated and applied to the Audio Source. This takes into account the Spatial Blend setting on the Audio Source, so if Spatial Blend is set to 2D, distance attenuation is effectively not applied. Distance Attenuation: **Input** Specifies how the distance attenuation value is determined. Curve Driven: Distance attenuation is controlled by the Volume curve on the Audio Source. Physics Based: A physics-based distance attenuation model is used. This is an inverse distance falloff. The curves defined on the Audio Source are ignored. **Air Absorption** If checked, frequency-dependent distance based air absorption will be calculated and applied to the Audio Source. Air Absorption: **Input** Specifies how the air absorption values (which are 3-band EQ values) are determined. Simulation Defined: Uses a physics-based air absorption model. This is an exponential falloff, with higher frequencies falling off faster with distance than lower frequencies. User Defined: Uses the values specified in the Air Absorption Low, Air Absorption Mid, and Air Absorption High sliders as the EQ values. The air absorption value will not automatically change with distance to the source. You are expected to control the Air Absorption Low, Air Absorption Mid, and Air Absorption High sliders using a custom script to achieve this effect. Air Absorption: **Low** The low frequency (up to 800 Hz) EQ value for air absorption. Only used if Air Absorption Input is set to User Defined. 0 = low frequencies are completely attenuated, 1 = low frequencies are not attenuated at all. Air Absorption: **Mid** The middle frequency (800 Hz - 8 kHz) EQ value for air absorption. Only used if Air Absorption Input is set to User Defined. 0 = middle frequencies are completely attenuated, 1 = middle frequencies are not attenuated at all. Air Absorption: **High** The high frequency (8 kHz and above) EQ value for air absorption. Only used if Air Absorption Input is set to User Defined. 0 = high frequencies are completely attenuated, 1 = high frequencies are not attenuated at all. **Directivity** If checked, attenuation based on the source’s directivity pattern and orientation will be applied to the Audio Source. Directivity: **Input** Specifies how the directivity attenuation value is determined. Simulation Defined. Uses a dipole directivity model. You can control the dipole shape using the Dipole Weight and Dipole Power properties. User Defined. Uses the value specified in the Directivity Value property. This value will not automatically change as the source rotates. You are expected to control the Directivity Value property using a custom script to achieve this effect. Directivity: **Dipole Weight** Blends between monopole (omnidirectional) and dipole directivity patterns. 0 = pure monopole (sound is emitted in all directions with equal intensity), 1 = pure dipole (sound is focused to the front and back of the source). At 0.5, the source has a cardioid directivity, with most of the sound emitted to the front of the source. Only used if Directivity Input is set to Simulation Defined. Directivity: **Dipole Power** Controls how focused the dipole directivity is. Higher values result in sharper directivity patterns. Only used if Directivity Input is set to Simulation Defined. Directivity: **Value** The directivity attenuation value. Only used if Directivity Input is set to User Defined. 0 = sound is completely attenuated, 1 = sound is not attenuated at all. **Occlusion** If checked, attenuation based on the occlusion of the source by the scene geometry will be applied to the Audio Source. Occlusion: **Input** Specifies how the occlusion attenuation value is determined. Simulation Defined. Uses ray tracing to determine how much of the source is occluded. User Defined. Uses the Occlusion Value slider to control occlusion. The occlusion value will not automatically change based on surrounding geometry. You are expected to control the Occlusion Value slider using a custom script to achieve this effect. This option is intended for integrating your own occlusion model with Steam Audio. Occlusion: **Type** Specifies how rays should be traced to model occlusion. Raycast: Trace a single ray from the listener to the source. If the ray is occluded, the source is considered occluded. Volumetric: Trace multiple rays from the listener to the source based on the Occlusion Radius setting. The proportion of rays that are occluded determine how much of the direct sound is considered occluded. Transmission calculations, if enabled, are only applied to the occluded portion of the direct sound. Occlusion: **Radius** The apparent size of the sound source. The larger the source radius, the larger an object must be in order to fully occlude sound emitted by the source. Occlusion: **Samples** The number of rays to trace from the listener to various points in a sphere around the source. Only used if Occlusion Type is set to Volumetric. Increasing this number results in smoother transitions as the source becomes more (or less) occluded. This comes at the cost of increased CPU usage. Occlusion: **Value** The occlusion attenuation value. Only used if Occlusion Input is set to User Defined. 0 = sound is completely attenuated, 1 = sound is not attenuated at all. Occlusion: **Transmission** If checked, a filter based on the transmission of sound through occluding scene geometry will be applied to the Audio Source. Occlusion: **Type** Specifies how the transmission filter is applied. Frequency Independent. Transmission is modeled as a single attenuation factor. Frequency Dependent. Transmission is modeled as a 3-band EQ. Occlusion: **Input** Specifies how the transmission attenuation or EQ values are determined. Simulation Defined. Uses ray tracing to determine how much of the sound is transmitted. User Defined. Uses the Transmission Low, Transmission Mid, and Transmission High sliders to control transmission. The transmission values will not automatically change based on surrounding geometry. You are expected to control the sliders using a custom script to achieve this effect. This option is intended for integrating your own occlusion and transmission model with Steam Audio. Occlusion: **Low** The low frequency (up to 800 Hz) EQ value for transmission. Only used if Transmission Input is set to User Defined. 0 = low frequencies are completely attenuated, 1 = low frequencies are not attenuated at all. Occlusion: **Mid** The middle frequency (800 Hz to 8 kHz) EQ value for transmission. Only used if Transmission Input is set to User Defined. 0 = middle frequencies are completely attenuated, 1 = middle frequencies are not attenuated at all. Occlusion: **High** The high frequency (8 kHz and above) EQ value for transmission. Only used if Transmission Input is set to User Defined. 0 = high frequencies are completely attenuated, 1 = high frequencies are not attenuated at all. Occlusion: **Attenuation** The attenuation value for transmission. Only used if Transmission Input is set to User Defined. 0 = the sound is completely attenuated, 1 = the sound is not attenuated at all. Occlusion: **Max Surfaces** The maximum number of transmission surfaces, starting from the closest surface to the listener, whose transmission coefficients will be considered when calculating the total amount of sound transmitted. Increasing this value will result in more accurate results when multiple surfaces lie between the source and the listener, at the cost of increased CPU usage. **Direct Mix** The contribution of the direct sound path to the overall mix for this Audio Source. Lower values reduce the contribution more. **Reflections** If checked, reflections reaching the listener from the source will be simulated and applied to the Audio Source. Reflections: **Type** Specifies how reflections should be simulated for this source. Realtime. Rays are traced in real-time, and bounced around the scene to simulate sound reflecting from the source and reaching the listener. This allows for smooth variations, and reflections off of dynamic geometry, at the cost of significant CPU usage. Baked Static Source. The source is assumed to be static, and the listener position is used to interpolate reflected sound from baked data. This results in relatively low CPU usage, but cannot model reflections off of dynamic geometry, and requires more memory and disk space. Baked Static Listener. The listener is assumed to be static, and the source position is used to interpolate reflected sound from baked data. This results in relatively low CPU usage, but cannot model reflections off of dynamic geometry, and requires more memory and disk spac_**Use Distance Curve**_ Is shown when distance attenuation is enabled and is set to curve driven. Reflections: **Baked Source** If Reflections Type is set to Baked Static Source, the position and orientation of the GameObject specified in this field will be used as the position and orientation of the source. Reflections: **Apply HRTF** If checked, applies HRTF-based 3D audio rendering to reflections. Results in an improvement in spatialization quality when using convolution or hybrid reverb, at the cost of slightly increased CPU usage. Default: off. Warning, this might introduce distortions for louder sounds. Reflections: **Mix Level** The contribution of reflections to the overall mix for this Audio Source. Lower values reduce the contribution more. **Pathing** If checked, shortest paths taken by sound as it propagates from the source to the listener will be simulated, and appropriate spatialization will be applied to the Audio Source for these indirect paths. Pathing: **Probe Batch** When simulating pathing, the baked data stored in this probe batch will be used to look up paths from the source to the listener. Pathing: **Validation** If checked, each baked path from the source to the listener is checked in real-time to see if it is occluded by dynamic geometry. If so, the path is not rendered. Pathing: **Find Alternate** If checked, if a baked path from the source to the listener is found to be occluded by dynamic geometry, alternate paths are searched for in real-time, which account for the dynamic geometry. Pathing: **Apply HRTF** If checked, applies HRTF-based 3D audio rendering to pathing. Results in an improvement in spatialization quality, at the cost of slightly increased CPU usage. Default: off. Pathing: **Mix Level** The contribution of pathing to the overall mix for this Audio Source. Lower values reduce the contribution more. [PreviousSoundContainerchevron-left](https://sonity.gitbook.io/docs/soundcontainer) [NextSoundEventchevron-right](https://sonity.gitbook.io/docs/soundevent) Last updated 1 month ago sun-brightdesktopmoon sun-brightdesktopmoon --- # Modifiers | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FGadMTDgNLfDk1zHC0x9H%252FModifiers.gif%3Falt%3Dmedia%26token%3Dd47e3ff5-c014-471c-b5af-afcd22b5041f&width=768&dpr=3&quality=100&sign=a95bbb3b&sv=2) [Modifiers](https://sonity.gitbook.io/docs/modifiers) are used to control how [SoundEvents](https://sonity.gitbook.io/docs/soundevent) are played (e.g. volume, polyphony, fade in length etc). They are available on the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) , [SoundTrigger](https://sonity.gitbook.io/docs/soundtrigger) , [SoundPicker](https://sonity.gitbook.io/docs/soundpicker) and [SoundMix](https://sonity.gitbook.io/docs/soundmix) objects. They have similar functionality as the [SoundParameters](https://sonity.gitbook.io/docs/soundparameter) , but with visual editing. Modifiers are only updated once when starting the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) , not continuously. Some [modifiers](https://sonity.gitbook.io/docs/modifiers) use priorities to determine what a final [modifier](https://sonity.gitbook.io/docs/modifiers) value should be. The modifier with the highest priority will determine the value. * 1st: [SoundParameter](https://sonity.gitbook.io/docs/soundparameter) * 2nd: [SoundMix](https://sonity.gitbook.io/docs/soundmix) * 3rd: [SoundTrigger](https://sonity.gitbook.io/docs/soundtrigger) /[SoundPicker](https://sonity.gitbook.io/docs/soundpicker) * 4th: [SoundTag](https://sonity.gitbook.io/docs/soundtag) * 5th: [SoundEvent](https://sonity.gitbook.io/docs/soundevent) **Volume dB** Volume offset in decibel. Note that [modifiers](https://sonity.gitbook.io/docs/modifiers) are only updated once when starting the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . If you want realtime volume settings for a loop, use the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) base, timeline or [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) volume. **Pitch st** Pitch offset in semitones. **Delay** Increase the delay in seconds. **Start Position** Sets the start position, 0 is the start, 1 is the end. The highest priority added [modifier](https://sonity.gitbook.io/docs/modifiers) will determine the value. **Reverse** If enabled the AudioClip will be played backwards. Make sure to set the start position to the end. Reverse is only supported for AudioClips which are stored in an uncompressed format or will be decompressed at load time. The highest priority added [modifier](https://sonity.gitbook.io/docs/modifiers) will determine the value. **Distance Scale** Distance scale multiplier (how far it will be heard). It is multiplied by the Distance Scale of the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . **Reverb Zone Mix dB** Reverb Zone Mix volume offset in decibel. **Fade In Length** The length of the fade in. Is calculated using the time scale selected in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . The highest priority added [modifier](https://sonity.gitbook.io/docs/modifiers) will determine the value. **Fade In Shape** Shape of the fade in Negative is exponential, 0 is linear, positive is logarithmic. The highest priority added [modifier](https://sonity.gitbook.io/docs/modifiers) will determine the value. **Fade Out Length** The length of the fade out. Is calculated using the time scale selected in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . The highest priority added [modifier](https://sonity.gitbook.io/docs/modifiers) will determine the value. **Fade Out Shape** Shape of the fade out Negative is exponential, 0 is linear, positive is logarithmic. The highest priority added [modifier](https://sonity.gitbook.io/docs/modifiers) will determine the value. **Increase 2D** Makes the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) more 2D (less spatialized). Useful for first person sounds. **Stereo Pan** Stereo pan offset -1 is left, 0 is centered, +1 is right. **Intensity** Multiplier of any used [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) parameter. **Distortion Increase** Increases the distortion. Distortion needs to be enabled on the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) for this to have any effect. **Polyphony** How many instances of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) that can exist at the same transform. [Modifier](https://sonity.gitbook.io/docs/modifiers) polyphony overrides the [SoundEvents](https://sonity.gitbook.io/docs/soundevent) base Polyphony value. The highest priority added [modifier](https://sonity.gitbook.io/docs/modifiers) will determine the value. **Follow Position** If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should follow the given Transform position. The highest priority added [modifier](https://sonity.gitbook.io/docs/modifiers) will determine the value. **Bypass Reverb Zones** If enabled all reverb zones will be bypassed. The highest priority added [modifier](https://sonity.gitbook.io/docs/modifiers) will determine the value. **Bypass Voice Effects** If enabled all voice effects (lowpass/highpass/distortion) will be bypassed. The highest priority added [modifier](https://sonity.gitbook.io/docs/modifiers) will determine the value. **Bypass Listener Effects** If enabled all listener effects will be bypassed. The highest priority added [modifier](https://sonity.gitbook.io/docs/modifiers) will determine the value. [PreviousPlayMaker Integrationchevron-left](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration) [NextSoundParameterchevron-right](https://sonity.gitbook.io/docs/soundparameter) Last updated 1 month ago sun-brightdesktopmoon sun-brightdesktopmoon --- # SoundContainer | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FRGxiAKJ6Aq1NFeDRxhz9%252FSoundContainer%2520Base.png%3Falt%3Dmedia%26token%3D8c92641b-c9b0-402c-acb0-8662f04795f3&width=768&dpr=3&quality=100&sign=207f51c2&sv=2) [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) are the building blocks of Sonity. They contain AudioClips and options of how the sound should be played. All [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) are multi-object editable. Here is a description of controls shared by multiple fields. **Rolloff** The power of the rolloff. 0 is linear. **Curve** Curve of the value over distance or intensity. Distance: From 0 (close) to 1 (distant). Intensity: From 0 (soft) to 1 (hard). **Strength** How much effect the distance/intensity should have. **Increase** Increases the amount. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#notes) Notes Example note: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252F8lfdmz7z9ugp8lNHpwKs%252FSoundContainer%2520Notes.png%3Falt%3Dmedia%26token%3Dd680f7af-99e9-43c2-889d-0359aed09551&width=768&dpr=3&quality=100&sign=7d5d0ce3&sv=2) At the top of the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) there is a text field which you can fill with notes. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#presets) Presets ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FcVIDXGQUGoASliMJSaQf%2Fimage102.png&width=768&dpr=3&quality=100&sign=8a257bc3&sv=2) The “Presets” shown in the example picture above need to be created with the [SoundPreset](https://sonity.gitbook.io/docs/soundpreset) object. This info also shows up on button hover: **SFX 3D** Enable Distance = true Spatial Blend = 1 Never Steal Voice = false Never Steal Voice Effects = false Pitch Random = true Priority = 0.5 Reverb Zone Mix = -0 dB **SFX 2D** Enable Distance = false Spatial Blend = 0 Never Steal Voice = false Never Steal Voice Effects = false Pitch Random = true Priority = 0.5 Reverb Zone Mix = -0 dB **SFX 2D** Enable Distance = false Spatial Blend = 0 Never Steal Voice = false Never Steal Voice Effects = false Pitch Random = false Priority = 0.5 Reverb Zone Mix = Negative Infinity dB **Music** Enable Distance = false Spatial Blend = 0 Never Steal Voice = true Never Steal Voice Effects = true Pitch Random = false Volume Random = false Priority = 1 Reverb Zone Mix = Negative Infinity dB **Automatic Looping** If the name of the selected [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) contains “loop” then it will automatically enable “Loop”, “Follow Position”, “Stop if Transform is Null” and “Random Start Position”. **Automatic Crossfades** If the names of the selected [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) end in certain combinations it will automatically set up distance or intensity crossfades. It works on multiple groups at the same time. These are the combinations and their result: **Distance Crossfade:** Close + Distant + Far = 3 layers Close + Distant = 2 layers Close + Far = 2 layers **Intensity Crossfade:** Soft + Medium + Hard = 3 layers Soft + Hard = 2 layers Example usage of Automatic Crossfades: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252F5fdZvfE2eacGMndigrJw%252FSoundContainer%2520Automatic%2520Crossfades.gif%3Falt%3Dmedia%26token%3Deaf75ce1-274f-41e7-bf82-11a6f5a33194&width=768&dpr=3&quality=100&sign=d66fe912&sv=2) **SoundPresets** Create [SoundPreset](https://sonity.gitbook.io/docs/soundpreset) objects to get custom settings which you can apply to your [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) and [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . Either manually select the preset you want to apply in the dropdown, or use “Auto Match” to automatically apply the settings based on the name of the asset. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#preview) Preview ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FkiclNIk4wJ2tIZ7m0VOK%2Fimage94.gif&width=768&dpr=3&quality=100&sign=e932bbe5&sv=2) With the preview you can listen to the sounds in the editor. The preview handle enables you to move the sound around. **Preview Shortcuts** Play: Ctrl+Q (Previews the selected [SoundEvent](https://sonity.gitbook.io/docs/soundevent) or [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) ). Stop: Ctrl+W (Stops any playing preview of [SoundEvents](https://sonity.gitbook.io/docs/soundevent) and [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) , press two times to skip fade out). They are rebindable in the Shortcuts window. **Play** Previews the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) . Does not work if Unity cannot build the project, or if the game is paused. The default shortcut is Ctrl+Q. **Stop** Press two times to skip fade out. The default shortcut is Ctrl+W. **Reset** Resets the preview settings. **Intensity** Controls the intensity value of the played [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) . **AudioMixerGroup** Only used for preview. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#spatialization-info) Spatialization Info Show and edit spatialization info for the selected [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) . ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FV6mQ540zpQ97PaoveO14%2Fimage84.gif&width=768&dpr=3&quality=100&sign=c24dd9d2&sv=2) **3D Sounds** All [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) with Spatial Blend > 0 and Distance Enabled. **2D Sounds** All [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) with Spatial Blend = 0 and Distance Disabled. **3D Sound no Distance** All [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) with Spatial Blend > 0 and Distance Disabled. **2D Sound with Distance** All [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) with Spatial Blend = 0 and Distance Enabled. **Select SC** Selects [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) matching the specific settings. **Select All SC** Selects All [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) in the same folder disregarding subfolders. **Select AC** Selects AudioClips of the [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) matching the specific settings. **Set 3D** Sets the selected [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) to Spatial Blend 1 and Distance Enabled. **Set 2D** Sets the selected [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) to Spatial Blend 0 and Distance Disabled. **All Select AC** Selects all AudioClips of the selected [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) . **All Set 3D** Sets all selected [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) to Spatial Blend 1 and Distance Enabled. **All Set 2D** Sets all selected [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) to Spatial Blend 0 and Distance Disabled. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#audioclips) AudioClips ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FBfY1tFQEfTr8U4g4WZmu%2Fimage18.gif&width=768&dpr=3&quality=100&sign=57bca177&sv=2) This is where you assign the AudioClips which are going to be used when the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) is played. Update AudioClips ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FPNRBOX1I00N9upQs1HeL%252FSoundContainer%2520Update%2520AudioClips.png%3Falt%3Dmedia%26token%3D8c58be91-ad3f-4c09-b685-a78499d1b5ea&width=768&dpr=3&quality=100&sign=8f2a346a&sv=2) Updating AudioClips can be used to automatically add/remove variations. Can be used on multiple items at once (tip: search “t:SoundContainer”). **Refresh AudioClip Group** Adds all AudioClips with the same name as the first AudioClip (disregarding numbers, e.g. 01 02). **Find AudioClip Group** Automatically finds all AudioClips containing the same name as this [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) (disregarding \_SC, numbers). If no matching AudioClips are found, it will try and remove one character at the end of the name at a time until it finds a hit. **Drop AudioClips/Folders Here** Here you can drag and drop AudioClips or folders with AudioClips in them. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#settings) Settings ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FCy6eQoX1BrIpj8hOv0oD%252FSoundContainer%2520Settings.gif%3Falt%3Dmedia%26token%3D4566e1ba-fd7b-407c-b64b-4dfce5f83ec6&width=768&dpr=3&quality=100&sign=37a2d70c&sv=2) circle-info ❕ Tip: All the info is also available as tooltips if you hover over properties. **Enable Distance** Otherwise the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) will not be affected by distance (disable for music etc). **Distance Scale** Range scale multiplier. It is multiplied by the [Distance Scale](https://sonity.gitbook.io/docs/soundmanager#settings) of the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FPtKYuWHQbCR9dQqI9NeW%252FSoundContainer%2520Distance%2520Scale%2520Set%2520X%2520if%2520Y.png%3Falt%3Dmedia%26token%3D8be62e81-a37a-4652-bbf1-15d36e001a20&width=768&dpr=3&quality=100&sign=65fb9d2&sv=2) Distance Scale: **If X set to Y** Shows up if you have select multiple [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) with Distance Enabled. Useful for batch editing a lot of assets where you want to change the Distance Scale for many sounds. Distance Scale: **Replace Distance** Replaces any Distance Scale matching X with the Y value. Also shows the Min and Max value for Distance Scale of the selected objects. **Loop** Makes the sound loop. If you use "Create Assets from Selection" and the AudioClip name contains "loop". Then it will automatically enable “Loop”, “Follow Position”, “Stop if Transform is Null” and “Random Start Position”. **Follow Position** If the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) should follow the given Transform position. **Stop if Transform is Null** Automatically stops the sound if the Transform it's played at is destroyed (either the owner or position Transform). Useful safety precaution for loops. **Random Start Position** Starts the sound at a random position. Overrides the Start Position setting. Useful for loops. **Random Range** Min/max range within the sound can start at. **Start Position** 0 is the start and 1 is the end. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#advanced-settings) Advanced Settings **Reverse** If enabled the AudioClip will be played backwards. Make sure to set the start position to the end. Reverse is only supported for AudioClips which are stored in an uncompressed format or will be decompressed at load time. **Play Order** Determines in which order the AudioClips will be played. Play Order: **Global Random** All [SoundEvents](https://sonity.gitbook.io/docs/soundevent) will share the same global random AudioClip pool, which ensures less repetition. Uses a pseudo random function remembering half of the length of available AudioClips it last played to avoid repetition. Play Order: **Local Random** Same as global random except its per [SoundEvent](https://sonity.gitbook.io/docs/soundevent) owner. If enabled all will share the same global random AudioClip pool, which ensures less repetition. Otherwise random AudioClip per owner is used. The randomizer either way uses a pseudo random function remembering which AudioClips it last played to avoid repetition. **Priority** The priority the Voice has when Voice stealing. Also the priority the Voice Effects has when Voice Effects stealing. 1 is high priority, 0.5 is default priority and 0 is low priority. It's multiplied with the volume of the Voice when evaluating final priority. **Lock Axis** Locks the selected axis to the selected position. Useful for 2D games if you want to lock the sound to a position along an axis. Lock Axis: **Axis** The axis to lock. Lock Axis: **Position** The position to set the locked axis to. **Prevent End Clicks** If enabled it will fade out the volume 0.1 seconds before the end of the AudioClip to prevent clicks. If the AudioClips is shorter than 0.1 seconds or set to loop the fade will be skipped. DC offsets and some settings in Unity make an AudioClip click at the end. ❕ Tip: If you still experience sporadic clicks, try changing the Load Type of the AudioClips to e.g. "Compressed In Memory", it might help. **Never Steal Voice** The [SoundManager](https://sonity.gitbook.io/docs/soundmanager) will never steal this Voice if the Voice Limit is reached (use on music etc). **Never Steal Voice Effects** The [SoundManager](https://sonity.gitbook.io/docs/soundmanager) will never steal the Voice Effects on this Voice if the Voice Effect Limit is reached (use on music etc). **Doppler Amount** How much the pitch of the sound is changed by the relative velocity between the AudioListener and the AudioSource. **Bypass Reverb Zones** Bypasses any reverb zones **Bypass Voice Effects** Bypasses any effects on the AudioSource, e.g. Distortion and Filters. Voice effects are automatically bypassed if you don't have distortion/lowpass/highpass enabled. **Bypass Listener Effects** Bypasses any effects on the listener **HRTF Plugin Spatialize** Enables spatialization using external third party plugins. You need to add the plugin and select it in the project audio settings. These are some examples of compatible spatializers [(read more here)arrow-up-right](https://docs.unity3d.com/Manual/VRAudioSpatializer.html) * Steam Audio Spatializer * Oculus Spatializer Unity * Google Resonance Audio Spatializer * Vive 3DSP Audio SDK Spatializer * Microsoft Spatializer * Apple PHASE Spatializer * Qualcomm 3D Spatializer **HRTF Plugin Post Effects** If the spatialization plugin effect happens before before or after any effects. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#steam-audio-settings) Steam Audio Settings Read the "[Steam Audio](https://sonity.gitbook.io/docs/soundcontainer/steam-audio-settings) " sub-page to learn more. ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FkMkJS2ImzjJlenp7pUHz%252FSoundContainer%2520Settings%2520Steam%2520Audio.gif%3Falt%3Dmedia%26token%3D96534647-4506-4e52-a627-8ff7af65c2ce&width=768&dpr=3&quality=100&sign=78f0cfd2&sv=2) ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#volume) Volume ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FhtiKZ2VRAHqW1ntsn4Ho%252FSoundContainer%2520Volume.gif%3Falt%3Dmedia%26token%3Dbb599b78-2f36-45cc-960d-0cddd19b3988&width=768&dpr=3&quality=100&sign=8f011c3f&sv=2) **Volume dB** Volume offset in decibel. If you want to be able to raise the volume and not just lower it you have 2 options: **Increase Volume - Option A:** Enable "Enable Volume Increase" in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . This will enable you to raise the volumes of [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) and [SoundEvents](https://sonity.gitbook.io/docs/soundevent) by +24 dB each and [SoundVolumeGroups](https://sonity.gitbook.io/docs/soundvolumegroup) by +12dB. **Increase Volume - Option B:** Select all the [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) and lower the volume by -20 dB with the -1dB button. Then to compensate you can increase the global volume with an Audio Mixer (which you then can set to +20 dB). **\-1 dB** Lowers the relative volume of all the selected [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) . Useful for example if you want to raise the volume of one [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) and keep the relative volume. Because then you can lower all of them to get more headroom. If multiple [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) are selected it will show the lowest volume. **+1 dB** Raises the relative volume of all the selected [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) . Useful for example if you want to set the loudest volume to 0 dB but keep the relative volumes. If multiple [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) are selected it will show the highest volume. **Distance Crossfade** With distance crossfade you can easily crossfade between different sounds over distance. For e.g. gunshots you could add sounds with close, distant and far perspectives. You’d set the “Layers” setting to 3 for all the [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) . Then you’d set “This Is” of close to 1, distant to 2 and far to 3. Distance Crossfade: **Layers** The number of layers the crossfade is based on. You must have at least 2 layers. Distance Crossfade: **This is** Which layer this is. Set up with other [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) for the other layers. Lower numbers are closer and higher are more distant. **Intensity** Changes the volume over intensity. Use on for example physics sounds where you pass the velocity with a [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) . **Intensity Crossfade** With intensity crossfade you can easily crossfade between different sounds over intensity. For e.g. impacts you could add sounds with hard, medium and soft variations. You’d set the “Layers” setting to 3 for all the [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) . Then you’d set “This Is” of hard to 3, medium to 2 and soft to 1. Intensity Crossfade: **Layers** The number of layers the crossfade is based on. You must have at least 2 layers. Intensity Crossfade: **This is** Which layer this is. Set up with other [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) for the other layers. Higher numbers are harder and lower numbers are softer. Intensity Crossfade example: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FvWzDYPHipR3DW1Z0z84t%252FSoundContainer%2520Intensity%2520Crossfade%2520example.gif%3Falt%3Dmedia%26token%3D2549c0f6-1427-4d7f-b5af-eb09bcd52747&width=768&dpr=3&quality=100&sign=8399a8a&sv=2) ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#pitch) Pitch ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FQp5zKSz1Nehy8ZHDEYJQ%252FSoundContainer%2520Pitch.gif%3Falt%3Dmedia%26token%3D90fb3331-c211-4e7e-a08a-eec727e4befb&width=768&dpr=3&quality=100&sign=93007ab7&sv=2) Controls the pitch (in semitones). **Intensity** Changes the pitch over intensity. Use on for example car sounds where you pass the speed with a [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) . Intensity: **Low st** The lowest intensity in semitones. Range -128 to 128. Intensity: **High st** The highest intensity in semitones. Range -128 to 128. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#spatial-blend) Spatial Blend ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FiEZyYjQ35zfoQqhM0YE1%252FSoundContainer%2520Spatial%2520Blend.gif%3Falt%3Dmedia%26token%3D37aa595a-9e74-4ffb-8254-18bc0d5021cf&width=768&dpr=3&quality=100&sign=cd8278ae&sv=2) Controls the spatial blend. 0 is 2D (not spatialized) and 1 is 3D (spatialized). **Intensity** Changes the spatial blend over intensity. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#spatial-spread) Spatial Spread ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FU8eANXVEIhbLOTrOpMRr%252FSoundContainer%2520Spatial%2520Spread.gif%3Falt%3Dmedia%26token%3D90a47ae1-f1d5-47a3-942d-f85ad1e53d75&width=768&dpr=3&quality=100&sign=49fb67b9&sv=2) Controls the spatial spread (in degrees). Only the 3D (spatialized) part of the sound is affected by the spatial spread. **Intensity** Changes the spatial spread over intensity. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#stereo-pan) Stereo Pan ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FfxzxohPsZ3iH0p95g97D%2Fimage100.gif&width=768&dpr=3&quality=100&sign=7af7b8f5&sv=2) Controls the stereo pan. -1 is left and 1 right. Only the 2D part of the sound is affected by the stereo pan. **Angle To Stereo Pan** Pans the sound depending on the angle between the Voice and the AudioListener. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#reverb-zone-mix) Reverb Zone Mix ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FRTIqQHPXRZCYCRamnM4j%252FSoundContainer%2520Reverb%2520Zone%2520Mix.gif%3Falt%3Dmedia%26token%3Da82d4a96-619b-4641-ae4d-cc1daf1109f5&width=768&dpr=3&quality=100&sign=b7976ef0&sv=2) Controls the reverb zone mix (in decibel). **Intensity** Changes the reverb zone mix over intensity. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#distortion) Distortion ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FnQGS2pREY1DdX89j9wqf%252FSoundContainer%2520Distortion.gif%3Falt%3Dmedia%26token%3D392aed3f-53da-4717-8319-ccbf23e6c6c6&width=768&dpr=3&quality=100&sign=b53e7fc2&sv=2) Waveshaper type distortion. 0 is clean, 1 is distorted. [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) Voice Effects are applied per Voice. If distortion amount is 0 the effect is disabled internally for performance. The number of active Voice Effects are limited by the “Voice Effect Limit” on the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . DSP effects are not available in WebGL. **Intensity** Changes the distortion over intensity. Use on for example explosion sounds where you pass the size of the explosion with a [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) . ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#lowpass) Lowpass ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2F0qk3xChsJQ24x7cS6eCc%2Fimage12.gif&width=768&dpr=3&quality=100&sign=5e855642&sv=2) Lowpass filter with a variable amount. Maximum of 6dB per octave. [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) Voice Effects are applied per Voice. If frequency is 20,000 Hz or amount is 0 dB the effect is disabled internally for performance. The number of active Voice Effects are limited by the “Voice Effect Limit” on the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . DSP effects are not available in WebGL. **Intensity** Changes the lowpass over intensity. Use on for example occluded sounds where you pass the amount of occlusion with [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) . ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#highpass) Highpass ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FnRMU7bAWMEF3ZPWWTH3r%2Fimage25.gif&width=768&dpr=3&quality=100&sign=6ceb7717&sv=2) Highpass filter with a variable amount. Maximum of 6dB per octave. [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) Voice Effects are applied per Voice. If frequency is 20 Hz or amount is 0 dB the effect is disabled internally for performance. The number of active Voice Effects are limited by the “Voice Effect Limit” on the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . DSP effects are not available in WebGL. **Intensity** Changes the highpass over intensity. Use on for example occluded sounds where you pass the amount of occlusion with [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) . ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#find-references) Find References ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2F6OsEFaNRUE3tSSHgQBpr%2Fimage21.gif&width=768&dpr=3&quality=100&sign=4c1bb2e1&sv=2) **Find References** Finds all the references to the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) . **Select All** Selects all the assets with references to the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) . **Clear** Removes all the found references. ### [hashtag](https://sonity.gitbook.io/docs/soundcontainer#asset-guid) Asset GUID The ID of an asset is cached in the editor because in some cases when using addressables a single scriptable object might be instantiated multiple times. This might lead to problems where a simple "Object == Object" check will return false, but a "ID == ID" will return true. If you are upgrading Sonity and use addressable assets you probably want to select all Sonity scriptable objects and run: "Tools/Sonity 🔊/Set Selected Assets as Dirty (Force Reserialize for Resave)" which will force the assets to cache the GUIDs. You can search t:[SoundEvent](https://sonity.gitbook.io/docs/soundevent) , t:[SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) , t:[SoundTag](https://sonity.gitbook.io/docs/soundtag) , t:[SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) , t:[SoundDataGroup](https://sonity.gitbook.io/docs/sounddatagroup) , t:[SoundMix](https://sonity.gitbook.io/docs/soundmix) , t:[SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics) to find all objects. If no GUID is cached then it will use the InstanceID in builds. The free trial version doesn't have full functionality. [PreviousForce Resave Assetschevron-left](https://sonity.gitbook.io/docs/how-to-guides/force-resave-assets) [NextSteam Audio Settingschevron-right](https://sonity.gitbook.io/docs/soundcontainer/steam-audio-settings) Last updated 1 month ago * [Notes](https://sonity.gitbook.io/docs/soundcontainer#notes) * [Presets](https://sonity.gitbook.io/docs/soundcontainer#presets) * [Preview](https://sonity.gitbook.io/docs/soundcontainer#preview) * [Spatialization Info](https://sonity.gitbook.io/docs/soundcontainer#spatialization-info) * [AudioClips](https://sonity.gitbook.io/docs/soundcontainer#audioclips) * [Settings](https://sonity.gitbook.io/docs/soundcontainer#settings) * [Advanced Settings](https://sonity.gitbook.io/docs/soundcontainer#advanced-settings) * [Steam Audio Settings](https://sonity.gitbook.io/docs/soundcontainer#steam-audio-settings) * [Volume](https://sonity.gitbook.io/docs/soundcontainer#volume) * [Pitch](https://sonity.gitbook.io/docs/soundcontainer#pitch) * [Spatial Blend](https://sonity.gitbook.io/docs/soundcontainer#spatial-blend) * [Spatial Spread](https://sonity.gitbook.io/docs/soundcontainer#spatial-spread) * [Stereo Pan](https://sonity.gitbook.io/docs/soundcontainer#stereo-pan) * [Reverb Zone Mix](https://sonity.gitbook.io/docs/soundcontainer#reverb-zone-mix) * [Distortion](https://sonity.gitbook.io/docs/soundcontainer#distortion) * [Lowpass](https://sonity.gitbook.io/docs/soundcontainer#lowpass) * [Highpass](https://sonity.gitbook.io/docs/soundcontainer#highpass) * [Find References](https://sonity.gitbook.io/docs/soundcontainer#find-references) * [Asset GUID](https://sonity.gitbook.io/docs/soundcontainer#asset-guid) sun-brightdesktopmoon sun-brightdesktopmoon --- # Third Party Integrations | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FS3jxczcjtlKbDOizw9Qs%252FSoundManager%2520Integrations.png%3Falt%3Dmedia%26token%3D8a208d37-fe38-4d61-b15d-f68c90367d29&width=768&dpr=3&quality=100&sign=5d721abd&sv=2) You can enable the integrations in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager#third-party-integrations) . ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations#steam-audio-integration) [Steam Audio Integration](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration) How to enable and use the Steam Audio integration in Sonity ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations#playmaker-integration) [PlayMaker Integration](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration) How to enable and use the PlayMaker integration in Sonity [PreviousSoundManager Functionschevron-left](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions) [NextSteam Audio Integrationchevron-right](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration) Last updated 1 month ago * [Steam Audio Integration](https://sonity.gitbook.io/docs/third-party-integrations#steam-audio-integration) * [PlayMaker Integration](https://sonity.gitbook.io/docs/third-party-integrations#playmaker-integration) sun-brightdesktopmoon sun-brightdesktopmoon --- # SoundEvent Functions | Sonity Docs The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) can be played directly from itself instead of playing via the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . A [SoundManager](https://sonity.gitbook.io/docs/soundmanager) instance in the scene is required to play [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . Example code: Copy using UnityEngine; using Sonity; public class PlayStopExample : MonoBehaviour { public SoundEvent soundEvent; void PlayExample() { // Plays the SoundEvent at the position of the transform soundEvent.Play(transform); } void StopExample() { // Stops the SoundEvent playing at the transform soundEvent.Stop(transform); } } ### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#play) Play Parameters owner The owner Transform localSoundTag The [SoundTag](https://sonity.gitbook.io/docs/soundtag) which will determine the Local [SoundTag](https://sonity.gitbook.io/docs/soundtag) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) soundParameterInternals For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#h.ciw7d4iq7bvo) is used to modify how the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played ### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#playatposition) PlayAtPosition Parameters owner The owner Transform position The Transform or Vector3 where is should play at (Transform can follow position) localSoundTag The [SoundTag](https://sonity.gitbook.io/docs/soundtag) which will determine the Local [SoundTag](https://sonity.gitbook.io/docs/soundtag) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) soundParameterInternals For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#h.ciw7d4iq7bvo) is used to modify how the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played ### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#stop) Stop circle-info 💡 TIP - Stopping Loops You really only need to use stop for looping or longer oneshot sounds (or the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) “Stop if Transform is Null” setting). Use the polyphony setting in the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to manage the number of instances playing. Parameters owner The owner Transform position The position Transform allowFadeOut If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be allowed to fade out. Otherwise it is going to be stopped immediately ### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#pause-and-unpause) Pause and Unpause Parameters owner The owner Transform forcePause If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be paused even if it is set to "Ignore Local Pause" ### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#get-state-length-time-and-contains-loop) Get State, Length, Time and Contains Loop Parameters owner The owner Transform pitchSpeed Determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long ### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#get-spectrum-data) Get Spectrum Data Parameters owner The owner Transform samples The array to populate with audio samples. Its length must be a power of 2 channel The channel to sample from window The FFTWindow type to use when sampling spectrumDataFrom Where to get the spectrum data from ### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#get-last-played-audiosource) Get Last Played AudioSource Parameters owner The owner Transform ### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#load-or-unload-audio-data) Load or Unload Audio Data ### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#ui-functions) UI Functions Useful if you want to play [SoundEvents](https://sonity.gitbook.io/docs/soundevent) without passing an owner. #### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#ui-play) **UI Play** Parameters localSoundTag The [SoundTag](https://sonity.gitbook.io/docs/soundtag) which will determine the Local [SoundTag](https://sonity.gitbook.io/docs/soundtag) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) soundParameterInternals For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundparameter) is used to modify how the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played position The Transform or Vector3 where is should play at (Transform can follow position) #### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#ui-stop) UI Stop Parameters allowFadeOut If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be allowed to fade out. Otherwise it is going to be stopped immediately #### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#ui-pause-and-unpause) UI Pause and Unpause Parameters forcePause If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be paused even if it is set to "Ignore Local Pause" #### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#ui-get-state-length-and-time) UI Get State, Length and Time Parameters pitchSpeed Determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long ### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#music-functions) Music Functions #### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#music-play) Music Play Useful if you want to play music with automatic stopping of the old music when playing a new song. Parameters stopAllOtherMusic If all other [SoundEvents](https://sonity.gitbook.io/docs/soundevent) played at the SoundManager music Transform should be stopped allowFadeOut If the other stopped [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be allowed to fade out. Otherwise they are going to be stopped immediately soundParameterInternals For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundparameter) is used to modify how the SoundEvent is played #### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#music-stop) Music Stop Parameters allowFadeOut If the other stopped [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be allowed to fade out. Otherwise they are going to be stopped immediately #### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#music-pause-and-unpause) Music Pause and Unpause Parameters forcePause If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be paused even if it is set to "Ignore Local Pause" #### [hashtag](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#music-get-state-length-and-time) Music Get State, Length and Time Parameters pitchSpeed Determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long [PreviousSoundEventchevron-left](https://sonity.gitbook.io/docs/soundevent) [NextSoundManagerchevron-right](https://sonity.gitbook.io/docs/soundmanager) Last updated 1 month ago * [Play](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#play) * [PlayAtPosition](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#playatposition) * [Stop](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#stop) * [Pause and Unpause](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#pause-and-unpause) * [Get State, Length, Time and Contains Loop](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#get-state-length-time-and-contains-loop) * [Get Spectrum Data](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#get-spectrum-data) * [Get Last Played AudioSource](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#get-last-played-audiosource) * [Load or Unload Audio Data](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#load-or-unload-audio-data) * [UI Functions](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#ui-functions) * [Music Functions](https://sonity.gitbook.io/docs/soundevent/soundevent-functions#music-functions) sun-brightdesktopmoon Copy // Plays the SoundEvent at the position of the owner Transform public void Play(Transform owner); public void Play(Transform owner, SoundTag localSoundTag); public void Play(Transform owner, params SoundParameterInternals[] soundParameterInternals); public void Play(Transform owner, SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); Copy // Plays the SoundEvent at the Vector3 position with another Transform as the owner public void PlayAtPosition(Transform owner, Vector3 position); public void PlayAtPosition(Transform owner, Vector3 position, SoundTag localSoundTag); public void PlayAtPosition(Transform owner, Vector3 position, params SoundParameterInternals[] soundParameterInternals); public void PlayAtPosition(Transform owner, Vector3 position, SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); // Plays the SoundEvent at the Transform position with another Transform as the owner public void PlayAtPosition(Transform owner, Transform position); public void PlayAtPosition(Transform owner, Transform position, SoundTag localSoundTag); public void PlayAtPosition(Transform owner, Transform position, params SoundParameterInternals[] soundParameterInternals); public void PlayAtPosition(Transform owner, Transform position, SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); Copy // Pauses/unpauses the SoundEvent with the owner Transform locally public void Pause(Transform owner, bool forcePause = false); public void Unpause(Transform owner); // Pauses/unpauses all SoundEvents with the owner Transform locally public void PauseAllAtOwner(bool forcePause = false); public void UnpauseAllAtOwner(); // Pauses/unpauses the SoundEvent everywhere locally public void PauseEverywhere(bool forcePause = false); public void UnpauseEverywhere(); // Pauses/unpauses the SoundEvent everywhere locally public void PauseEverything(bool forcePause = false); public void UnpauseEverything(); Copy // Pauses/unpauses the SoundEvent with the owner Transform locally public void Pause(Transform owner, bool forcePause = false); public void Unpause(Transform owner); // Pauses/unpauses all SoundEvents with the owner Transform locally public void PauseAllAtOwner(bool forcePause = false); public void UnpauseAllAtOwner(); // Pauses/unpauses the SoundEvent everywhere locally public void PauseEverywhere(bool forcePause = false); public void UnpauseEverywhere(); // Pauses/unpauses the SoundEvent everywhere locally public void PauseEverything(bool forcePause = false); public void UnpauseEverything(); Copy // If playing it returns SoundEventState.Playing // If paused either locally or globally it returns SoundEventState.Paused // If not playing, but it is delayed it returns SoundEventState.Delayed // If not playing and it is not delayed it returns SoundEventState.NotPlaying // If the SoundEvent or Transform is null it returns SoundEventState.NotPlaying public SoundEventState GetSoundEventState(Transform owner); // Returns the length (in seconds) of the AudioClip in the last played AudioSource // Returns Mathf.Infinity if the InstanceSoundEvent is not playing // Returns Mathf.Infinity if the SoundEvent or Transform is null // pitchSpeed determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long public float GetLastPlayedClipLength(Transform owner, bool pitchSpeed); // Returns the current time (in seconds) of the AudioClip in the last played AudioSource // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null // pitchSpeed determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long public float GetLastPlayedClipTimeSeconds(Transform owner, bool pitchSpeed); // Returns the current time (in range 0 to 1) of the AudioClip in the last played AudioSource // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null public float GetLastPlayedClipTimeRatio(Transform owner); // Returns the max length (in seconds) of the SoundEvent (calculated from the longest audioClip) // Is scaled by the pitch of the SoundEvent and SoundContainer // Does not take into account random, intensity or parameter pitch public float GetMaxLength(); // Returns the time (in seconds) since the SoundEvent was played // Is calculated using the time scale selected in the SoundManager // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null public float GetTimePlayed(Transform owner); // Returns if any SoundContainers in the SoundEvent is set to looping public bool GetContainsLoop(); Copy // Provides a block of spectrum data from AudioSources public void GetSpectrumData(Transform owner, ref float[] samples, int channel, FFTWindow window, SpectrumDataFrom spectrumDataFrom); Copy // Returns the last played AudioSource // Note that the AudioSource might be stolen or reused for different Voices over time public AudioSource GetLastPlayedAudioSource(Transform owner); Copy // Loads the audio data of any AudioClips assigned to the SoundContainers of the SoundEvent public void LoadAudioData(); // Unloads the audio data of any AudioClips assigned to the SoundContainers of the SoundEvent public void UnloadAudioData(); Copy // Plays the SoundEvent with the UI Transform as owner // Useful to play e.g. UI or other 2D sounds without having to pass a Transform // To make the sound 2D you still need to disable distance and set spatial blend to 0 in the SoundContainer public void UIPlay(); public void UIPlay(SoundTag localSoundTag); public void UIPlay(params SoundParameterInternals[] soundParameterInternals); public void UIPlay(SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); // Plays the SoundEvent at the position with the UI Transform as owner (Useful for UnityEvents because it only has one parameter) public void UIPlayAtPosition(Vector3 position); public void UIPlayAtPosition(Transform position); Copy // Stops the SoundEvent at the UI Transform public void UIStop(bool allowFadeOut = true); // Stops all SoundEvents at the UI Transform public void UIStopAll(bool allowFadeOut = true); Copy // Pauses/unpauses the SoundEvent at the UI Transform locally public void UIPause(bool forcePause = false); public void UIUnpause(); // Pauses/unpauses all SoundEvents at the UI Transform locally public void UIPauseAll(bool forcePause = false); public void UIUnpauseAll(); Copy // Uses the UI owner Transform // If playing it returns SoundEventState.Playing // If paused either locally or globally it returns SoundEventState.Paused // If not playing, but it is delayed it returns SoundEventState.Delayed // If not playing and it is not delayed it returns SoundEventState.NotPlaying // If the SoundEvent or Transform is null it returns SoundEventState.NotPlaying public SoundEventState UIGetSoundEventState(); // Uses the UI owner Transform // Returns the length (in seconds) of the AudioClip in the last played AudioSource // Returns Mathf.Infinity if the InstanceSoundEvent is not playing // Returns Mathf.Infinity if the SoundEvent or Transform is null // pitchSpeed determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long public float UIGetLastPlayedClipLength(bool pitchSpeed); // Uses the UI owner Transform // Returns the current time (in seconds) of the AudioClip in the last played AudioSource // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null // pitchSpeed determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long public float UIGetLastPlayedClipTimeSeconds(bool pitchSpeed); // Uses the UI owner Transform // Returns the current time (in range 0 to 1) of the AudioClip in the last played AudioSource // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null public float UIGetLastPlayedClipTimeRatio(); // Uses the UI owner Transform // Returns the time (in seconds) since the SoundEvent was played // Is calculated using the time scale selected in the SoundManager // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null public float UIGetTimePlayed(); // Returns the owner Transform used by UIPlay() etc public Transform UIGetTransform(); Copy // Plays the SoundEvent at the SoundManagers music Transform public void MusicPlay(bool stopAllOtherMusic = true, bool allowFadeOut = true); public void MusicPlay(bool stopAllOtherMusic = true, bool allowFadeOut = true, params SoundParameterInternals[] soundParameterInternals); // Plays allowing fade out (Useful for UnityEvents because it only has one parameter) public void MusicPlayAllowFadeOut(bool stopAllOtherMusic = true); // Plays without fade out (Useful for UnityEvents because it only has one parameter) public void MusicPlayImmediate(bool stopAllOtherMusic = true); Copy // Stops the SoundEvent playing at the Music Transform public void MusicStop(bool allowFadeOut = true); // Stops all the SoundEvents playing at the Music music Transform public void AllMusicStop(bool allowFadeOut = true); Copy // Pauses/unpauses the SoundEvent at the Music Transform locally public void MusicPause(bool forcePause = false); public void MusicUnpause(); // Pauses/unpauses all SoundEvents at the Music Transform locally public void AllMusicPause(bool forcePause = false); public void AllMusicUnpause(); Copy // Uses the Music owner Transform // If playing it returns SoundEventState.Playing // If paused either locally or globally it returns SoundEventState.Paused // If not playing, but it is delayed it returns SoundEventState.Delayed // If not playing and it is not delayed it returns SoundEventState.NotPlaying // If the SoundEvent or Transform is null it returns SoundEventState.NotPlaying public SoundEventState MusicGetSoundEventState(); // Uses the Music owner Transform // Returns the length (in seconds) of the AudioClip in the last played AudioSource // Returns Mathf.Infinity if the InstanceSoundEvent is not playing // Returns Mathf.Infinity if the SoundEvent or Transform is null // pitchSpeed determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long public float MusicGetLastPlayedClipLength(bool pitchSpeed); // Uses the Music owner Transform // Returns the current time (in seconds) of the AudioClip in the last played AudioSource // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null // pitchSpeed determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long public float MusicGetLastPlayedClipTimeSeconds(bool pitchSpeed); // Uses the Music owner Transform // Returns the current time (in range 0 to 1) of the AudioClip in the last played AudioSource // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null public float MusicGetLastPlayedClipTimeRatio(); // Uses the Music owner Transform // Returns the time (in seconds) since the SoundEvent was played // Is calculated using the time scale selected in the SoundManager // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null public float MusicGetTimePlayed(); // Returns the owner Transform used by PlayMusic() etc public Transform MusicGetTransform(); sun-brightdesktopmoon --- # SoundManager Functions | Sonity Docs The [SoundManager](https://sonity.gitbook.io/docs/soundmanager) is the master object which is used to play sounds and manage global settings. An instance in the scene is required to play [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . You can either add the pre-made prefab called “SoundManager” or add the “Sonity - Sound Manager” component to an empty GameObject in the scene. Example code: Copy using UnityEngine; using Sonity; public class PlayStopExample : MonoBehaviour { public SoundEvent soundEvent; void PlayExample() { // Plays the SoundEvent at the position of the transform SoundManager.Instance.Play(soundEvent, transform); } void StopExample() { // Stops the SoundEvent playing at the transform SoundManager.Instance.Stop(soundEvent, transform); } } ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#play) Play Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to play owner The owner Transform localSoundTag The [SoundTag](https://sonity.gitbook.io/docs/soundtag) which will determine the Local [SoundTag](https://sonity.gitbook.io/docs/soundtag) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) soundParameterInternals For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundparameter) is used to modify how the SoundEvent is played ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#playatposition) PlayAtPosition Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to play owner The owner Transform position The Transform or Vector3 where is should play at (Transform can follow position) localSoundTag The [SoundTag](https://sonity.gitbook.io/docs/soundtag) which will determine the Local [SoundTag](https://sonity.gitbook.io/docs/soundtag) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) soundParameterInternals For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundparameter) is used to modify how the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#stop) Stop Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to stop owner The owner Transform position The position Transform allowFadeOut If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be allowed to fade out. Otherwise it is going to be stopped immediately ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#pause-and-unpause) Pause and Unpause Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to pause/unpause owner The owner Transform forcePause If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be paused even if it is set to "Ignore Local Pause" ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#get-state-length-time-and-contains-loop) Get State, Length, Time and Contains Loop Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to get length or time from owner The owner Transform pitchSpeed Determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#get-spectrum-data) Get Spectrum Data Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to get the spectrum data from owner The owner Transform samples The array to populate with audio samples. Its length must be a power of 2 channel The channel to sample from window The FFTWindow type to use when sampling spectrumDataFrom Where to get the spectrum data from ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#get-last-played-audiosource) Get Last Played AudioSource Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to get the AudioSource from owner The owner Transform ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#load-or-unload-audio-data) Load or Unload Audio Data ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#ui) UI Useful if you want to play [SoundEvents](https://sonity.gitbook.io/docs/soundevent) without passing an owner. #### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#ui-play) UI Play Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to play localSoundTag The [SoundTag](https://sonity.gitbook.io/docs/soundtag) which will determine the Local [SoundTag](https://sonity.gitbook.io/docs/soundtag) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) soundParameterInternals For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundparameter) is used to modify how the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played position The Transform or Vector3 where is should play at (Transform can follow position) #### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#ui-stop) UI Stop Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to stop allowFadeOut If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be allowed to fade out. Otherwise it is going to be stopped immediately #### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#ui-pause-and-unpause) UI Pause and Unpause Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to pause/unpause forcePause If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be paused even if it is set to "Ignore Local Pause" #### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#ui-get-state-length-and-time) UI Get State, Length and Time Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to get length or time from pitchSpeed Determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#music) Music Useful if you want to play music with automatic stopping of the old music when playing a new song. #### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#music-play) Music Play Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to play stopAllOtherMusic If all other [SoundEvents](https://sonity.gitbook.io/docs/soundevent) played at the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) music Transform should be stopped allowFadeOut If the other stopped [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be allowed to fade out. Otherwise they are going to be stopped immediately soundParameterInternals For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundparameter) is used to modify how the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played #### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#music-stop) Music Stop Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to stop allowFadeOut If the other stopped [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be allowed to fade out. Otherwise they are going to be stopped immediately #### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#music-pause-and-unpause) Music Pause and Unpause #### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#music-get-state-length-and-time) Music Get State, Length and Time Parameters soundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to get length or time from pitchSpeed Determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#global-pause-and-unpause) Global Pause and Unpause ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#global-volume) Global Volume ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#global-soundtag) Global SoundTag ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#global-distance-scale) Global Distance Scale ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#speed-of-sound) Speed Of Sound ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#voice-limit) Voice Limit ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#disable-playing-sounds) Disable Playing Sounds ### [hashtag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#get-addressable-audiomixer) Get Addressable AudioMixer [PreviousEditor Toolschevron-left](https://sonity.gitbook.io/docs/soundmanager/editor-tools) [NextThird Party Integrationschevron-right](https://sonity.gitbook.io/docs/third-party-integrations) Last updated 1 month ago * [Play](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#play) * [PlayAtPosition](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#playatposition) * [Stop](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#stop) * [Pause and Unpause](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#pause-and-unpause) * [Get State, Length, Time and Contains Loop](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#get-state-length-time-and-contains-loop) * [Get Spectrum Data](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#get-spectrum-data) * [Get Last Played AudioSource](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#get-last-played-audiosource) * [Load or Unload Audio Data](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#load-or-unload-audio-data) * [UI](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#ui) * [Music](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#music) * [Global Pause and Unpause](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#global-pause-and-unpause) * [Global Volume](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#global-volume) * [Global SoundTag](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#global-soundtag) * [Global Distance Scale](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#global-distance-scale) * [Speed Of Sound](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#speed-of-sound) * [Voice Limit](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#voice-limit) * [Disable Playing Sounds](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#disable-playing-sounds) * [Get Addressable AudioMixer](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions#get-addressable-audiomixer) sun-brightdesktopmoon Copy // Plays the SoundEvent at the position of the owner Transform public void Play(SoundEvent soundEvent, Transform owner); public void Play(SoundEvent soundEvent, Transform owner, SoundTag localSoundTag); public void Play(SoundEvent soundEvent, Transform owner, params SoundParameterInternals[] soundParameterInternals); public void Play(SoundEvent soundEvent, Transform owner, SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); Copy // Plays the SoundEvent at the Vector3 position with another Transform as the owner public void PlayAtPosition(SoundEvent soundEvent, Transform owner, Vector3 position); public void PlayAtPosition(SoundEvent soundEvent, Transform owner, Vector3 position, SoundTag localSoundTag); public void PlayAtPosition(SoundEvent soundEvent, Transform owner, Vector3 position, params SoundParameterInternals[] soundParameterInternals); public void PlayAtPosition(SoundEvent soundEvent, Transform owner, Vector3 position, SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); // Plays the SoundEvent at the Transform position with another Transform as the owner public void PlayAtPosition(SoundEvent soundEvent, Transform owner, Transform position); public void PlayAtPosition(SoundEvent soundEvent, Transform owner, Transform position, SoundTag localSoundTag); public void PlayAtPosition(SoundEvent soundEvent, Transform owner, Transform position, params SoundParameterInternals[] soundParameterInternals); public void PlayAtPosition(SoundEvent soundEvent, Transform owner, Transform position, SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); Copy // Stops the SoundEvent at the owner Transform public void Stop(SoundEvent soundEvent, Transform owner, bool allowFadeOut = true); // Stops the SoundEvent at the position Transform public void StopAtPosition(SoundEvent soundEvent, Transform position, bool allowFadeOut = true); // Stops all the SoundEvents at the owner Transform public void StopAllAtOwner(Transform owner, bool allowFadeOut = true); // Stops the SoundEvent everywhere public void StopEverywhere(SoundEvent soundEvent, bool allowFadeOut = true); // Stops all SoundEvents public void StopEverything(bool allowFadeOut = true); Copy // Pauses/unpauses the SoundEvent with the owner Transform locally public void Pause(SoundEvent soundEvent, Transform owner, bool forcePause = false); public void Unpause(SoundEvent soundEvent, Transform owner); // Pauses/unpauses all SoundEvents with the owner Transform locally public void PauseAllAtOwner(Transform owner, bool forcePause = false); public void UnpauseAllAtOwner(Transform owner); // Pauses/unpauses the SoundEvent everywhere locally public void PauseEverywhere(SoundEvent soundEvent, bool forcePause = false); public void UnpauseEverywhere(SoundEvent soundEvent); // Pauses/unpauses the SoundEvent everywhere locally public void PauseEverything(bool forcePause = false); public void UnpauseEverything(); Copy // If playing it returns SoundEventState.Playing // If paused either locally or globally it returns SoundEventState.Paused // If not playing, but it is delayed it returns SoundEventState.Delayed // If not playing and it is not delayed it returns SoundEventState.NotPlaying // If the SoundEvent or Transform is null it returns SoundEventState.NotPlaying public SoundEventState GetSoundEventState(SoundEvent soundEvent, Transform owner); // Returns the length (in seconds) of the AudioClip in the last played AudioSource // Returns Mathf.Infinity if the InstanceSoundEvent is not playing // Returns Mathf.Infinity if the SoundEvent or Transform is null // pitchSpeed determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long public float GetLastPlayedClipLength(SoundEvent soundEvent, Transform owner, bool pitchSpeed); // Returns the current time (in seconds) of the AudioClip in the last played AudioSource // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null // pitchSpeed determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long public float GetLastPlayedClipTimeSeconds(SoundEvent soundEvent, Transform owner, bool pitchSpeed); // Returns the current time (in range 0 to 1) of the AudioClip in the last played AudioSource // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null public float GetLastPlayedClipTimeRatio(SoundEvent soundEvent, Transform owner); // Returns the max length (in seconds) of the SoundEvent (calculated from the longest audioClip) // Is scaled by the pitch of the SoundEvent and SoundContainer // Does not take into account random, intensity or parameter pitch // Returns 0 if the SoundEvent is null public float GetMaxLength(SoundEvent soundEvent); // Returns the time (in seconds) since the SoundEvent was played // Is calculated using the time scale selected in the SoundManager // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null public float GetTimePlayed(SoundEvent soundEvent, Transform owner); // Returns if any SoundContainers in the SoundEvent is set to looping // Returns false if the SoundEvent is null public bool GetContainsLoop(SoundEvent soundEvent); // Returns the Transform of the SoundManager public Transform GetSoundManagerTransform(); Copy // Provides a block of spectrum data from AudioSources public void GetSpectrumData(SoundEvent soundEvent, Transform owner, ref float[] samples, int channel, FFTWindow window, SpectrumDataFrom spectrumDataFrom); Copy // Returns the last played AudioSource // Note that the AudioSource might be stolen or reused for different Voices over time public AudioSource GetLastPlayedAudioSource(SoundEvent soundEvent, Transform owner); Copy // Loads the audio data of any AudioClips assigned to the SoundContainers of the SoundEvent public void LoadAudioData(SoundEvent soundEvent); // Unloads the audio data of any AudioClips assigned to the SoundContainers of the SoundEvent public void UnloadAudioData(SoundEvent soundEvent); Copy // Plays the SoundEvent with the UI Transform as owner // Useful to play e.g. UI or other 2D sounds without having to pass a Transform // To make the sound 2D you still need to disable distance and set spatial blend to 0 in the SoundContainer public void UIPlay(SoundEvent soundEvent); public void UIPlay(SoundEvent soundEvent, SoundTag localSoundTag); public void UIPlay(SoundEvent soundEvent, params SoundParameterInternals[] soundParameterInternals); public void UIPlay(SoundEvent soundEvent, SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); // Plays the SoundEvent at the position with the UI Transform as owner (Useful for UnityEvents because it only has one parameter) public void UIPlayAtPosition(Vector3 position); public void UIPlayAtPosition(Transform position); Copy // Stops the SoundEvent at the UI Transform public void UIStop(SoundEvent soundEvent, bool allowFadeOut = true); // Stops all SoundEvents at the UI Transform public void UIStopAll(Transform owner, bool allowFadeOut = true); Copy // Pauses/unpauses the SoundEvent at the UI Transform locally public void UIPause(SoundEvent soundEvent, bool forcePause = false); public void UIUnpause(SoundEvent soundEvent); // Pauses/unpauses all SoundEvents at the UI Transform locally public void UIPauseAll(bool forcePause = false); public void UIUnpauseAll(); Copy // Uses the UI owner Transform // If playing it returns SoundEventState.Playing // If paused either locally or globally it returns SoundEventState.Paused // If not playing, but it is delayed it returns SoundEventState.Delayed // If not playing and it is not delayed it returns SoundEventState.NotPlaying // If the SoundEvent or Transform is null it returns SoundEventState.NotPlaying public SoundEventState UIGetSoundEventState(SoundEvent soundEvent); // Uses the UI owner Transform // Returns the length (in seconds) of the AudioClip in the last played AudioSource // Returns Mathf.Infinity if the InstanceSoundEvent is not playing // Returns Mathf.Infinity if the SoundEvent or Transform is null // pitchSpeed determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long public float UIGetLastPlayedClipLength(SoundEvent soundEvent, bool pitchSpeed); // Uses the UI owner Transform // Returns the current time (in seconds) of the AudioClip in the last played AudioSource // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null // pitchSpeed determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long public float UIGetLastPlayedClipTimeSeconds(SoundEvent soundEvent, bool pitchSpeed); // Uses the UI owner Transform // Returns the current time (in range 0 to 1) of the AudioClip in the last played AudioSource // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null public float UIGetLastPlayedClipTimeRatio(SoundEvent soundEvent); // Uses the UI owner Transform // Returns the time (in seconds) since the SoundEvent was played // Is calculated using the time scale selected in the SoundManager // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null public float UIGetTimePlayed(SoundEvent soundEvent); // Returns the owner Transform used by UIPlay() etc public Transform UIGetTransform(); Copy // Plays the SoundEvent at the SoundManagers music Transform public void MusicPlay(SoundEvent soundEvent, bool stopAllOtherMusic = true, bool allowFadeOut = true); public void MusicPlay(SoundEvent soundEvent, bool stopAllOtherMusic = true, bool allowFadeOut = true, params SoundParameterInternals[] soundParameterInternals); Copy // Stops the SoundEvent playing at the Music Transform public void MusicStop(SoundEvent soundEvent, bool allowFadeOut = true) // Stops all the SoundEvents playing at the Music Transform public void MusicStopAll(bool allowFadeOut = true) Copy // Pauses/unpauses the SoundEvent at the Music Transform locally public void MusicPause(SoundEvent soundEvent, bool forcePause = false); public void MusicUnpause(SoundEvent soundEvent); // Pauses/unpauses all SoundEvents at the Music Transform locally public void MusicPauseAll(bool forcePause = false); public void MusicUnpauseAll(); Copy // Uses the Music owner Transform // If playing it returns SoundEventState.Playing // If paused either locally or globally it returns SoundEventState.Paused // If not playing, but it is delayed it returns SoundEventState.Delayed // If not playing and it is not delayed it returns SoundEventState.NotPlaying // If the SoundEvent or Transform is null it returns SoundEventState.NotPlaying public SoundEventState MusicGetSoundEventState(SoundEvent soundEvent); // Uses the Music owner Transform // Returns the length (in seconds) of the AudioClip in the last played AudioSource // Returns Mathf.Infinity if the InstanceSoundEvent is not playing // Returns Mathf.Infinity if the SoundEvent or Transform is null // pitchSpeed determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long public float MusicGetLastPlayedClipLength(SoundEvent soundEvent, bool pitchSpeed); // Uses the Music owner Transform // Returns the current time (in seconds) of the AudioClip in the last played AudioSource // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null // pitchSpeed determines if it should be scaled by pitch. E.g. -12 semitones will be twice as long public float MusicGetLastPlayedClipTimeSeconds(SoundEvent soundEvent, bool pitchSpeed); // Uses the Music owner Transform // Returns the current time (in range 0 to 1) of the AudioClip in the last played AudioSource // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null public float MusicGetLastPlayedClipTimeRatio(SoundEvent soundEvent); // Uses the Music owner Transform // Returns the time (in seconds) since the SoundEvent was played // Is calculated using the time scale selected in the SoundManager // Returns 0 if the InstanceSoundEvent is not playing // Returns 0 if the SoundEvent or Transform is null public float MusicGetTimePlayed(SoundEvent soundEvent); // Returns the owner Transform used by MusicPlay() etc public Transform MusicGetTransform(); Copy // Pauses the all SoundEvents except those who are set to "Ignore Global Pause" public void SetGlobalPause(); // Unpauses the all SoundEvents except those who are set to "Ignore Global Pause" public void SetGlobalUnpause(); // Returns if Global Pause is enabled public bool GetGlobalPaused(); Copy // Sets a global volume of all sounds in decibels using AudioListener.volume, ranging from NegativeInfinity dB to 0 dB public void SetGlobalVolumeDecibel(float volumeDecibel); // Returns the global volume in decibels, ranging from NegativeInfinity dB to 0 dB public void SetGlobalVolumeRatio(float volumeRatio); // Sets a global volume of all sounds in linear scale using AudioListener.volume, ranging from 0 to 1 public float GetGlobalVolumeDecibel(); // Returns the global volume in linear scale, ranging from 0 to 1 public float GetGlobalVolumeRatio(); Copy // Sets the global SoundTag public void SetGlobalSoundTag(SoundTag soundTag); // Returns the global SoundTag public SoundTag GetGlobalSoundTag(); Copy // Sets the global distance scale (default is a scale of 100 units) public void SetGlobalDistanceScale(float distanceScale); // Returns the global distance scale public float GetGlobalDistanceScale(); Copy // Set if speed of sound should be active public void SetSpeedOfSoundEnabled(bool speedOfSoundEnabled); // Set the speed of sound scale // The default is a multiplier of 1 (by the base value of 340 unity units per second) public void SetSpeedOfSoundScale(float speedOfSoundScale); // Returns the speed of sound scale public float GetSpeedOfSoundScale(); Copy // Sets the Voice limit public void SetVoiceLimit(int voiceLimit); // Returns the Voice limit public int GetVoiceLimit(); // Sets the VoiceEffect limit public void SetVoiceEffectLimit(int voiceEffectLimit); // Returns the VoiceEffect limit public int GetVoiceEffectLimit(); Copy // Disables/enables all the Play functionality public void SetDisablePlayingSounds(bool disablePlayingSounds); // If the Play/PlayAtPosition functionality is disabled public bool GetDisablePlayingSounds(); Copy // If you have addressable AudioMixer enabled in the SoundManager you need to use this AudioMixer instance for e.g. AudioMixer.SetFloat(). // This is to fix problems when the AudioMixer is an addressable asset because it might create both a normal and an addressable instance with different IDs. // Note that when using an addressable AudioMixer you should also enable Async Startup to increase startup speed. // For addressable AudioMixer to work, you need to add the package "com.unity.addressables". // You also need to define the Script Define Symbol "SONITY_ENABLE_ADDRESSABLE_AUDIOMIXER". // Asmdef_Sonity.Internal.Runtime references Unity.Addressables and Unity.ResourceManager. // Asmdef_Sonity.Internal.Editor references Unity.Addressables. public AudioMixer GetAddressableAudioMixer(); sun-brightdesktopmoon --- # SoundManager | Sonity Docs ### [hashtag](https://sonity.gitbook.io/docs/soundmanager#soundmanager-component) SoundManager Component ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252Fme5W7oogOoRtBylGT8KC%252FSoundManager%2520Component.png%3Falt%3Dmedia%26token%3D6203116c-bbaf-4c9c-b404-cf9d24c94b2f&width=768&dpr=3&quality=100&sign=3bd06ff&sv=2) The [SoundManager](https://sonity.gitbook.io/docs/soundmanager) is the master object which is used to play sounds and manage global settings. An instance of this object is required in the scene in order to play [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . You can add the pre-made prefab called “SoundManager” found in “Assets\\Plugins\\Sonity\\Prefabs” to the scene. Or you can add the “Sonity - Sound Manager” component to an empty GameObject in the scene, it works just as well. circle-info 💡 TIP - Play On Awake If you need to play [SoundEvents](https://sonity.gitbook.io/docs/soundevent) on Awake() when starting your game you need to edit the Script Execution Order. Go to "Project Settings..." -> "Script Execution Order" and add "Sonity.SoundManager". Then set it to a negative value (like -50) so it loads before the code which you want to use Awake() to play sounds when starting your game. ### [hashtag](https://sonity.gitbook.io/docs/soundmanager#settings) Settings ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FHl9utzt3ehYLC053NRvD%252FSoundManager%2520Settings.png%3Falt%3Dmedia%26token%3Df0d2448c-0bad-4453-8c89-a30064beaaae&width=768&dpr=3&quality=100&sign=dec53276&sv=2) **Enable Volume Increase** If enabled you get the ability to raise the volume of [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) and [SoundEvents](https://sonity.gitbook.io/docs/soundevent) by +24dB each and [SoundVolumeGroups](https://sonity.gitbook.io/docs/soundvolumegroup) by +12dB. This is done by increasing the AudioListener.volume +60dB and reducing the volume of the AudioSource to compensate. Note that all other non-Sonity AudioSources will also be affected, you can avoid this by enabling AudioSource.ignoreListenerVolume. For volume increase to work, you need to set the Scripting Define Symbol "SONITY\_ENABLE\_VOLUME\_INCREASE". This can be done by pressing the button below (make sure all platforms has this scripting define symbol). You also need to have a [SoundManager](https://sonity.gitbook.io/docs/soundmanager) in your scene for volume increase to work when previewing and ingame. The free trial version of Sonity doesn’t support this feature because it uses Scripting Define Symbols. **Global Volume** Sets the global volume using AudioListener.volume. Note that because AudioListener.volume is used, all other non-Sonity AudioSources will also be affected. This can be remedied with using AudioSource.ignoreListenerVolume. Can be set with SetGlobalVolumeDecibel() and SetGlobalVolumeRatio() in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . **Global Pause** Pauses or unpauses all sound using AudioListener.pause. Except the [SoundEvents](https://sonity.gitbook.io/docs/soundevent) which are set to "Ignore Global Pause". Note that because AudioListener.pause is used, all other non-Sonity AudioSources will also be paused. This can be remedied with using AudioSource.ignoreListenerPause. Can be set with SetGlobalPause() and SetGlobalUnpause() in the SoundManager." **Global SoundTag** The selected Global [SoundTag](https://sonity.gitbook.io/docs/soundtag) . [SoundEvents](https://sonity.gitbook.io/docs/soundevent) using global [SoundTag](https://sonity.gitbook.io/docs/soundtag) are affected by this. **Distance Scale** Global range scale multiplier for all the sounds in Sonity. Distance is calculated by Unity units of distance. E.g. if Distance Scale is set to 100, a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) with the distance multiplier of 1 will be heard up to 100 Unity units away. #### [hashtag](https://sonity.gitbook.io/docs/soundmanager#third-party-integrations) Third Party Integrations ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FDQZHA7b3jyqWtdDNbzlt%2Fimage5.png&width=768&dpr=3&quality=100&sign=81603516&sv=2) ### [hashtag](https://sonity.gitbook.io/docs/soundmanager#steam-audio-integration) Steam Audio Integration Enables the integration between Sonity and the third party asset Steam Audio. #### [hashtag](https://sonity.gitbook.io/docs/soundmanager#read-more-about-the-steam-audio-sonity-integration-here) [Read more about the Steam Audio Sonity Integration here](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration) **Spatialize On Default** Makes HRTF Plugin Spatialize in the [SoundContainer Settings](https://sonity.gitbook.io/docs/soundcontainer#steam-audio-settings) be enabled by default when creating new assets. Spatialize makes the sound be affected by Steam Audio with effects like occlusion, reflections and more. Disable Spatialize for 2D sounds like music etc. ### [hashtag](https://sonity.gitbook.io/docs/soundmanager#playmaker-integration) PlayMaker Integration Enables the integration between Sonity and the third party asset PlayMaker by adding custom Sonity actions. #### [hashtag](https://sonity.gitbook.io/docs/soundmanager#read-more-about-the-playmaker-sonity-integration-here) [Read more about the PlayMaker Sonity Integration here](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration) ### [hashtag](https://sonity.gitbook.io/docs/soundmanager#docs-internal-guid-dcaf7a58-7fff-9584-39bc-aabab3d35a26) Advanced Settings **Sound Time Scale** Change the Time Scale used for sound related calculations ingame. When the game is not playing in the editor, only Time.realtimeSinceStartup can be used (for preview, etc). The Time Scale is used to calculate: * [Modifier](https://sonity.gitbook.io/docs/modifiers) Delay * [Modifier](https://sonity.gitbook.io/docs/modifiers) Fade In/Out Length * [SoundEvent](https://sonity.gitbook.io/docs/soundevent) Timeline Delay * [SoundEvent](https://sonity.gitbook.io/docs/soundevent) Cooldown Time * [SoundEvent](https://sonity.gitbook.io/docs/soundevent) Intensity Seek Time * [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) Prevent End Clicks Fade * [SoundParameter](https://sonity.gitbook.io/docs/soundparameter) Delay * [SoundManager](https://sonity.gitbook.io/docs/soundmanager) Speed of Sound Delay * [SoundManager](https://sonity.gitbook.io/docs/soundmanager) Voice Disable Time * [SoundManager](https://sonity.gitbook.io/docs/soundmanager) SoundEvent Debug Live Fade **Override Listener Distance** If enabled an [AudioListenerDistance](https://sonity.gitbook.io/docs/soundmanager#audiolistenerdistance-component) component is required in the scene. The position of the [AudioListenerDistance](https://sonity.gitbook.io/docs/soundmanager#audiolistenerdistance-component) component will determine all distance based calculations (like volume falloff). While the AudioListener position will be used for spatialization and Angle to Stereo Pan calculations. Example of usage in a 3rd person or top down game: Enable "Override Listener Distance" in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . Put the AudioListener on the main camera and the [AudioListenerDistance](https://sonity.gitbook.io/docs/soundmanager#audiolistenerdistance-component) on the player character. Try changing the Amount slider to find a nice balance between the different positions. Override Listener Distance: **Amount %** How much weight the [AudioListenerDistance](https://sonity.gitbook.io/docs/soundmanager#audiolistenerdistance-component) position has over the AudioListener position. The position is linearly interpolated between the two of them. 100% is at the [AudioListenerDistance](https://sonity.gitbook.io/docs/soundmanager#audiolistenerdistance-component) component position. 50% is halfway between them. 0% is at the AudioListener position. **Enable Speed of Sound** Speed of sound is a delay based on the distance between the AudioListener and a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Enable Speed of Sound: **Speed of Sound Scale** Global speed of sound delay scale multiplier. 1 equals 430 Unity units per second. Is calculated using the time scale selected in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . **Addressable AudioMixer** If enabled, all AudioMixer references in all [SoundEvents](https://sonity.gitbook.io/docs/soundevent) and [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) to the selected addressable AudioMixer Reference Asset. This is to fix problems when the AudioMixer is an addressable asset because it might create both a normal and an addressable instance with different IDs. Note that when using an addressable AudioMixer you should also enable Async Startup to increase startup speed. The AudioMixerGroups are matched using FindMatchingGroups using the name of the AudioMixerGroup, so you have to name your groups to something unique. For builds the AudioMixerGroups are cached and wont be updated once the sound has been played. When using AudioMixer.SetFloat() etc you need to access this specific AudioMixer instance by using "SoundManager.Instance.GetAddressableAudioMixer();" For addressable AudioMixer to work, you need to add the package "com.unity.addressables". You also need to define the Script Define Symbol "SONITY\_ENABLE\_ADDRESSABLE\_AUDIOMIXER". Asmdef\_Sonity.Internal.Runtime references Unity.Addressables and Unity.ResourceManager. Asmdef\_Sonity.Internal.Editor references Unity.Addressables. The free trial version of Sonity doesn’t support this feature because it uses Scripting Define Symbols. Addressable AudioMixer: **AudioMixer Reference** Assign the AudioMixer reference here, it will be automatically loaded. Only one AudioMixer per project is supported with this feature. Addressable AudioMixer: **Async Load In Editor** Enables async loading of the addressable AudioMixer in the editor. Having it disabled is useful for testing in the editor when you need to access the AudioMixer or play sounds on Awake before async loading is finished. **Async Startup** Makes Sonity initialize using an async loading method. This is useful for when you use the addressable AudioMixer to speed up load times. Or when using Steam Audio and you want to preload voices. **Use DontDestroyOnLoad()** Calls DontDestroyOnLoad() at Start for Sonity objects. Which makes them persistent when switching scenes. For this to work the parent is set to null, which can move the objects. **Debug Warnings** Makes Sonity output Debug Warnings if anything is wrong. Debug Warnings: **Debug in Play Mode** Makes Sonity output Debug Warnings if anything is wrong in Play Mode. **GUI Warnings** Makes Sonity show GUI Warnings if anything is wrong in the editor. **Disable Playing Sounds** Disables all the Play functionality. Useful if you've for example implemented temp sounds and don't want everyone else to hear them. ### [hashtag](https://sonity.gitbook.io/docs/soundmanager#performance-settings) **Performance Settings** **Voice Limit** Maximum number of Voices. If the limit is reached it will steal the Voice with the lowest priority. If you need extra performance, you could try lowering the real and virtual voices to a lower number. Voice Limit cannot be lower than Voice Preload. **Max Real Voices:** The maximum number of real (heard) AudioSources that can be played at the same time. "Real Voices" should be the same as the "Voice Limit", or more if you play other sounds outside of Sonity. **Max Virtual Voices:** The maximum number of virtual (not heard) AudioSources that can be played at the same time. This should always be more than the number of real voices. You can change these values manually in: "Edit" > "Project Settings" > "Audio" **Apply to Project Audio Settings** Applies the Voice Limit to the Project Audio Settings. Sets "Real Voices" to the "Voice Limit". You can change these values manually in: "Edit" > "Project Settings" > "Audio" **Voice Preload** How many Voices to preload on Awake(). Voice Limit cannot be lower than Voice Preload. **Voice Disable Time** How long in seconds to wait before disabling a Voice when they've stopped playing. Retriggering a voice which is not disabled is more performant than retriggering a voice which is disabled. But having a lot of voices enabled which aren't used is also not good for performance, so don't set this value too high. Is calculated using the time scale selected in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . **Voice Effect Limit** Maximum number of Voice Effects which can be used at the same time. A Voice with any combination of waveshaper/lowpass/highpass counts as one Voice Effect. If the values of a Voice Effect doesn't have any effect it is disabled automatically (e.g. distortion amount is 0). If the Voice Effect limit is reached, the Voice Effects are prioritized by the Voices with the highest volume \* priority. Watch out for high load on the audio thread if set too high. Try setting the buffer size to "Best Performance" in "Edit" > "Project Settings" > "Audio" if you want to run more Voice Effects. ### [hashtag](https://sonity.gitbook.io/docs/soundmanager#debug) Debug ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FGXEqXAPr2jIMMbllM7cF%252FSoundManager%2520Debug.png%3Falt%3Dmedia%26token%3D76bb529e-4715-4360-9b8f-95c5ce108aa8&width=768&dpr=3&quality=100&sign=9fb08bb1&sv=2) **AudioListener** Here you can see and select the currently cached AudioListener in runtime. If you click on the field your selection will show you the currently used AudioListener. The AudioListener component is found and cached automatically and cannot be assigned here. **AudioListenerDistance** Here you can see and select the currently cached [AudioListenerDistance](https://sonity.gitbook.io/docs/soundmanager#audiolistenerdistance-component) in runtime. If you click on the field your selection will show you the currently used [AudioListenerDistance](https://sonity.gitbook.io/docs/soundmanager#audiolistenerdistance-component) . The [AudioListenerDistance](https://sonity.gitbook.io/docs/soundmanager#audiolistenerdistance-component) component is found and cached automatically and cannot be assigned here. Is only shown if “Override Listener Distance” is enabled. ### [hashtag](https://sonity.gitbook.io/docs/soundmanager#log-soundevents) Log SoundEvents ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252F7SH3wlMcwmODxUffGWUB%252FSoundManager%2520Log%2520SoundEvents.png%3Falt%3Dmedia%26token%3D4da85e72-d2e4-4d56-ac4b-89a56cfad58f&width=768&dpr=3&quality=100&sign=d4055566&sv=2) When enabled [SoundEvent](https://sonity.gitbook.io/docs/soundevent) actions will be logged to the console. This is useful to debug what happens with [SoundEvents](https://sonity.gitbook.io/docs/soundevent) during runtime. It also enables you to see where in the code the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played/stopped from if you enable Stack Tracke Logging “Script Only”. **To Console** If enabled it will log [SoundEvent](https://sonity.gitbook.io/docs/soundevent) actions to the console. Example: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FegslZ2FurEVN2aLuEmPC%252FSoundManager%2520Log%2520SoundEvents%2520Example.png%3Falt%3Dmedia%26token%3D4ffc10dd-8315-4e98-9846-620293a3ca95&width=768&dpr=3&quality=100&sign=a5a94af4&sv=2) circle-info ❕ Tip: As you can see in the bottom you can also see where the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played in code. **Debug Log Type** Select which kind of Debug.Log you want to use. Switch between either Debug.Log, Debug.LogWarning or Debug.LogError. **Click On Log Selects** If you click the log in the console, you will be redirected to one of either object: Click On Log Selects: **Owner** Selects the owner transform which is used to play the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Click On Log Selects: **Position** Selects the transform position which is used to play the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) if its played with PlayAtPosition with a Transform. Click On Log Selects: **SoundEvent** Selects the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) which is logged. If an Owner or Position can't be found (for example when logging stop etc) it will redirect to the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) instead. **Log Settings** Opens a dropdown menu where you can select which events should be logged. Log Settings: **SoundEvent Play** Logs when a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played. Log Settings: **SoundEvent Stop** Logs when a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is stopped with a stop command. Log Settings: **SoundEvent Pool** Logs when a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is pooled after its stopped. Log Settings: **SoundEvent Pause** Logs when a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is paused. Log Settings: **SoundEvent Unpause** Logs when a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is unpaused. Log Settings: **SoundEvent Global Pause** Logs when a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is paused using global pause. Log Settings: **SoundEvent Global Unpause** Logs when a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is unpaused using global unpause. Log Settings: **SoundParameters Once** Logs any [SoundParameter](https://sonity.gitbook.io/docs/soundparameter) set to UpdateMode Once passed when playing a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Log Settings: **SoundParameters Continuous** Logs any [SoundParameter](https://sonity.gitbook.io/docs/soundparameter) set to UpdateMode Continuous on an active [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . ### [hashtag](https://sonity.gitbook.io/docs/soundmanager#draw-soundevents) Draw SoundEvents ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FlujDqRDtS9bpF76iVYUC%252FSoundManager%2520Draw%2520SoundEvents.png%3Falt%3Dmedia%26token%3Da503064e-3a3b-4ebf-b942-2d5ec169dec6&width=768&dpr=3&quality=100&sign=2d81d6f0&sv=2) Draws the names of all currently playing [SoundEvent](https://sonity.gitbook.io/docs/soundevent) in the scene and/or game view. Useful for debugging when you want to see what is playing and where. **In Scene View** Draws debug names in the Unity scene view. Doesn't work in Unity versions older than 2019.1. Example: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FDRF6CWAuglwx9BaXWZqV%252FSoundManager%2520Draw%2520SoundEvents%2520Example%2520In%2520Game%2520View.gif%3Falt%3Dmedia%26token%3D9ab086ac-cd8e-4c5e-826c-6b891117ac19&width=768&dpr=3&quality=100&sign=f566aa7&sv=2) **In Game View** Draws debug names in the Unity game view. Only applied in the Unity editor. Example: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FiFqiR5V9CuHG8AZEbHcd%252FSoundManager%2520Draw%2520SoundEvents%2520Example%2520In%2520Scene%2520View.gif%3Falt%3Dmedia%26token%3D6e51e2c3-6857-46d7-99a8-9860081585ce&width=768&dpr=3&quality=100&sign=b0f6a5f3&sv=2) **Hide if Closer Than** Hides the debug if its closer to the camera than the allowed value in Game view. Useful for hiding [SoundEvents](https://sonity.gitbook.io/docs/soundevent) which are played on the camera which you don't want to see. #### [hashtag](https://sonity.gitbook.io/docs/soundmanager#style) **Style** **Font Size** The font size of the text. **Volume to Opacity** How much of the volume of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) will be applied to the transparency of the text. E.g lower volumes will be more transparent. **Lifetime to Opacity** How much the lifetime of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) will affect the transparency of the text. **Lifetime Fade Length** How long the fade should be. Is calculated using the time scale selected in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . **Start Color** The color the text should have when it starts playing. **End Color** Which color the text should fade to over the lifetime. The color of the text outline. ### [hashtag](https://sonity.gitbook.io/docs/soundmanager#statistics) Statistics ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FgTrNCurrsWQkUpAJfgwv%252FSoundManager%2520Statistics.png%3Falt%3Dmedia%26token%3D977d4742-1049-4473-85e5-ef6131000497&width=768&dpr=3&quality=100&sign=5b2b7351&sv=2) **SoundEvents** Statistics of [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . SoundEvents: **Created** The number of instantiated [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . SoundEvents: **Active** The number of active [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . SoundEvents: **Disabled** The number of unused and disabled [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . **Voices** Statistics of Voices. Voices: **Played** The number of played Voices since start. Voices: **Stolen** The number of stolen Voices since start. Voices: **Max Simultaneous** The maximum number of simultaneously playing Voices since start. Voices: **Created** The number of Voices in the pool. Voices: **Active** The number of Voices playing audio. Voices: **Inactive** The number of inactive Voices in the pool. Voices: **Paused** The number of paused Voices in the pool. Voices: **Stopped** The number of stopped Voices in the pool. **Voice Effects** Statistics of Voice Effects. A Voice with any combination of waveshaper/lowpass/highpass counts as one Voice Effect Voice Effects: **Active** The number of active Voice Effects. Voice Effects: **Available** How many Voice Effects are available. #### [hashtag](https://sonity.gitbook.io/docs/soundmanager#statistics-instances) Statistics Instances ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FvfaDZOaKg2YutceIulON%252FStatistics%2520Instances.png%3Falt%3Dmedia%26token%3D2d4147b8-a18a-429a-835b-dc12095a852c&width=768&dpr=3&quality=100&sign=8b704db9&sv=2) Real-time statistics per [SoundEvent](https://sonity.gitbook.io/docs/soundevent) Instance. Available in Playmode. **Sort By** Which method to sort the list of [SoundEvent](https://sonity.gitbook.io/docs/soundevent) Instances. Sort By: **Name** Sorts by alphabetical order Sort By: **Voices** Sorts by voice count Sort By: **Plays** Sorts by number of plays Sort By: **Volume** Sorts by volume Sort By: **Time** Sorts by last time played **Show** Toggle what information to show about the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) Instances. Show: **Active** How many are currently active. Show: **Disabled** How many are currently disabled. Show: **Voices** How many voices are currently used. Show: **Plays** The number of total plays. Show: **Volume** The current average volume. ### [hashtag](https://sonity.gitbook.io/docs/soundmanager#editor-tools) Editor Tools ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2F3pnYfJYAYKVXHGlT98YW%2Fimage15.png&width=768&dpr=3&quality=100&sign=8f20b3f6&sv=2) This is a collection of nifty editor tools which you can use to speed up your workflow. They are enabled with the use of “Script Define Symbols” in Project Settings -> Player -> Other Settings -> Script Compilation -> Script Define Symbols. This way they can be bound to default hotkeys and they won’t hog up your toolbars if you don’t use them. You can read more about them here: #### [hashtag](https://sonity.gitbook.io/docs/soundmanager#editor-tool-reference-finder) [Editor Tool - Reference Finder](https://sonity.gitbook.io/docs/soundmanager/editor-tools#editor-tool-reference-finder) #### [hashtag](https://sonity.gitbook.io/docs/soundmanager#editor-tool-select-same-type) [Editor Tool - Select Same Type](https://sonity.gitbook.io/docs/soundmanager/editor-tools#editor-tool-select-same-type) #### [hashtag](https://sonity.gitbook.io/docs/soundmanager#editor-tool-selection-history) [Editor Tool - Selection History](https://sonity.gitbook.io/docs/soundmanager/editor-tools#editor-tool-selection-history) ### [hashtag](https://sonity.gitbook.io/docs/soundmanager#audiolistenerdistance-component) AudioListenerDistance Component If “Override Listener Distance” is enabled in the [SoundManager Settings](https://sonity.gitbook.io/docs/soundmanager#settings) this is a required component in the scene. The position of the [AudioListenerDistance](https://sonity.gitbook.io/docs/soundmanager#audiolistenerdistance-component) component will determine all distance based calculations (like volume falloff). While the AudioListener position will be used for spatialization and Angle to Stereo Pan calculations. Example of usage in a 3rd person or top down game: Enable "Override Listener Distance" in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . Put the AudioListener on the main camera and the [AudioListenerDistance](https://sonity.gitbook.io/docs/soundmanager#audiolistenerdistance-component) on the player character. Try changing the Amount slider to find a nice balance between the different positions. [PreviousSoundEvent Functionschevron-left](https://sonity.gitbook.io/docs/soundevent/soundevent-functions) [NextEditor Toolschevron-right](https://sonity.gitbook.io/docs/soundmanager/editor-tools) Last updated 1 month ago * [SoundManager Component](https://sonity.gitbook.io/docs/soundmanager#soundmanager-component) * [Settings](https://sonity.gitbook.io/docs/soundmanager#settings) * [Steam Audio Integration](https://sonity.gitbook.io/docs/soundmanager#steam-audio-integration) * [PlayMaker Integration](https://sonity.gitbook.io/docs/soundmanager#playmaker-integration) * [Advanced Settings](https://sonity.gitbook.io/docs/soundmanager#docs-internal-guid-dcaf7a58-7fff-9584-39bc-aabab3d35a26) * [Performance Settings](https://sonity.gitbook.io/docs/soundmanager#performance-settings) * [Debug](https://sonity.gitbook.io/docs/soundmanager#debug) * [Log SoundEvents](https://sonity.gitbook.io/docs/soundmanager#log-soundevents) * [Draw SoundEvents](https://sonity.gitbook.io/docs/soundmanager#draw-soundevents) * [Statistics](https://sonity.gitbook.io/docs/soundmanager#statistics) * [Editor Tools](https://sonity.gitbook.io/docs/soundmanager#editor-tools) * [AudioListenerDistance Component](https://sonity.gitbook.io/docs/soundmanager#audiolistenerdistance-component) sun-brightdesktopmoon sun-brightdesktopmoon --- # SoundEvent | Sonity Docs [hashtag](https://sonity.gitbook.io/docs/soundevent#soundevent) SoundEvent ------------------------------------------------------------------------------- ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FAJiJZH9D1baPCWXusuLh%2Fimage101.png&width=768&dpr=3&quality=100&sign=51247e2a&sv=2) [SoundEvents](https://sonity.gitbook.io/docs/soundevent) are what you play in Sonity. They contain SoundContainers and options of how the sound should be played. All SoundEvents are multi-object editable. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#notes) Notes Example note: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2Ftpf9mb3NhxvjMR5uq7Y7%2Fimage97.png&width=768&dpr=3&quality=100&sign=7ceceb14&sv=2) At the top of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) there is a text field which you can fill with notes. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#presets) Presets ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FueuDZ4Llj86IlttFyl6V%252FSoundEvent%2520Presets.png%3Falt%3Dmedia%26token%3D48839f08-4128-454d-be53-66f533f32664&width=768&dpr=3&quality=100&sign=2b66cd57&sv=2) The “Presets” shown in the example picture above need to be created with the [SoundPreset](https://sonity.gitbook.io/docs/soundpreset) object. **SoundPresets** Create [SoundPreset](https://sonity.gitbook.io/docs/soundpreset) objects to get custom settings which you can apply to your [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) and [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . Either manually select the preset you want to apply in the dropdown, or use “Auto Match” to automatically apply the settings based on the name of the asset. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#mute-solo-disable) Mute, Solo, Disable ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FrFa28tQMRdBIzGGlWjYa%2Fimage27.gif&width=768&dpr=3&quality=100&sign=2bc25bbb&sv=2) **Mute** Mutes the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Only affects the Unity Editor. **Solo** Mutes all other [SoundEvents](https://sonity.gitbook.io/docs/soundevent) who don't have solo enabled. The Solo property is not serialized (e.g. will be reset on start). This is to prevent leaving a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) soloed by mistake which would make nothing else sound when the game runs. Only affects the Unity Editor. **Disable** Disables the playing of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . It is also disabled when building the project. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#preview) Preview ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FcTe9u184w9U6kejG45HI%252FSoundEvent%2520Preview.gif%3Falt%3Dmedia%26token%3Db489f3fe-edd5-4dd8-9ecd-442bbdca3c09&width=768&dpr=3&quality=100&sign=9c9747de&sv=2) With the preview you can listen to the sounds in the editor. The preview handle enables you to move the sound around. **Preview Shortcuts** Play: Ctrl+Q (Previews the selected [SoundEvent](https://sonity.gitbook.io/docs/soundevent) or [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) ). Stop: Ctrl+W (Stops any playing preview of [SoundEvents](https://sonity.gitbook.io/docs/soundevent) and [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) , press two times to skip fade out). They are rebindable in the Shortcuts window. **Play** Previews the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Does not work if Unity cannot build the project, or if the game is paused. Preview doesn't play more than one level of TriggerOnPlay/Stop/Tail at the moment (there is full functionality ingame). The default shortcut is Ctrl+Q. **Stop** Press two times to skip the fade out. The default shortcut is Ctrl+W. **Reset** Resets the preview settings. **Intensity** Controls the intensity value of the played [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) . **AudioMixerGroup** Only used for preview. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#spatialization-info) Spatialization Info Show and edit spatialization info for the selected [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FJOhHmDt8tqEOgMGj9hg9%2Fimage22.gif&width=768&dpr=3&quality=100&sign=ff1a10d2&sv=2) **3D Sounds** All [SoundEvents](https://sonity.gitbook.io/docs/soundevent) with [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) which have Spatial Blend > 0 and Distance Enabled. **2D Sounds** All [SoundEvents](https://sonity.gitbook.io/docs/soundevent) with [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) which have Spatial Blend = 0 and Distance Disabled. **3D Sound no Distance** All [SoundEvents](https://sonity.gitbook.io/docs/soundevent) with [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) which have Spatial Blend > 0 and Distance Disabled. **2D Sound with Distance** All [SoundEvents](https://sonity.gitbook.io/docs/soundevent) with [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) which have Spatial Blend = 0 and Distance Enabled. **2D Sound with Distance** All [SoundEvents](https://sonity.gitbook.io/docs/soundevent) with [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) which have mixed Spatial Blend and Distance Enabled settings. **Empty** All [SoundEvents](https://sonity.gitbook.io/docs/soundevent) which have no [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) . **Select SE** Selects [SoundEvents](https://sonity.gitbook.io/docs/soundevent) matching the specific settings. **Select All SE** Selects All [SoundEvents](https://sonity.gitbook.io/docs/soundevent) in the same folder disregarding subfolders. **Select SC** Selects [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) of the [SoundEvents](https://sonity.gitbook.io/docs/soundevent) matching the specific settings. **Set 3D** Sets the [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) of the selected [SoundEvents](https://sonity.gitbook.io/docs/soundevent) to Spatial Blend 1 and Distance Enabled. **Set 2D** Sets the [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) of the selected [SoundEvents](https://sonity.gitbook.io/docs/soundevent) to Spatial Blend 0 and Distance Disabled. **All Select AC** Selects all [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) of the selected [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . **All Set 3D** Sets all [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) of the selected [SoundEvents](https://sonity.gitbook.io/docs/soundevent) to Spatial Blend 1 and Distance Enabled. **All Set 2D** Sets all [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) of the selected [SoundEvents](https://sonity.gitbook.io/docs/soundevent) to Spatial Blend 0 and Distance Disabled. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#soundcontainers) SoundContainers ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FVBJPfkk0CTHPmnBHkOzj%2Fimage23.gif&width=768&dpr=3&quality=100&sign=bc1c8da6&sv=2) This is where you assign the [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) which are going to be used when the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played. **Find SoundContainers** ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2Fi0zwobyRYIX6obLOF4JI%2Fimage13.png&width=768&dpr=3&quality=100&sign=fdd9b39b&sv=2) Automatically finds all [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) containing the same name as this [SoundEvent](https://sonity.gitbook.io/docs/soundevent) (disregarding \_SE, numbers). Can be used on multiple items at once (tip: search "t:soundEvent"). If no matching [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) are found, it will try and remove one character at the end of the name at a time until it finds a hit."; **Drop SoundContainers/Folders Here** Here you can drag and drop [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) or folders with [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) in them. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#timeline) Timeline ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FMenjNBW0dutYALfy12j5%2Fimage29.gif&width=768&dpr=3&quality=100&sign=e743cf17&sv=2) In the timeline editor you can move the items in time and change the volume volume of individual [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) . The length of the item in the timeline is determined by the length of the longest AudioClip in the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) . If you change the pitch, the length of the item will match the pitch. **Shortcuts and Controls** Zoom: Ctrl + mouse wheel scroll. Pan: Mouse wheel hold and drag (or left mouse button hold and drag on the background). Volume: Hold and drag top of item up/down or click on the volume to write the decibel value. Move item: Hold and drag on item left/right. Focus on items: F ### [hashtag](https://sonity.gitbook.io/docs/soundevent#base) Base ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FOTS5J39fmIWoEVdM6QP5%252FSoundEvent%2520Base.gif%3Falt%3Dmedia%26token%3D301b34b3-bfba-4e8b-bd82-b48a579def75&width=768&dpr=3&quality=100&sign=96b616bf&sv=2) Contains base settings for the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . **Polyphony** How many instances of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) that can exist at the same transform. Modifier polyphony overrides this value. **Volume dB** Volume offset in decibel. If you want to be able to raise the volume and not just lower it you have 2 options: **Option A:** Enable "Enable Volume Increase" in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . This will enable you to raise the volumes of [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) and [SoundEvents](https://sonity.gitbook.io/docs/soundevent) by +24 dB each and [SoundVolumeGroups](https://sonity.gitbook.io/docs/soundvolumegroup) by +12dB. **Option B:** Select all the [SoundEvents](https://sonity.gitbook.io/docs/soundevent) and lower the volume by -20 dB with the -1dB button. Then to compensate you can increase the global volume with an Audio Mixer (which you then can set to +20 dB). circle-info **💡 TIP - Convert from Old Modifier to Base** You can convert the old [Modifier](https://sonity.gitbook.io/docs/modifiers) polyphony and volume to the new Base by selecting the assets and running: "Tools/Sonity 🔊/Convert SoundEvent Modifier Volume and Polyphony to Base" This will offset the Base volume with the [Modifier](https://sonity.gitbook.io/docs/modifiers) volume and override the Base polphony with the [Modifier](https://sonity.gitbook.io/docs/modifiers) polyphony. **\-1 dB** Lowers the relative volume of all the selected [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . Useful for example if you want to raise the volume of one [SoundEvent](https://sonity.gitbook.io/docs/soundevent) and keep the relative volume. Because then you can lower all of them to get more headroom. If multiple [SoundEvents](https://sonity.gitbook.io/docs/soundevent) are selected it will show the lowest volume. **+1 dB** Raises the relative volume of all the selected [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . Useful for example if you want to set the loudest volume to 0 dB but keep the relative volumes. If multiple [SoundEvents](https://sonity.gitbook.io/docs/soundevent) are selected it will show the highest volume. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#modifiers) Modifiers ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FucgZLZ7sAekRbCXYJOql%252FSoundEvent%2520Modifiers.gif%3Falt%3Dmedia%26token%3D654e8d1d-c3dd-4f0f-b383-0f86a45c6c9c&width=768&dpr=3&quality=100&sign=6b61f475&sv=2) Modifiers are used to control how [SoundEvents](https://sonity.gitbook.io/docs/soundevent) are played (e.g. volume, polyphony, fade in length etc). See [Modifiers](https://sonity.gitbook.io/docs/modifiers) for more info. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#settings) Settings ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FTx38xnSloD3PSwyJzeWb%252FSoundEvent%2520Settings.png%3Falt%3Dmedia%26token%3D02cac207-8381-49c2-a885-2ca6a296463c&width=768&dpr=3&quality=100&sign=885ef2c3&sv=2) **Polyphony Mode** Polyphony Mode: **Limited Per Owner** Useful if you want to limit polyphony e.g per player. You can use e.g [SoundEvent.PlayAtPosition();](https://sonity.gitbook.io/docs/soundevent/soundevent-functions) to play a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) at one position with another owner. Polyphony Mode: **Limited Globally** Useful if you want to limit the polyphony globally e.g for bullet impacts. This setting will change the old owner to the new position and set the new owner as the Transform of the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) .Instance. If you play the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) with either [MusicPlay](https://sonity.gitbook.io/docs/soundevent/soundevent-functions) or [UIPlay](https://sonity.gitbook.io/docs/soundevent/soundevent-functions) this setting will not have an effect. circle-info ❕ Tip: If you want to limit the polyphony per owner and globally at the same time, you can use [SoundPolyGroups](https://sonity.gitbook.io/docs/soundevent#h.kivxl47osql) . **AudioMixerGroup** The AudioMixerGroup you want to output to. circle-info 💡 TIP - AudioMixerGroup Performance If you have issues with audio performance you might want to make sure you’re not using an unnecessary amount of AudioMixerGroups (like a hundred of them). Because changing AudioMixerGroup for a Voice uses performance (when playing a new Voice Sonity tries to find an unused Voice which uses the same AudioMixerGroup). Use AudioMixerGroups when you want effects per group or e.g. ducking or for larger groups of sounds, but maybe not a have a unique one for each sound. **SoundVolumeGroup** [SoundVolumeGroup](https://sonity.gitbook.io/docs/soundvolumegroup) enables grouped volume control with live volume changes. It is perfect for quickly changing the volume of a large group of sounds. It also supports +12dB volume if you “Enable Volume Increase” in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . ### [hashtag](https://sonity.gitbook.io/docs/soundevent#advanced-settings) Advanced Settings **SoundMix** [SoundMix](https://sonity.gitbook.io/docs/soundmix) enables hierarchical control of for example volume or distance scale etc. **SoundPolyGroup** [SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) gives polyphony control grouped over different [SoundEvent](https://sonity.gitbook.io/docs/soundevent) types. **Priority** Lower priority [SoundEvents](https://sonity.gitbook.io/docs/soundevent) will be stolen first. If "Skip Lower Priority" is enabled on the [SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) this will determine if this [SoundEvent](https://sonity.gitbook.io/docs/soundevent) will play or not when the Polyphony Limit is reached. **Cooldown Time** How quick this [SoundEvent](https://sonity.gitbook.io/docs/soundevent) can be retriggered in seconds. Is calculated using the time scale selected in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . **Probability %** The probability that this [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should play. **Pass Parameters** If [SoundParameters](https://sonity.gitbook.io/docs/soundparameter) should be passed to sub. E.g [SoundTag](https://sonity.gitbook.io/docs/soundtag) , TriggerOnPlay, TriggerOnStop, TriggerOnTail. **Ignore Local Pause** If enabled, the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) won't be paused unless force pause is used. **Ignore Global Pause** If enabled, the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) won't be paused when global pause is used. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#intensity) Intensity ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FSCpIHCvI0CVX4GCkKJ3T%252FSoundEvent%2520Intensity.gif%3Falt%3Dmedia%26token%3D861431e9-b0ca-49c6-a0ab-3f1492ca18ee&width=768&dpr=3&quality=100&sign=500c90c1&sv=2) Intensity contains settings for how [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) is scaled before it is applied to the enabled intensity options e.g Volume, Pitch etc. In the example above the sound is played a few times with a [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) . The range of the recorded intensity is from 0.5 to 2.5. When “Scale Min-Max to 0-1” is pressed the following happens: 1. It first finds the Min value which is 0.5 and sets Add to -0.5 so it is 0 2. Then it finds the Max value which now is 2 and sets Multiplier to 0.5 so it is 1 This makes the range into 0 to 1. The intensity debug log records all intensity values used when this [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played. It is used to scale the [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) to a 0-1 range. **Add** Adds to the [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) . **Multiplier** Multiplier of the [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) . **Curve** Curve of the intensity. From 0 (soft) to 1 (hard). **Smoothing** The seek time of the [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) in seconds. Is calculated using the time scale selected in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . **Enable Threshold** If this [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played with a [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) and it is under the threshold it won't be played. Enable Threshold: **Threshold** The threshold limit after scaling the intensity value. **Scale Add** Adds to the [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) , used by the automatic scaling. Is separate from the manual add setting to provide finer control and better multi-editing. **Scale Multiplier** Multiplier of the [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) , used by the automatic scaling. Is separate from the manual multiplier setting to provide finer control and better multi-editing. **Intensity Record** If enabled it will record all [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) used when playing this SoundEvent. **Debug Zoom** Focuses the vertical zoom scale to the values which are within the min and max range. **Debug Resolution** The resolution of the displayed values. **Scale Max to 1** Sets Intensity Add to 0. Then uses the recorded values to scale the Max value to 1 with Intensity Multiply. Useful for e.g. impacts where the Min value is 0 and the Max value is unknown. **Scale Min-Max to 0-1** Uses the recorded values to make the Min value 0 with Intensity Add. Then uses the recorded values to scale the Max value to 1 with Intensity Multiply. Useful where Min and Max Intensity value ranges are unknown. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#trigger-other) Trigger Other ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2Ffrx2OsCnDpv5nxyP6wn6%2Fimage4.png&width=768&dpr=3&quality=100&sign=906910ce&sv=2) Triggers other [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . **Which to Play** If Play All is selected, then all assigned [SoundEvents](https://sonity.gitbook.io/docs/soundevent) will be played. If One Random is selected, then one random of the assigned [SoundEvents](https://sonity.gitbook.io/docs/soundevent) will be played. The randomizer uses a pseudo random function remembering which [SoundEvents](https://sonity.gitbook.io/docs/soundevent) it last played to avoid repetition. #### [hashtag](https://sonity.gitbook.io/docs/soundevent#trigger-on-play) Trigger On Play ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FgsFImxe3x5sHptssizCv%252FTrigger%2520On%2520Play.png%3Falt%3Dmedia%26token%3Da506966e-fed9-43ba-b537-8756d09e0dc8&width=768&dpr=3&quality=100&sign=8c6470b4&sv=2) Triggers another [SoundEvent](https://sonity.gitbook.io/docs/soundevent) when this [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played. #### [hashtag](https://sonity.gitbook.io/docs/soundevent#trigger-on-stop) Trigger On Stop ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FttDWqULsODEWMDsrjOkr%252FTrigger%2520On%2520Stop.png%3Falt%3Dmedia%26token%3D4d716a6b-552b-479e-91a6-69e5e3c5e2aa&width=768&dpr=3&quality=100&sign=8a7dcf2a&sv=2) Triggers another [SoundEvent](https://sonity.gitbook.io/docs/soundevent) when this [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is stopped. #### [hashtag](https://sonity.gitbook.io/docs/soundevent#trigger-on-tail) Trigger On Tail ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FrEH6yCYfrsaedXhq2il6%2Fimage26.png&width=768&dpr=3&quality=100&sign=9bcbacf9&sv=2) Triggers another [SoundEvent](https://sonity.gitbook.io/docs/soundevent) "Tail Length" before the end. It looks at the time of the last played voice on the first [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) . Useful for music, e.g. if you have an intro with a 2 second tail and a loop you want to play on the tail of the intro. If you play with [SoundManager](https://sonity.gitbook.io/docs/soundmanager) .PlayMusic, you can stop the next [SoundEvent](https://sonity.gitbook.io/docs/soundevent) with [SoundManager](https://sonity.gitbook.io/docs/soundmanager) .StopAllMusic without a reference. If you want it to trigger itself, make sure to set the "Settings" polyphony to 2. If the trigger timing is not tight enough, try setting the AudioClip "Compression Format" to PCM or ADPCM (Vorbis is less accurate). **Tail Length** How long in seconds before the end of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to trigger the next [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . It looks at the time of the last played voice on the first [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) . It takes into account pitch when calculating time. For example, if the tail length is 2 seconds and you pitch it +12 semitones (2x speed) the internal tail length will be 1 seconds. This is because double the speed with half the duration and vice versa. **Set Tail Length from BPM & Beats** Calculates the Tail Length from the BPM and the Beats settings. **BPM** Beats per minute. **Beats** How long the tail is in beats. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#soundtag) SoundTag ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FKui91RIi37n74bY9hOJm%252FSoundEvent%2520SoundTag.gif%3Falt%3Dmedia%26token%3D59eefca7-bd0f-4945-a3ac-50dc26743c2f&width=768&dpr=3&quality=100&sign=41eb19d1&sv=2) Uses [SoundTag](https://sonity.gitbook.io/docs/soundtag) to play other [SoundEvents](https://sonity.gitbook.io/docs/soundevent) and/or change [SoundEventModifier](https://sonity.gitbook.io/docs/modifiers) . The [SoundTag](https://sonity.gitbook.io/docs/soundtag) won't be passed to the [SoundEvents](https://sonity.gitbook.io/docs/soundevent) of the [SoundTag](https://sonity.gitbook.io/docs/soundtag) in order to avoid infinite repetitions. **Mode** If local [SoundTag](https://sonity.gitbook.io/docs/soundtag) is selected you need to pass an [SoundTag](https://sonity.gitbook.io/docs/soundtag) when playing the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . If global [SoundTag](https://sonity.gitbook.io/docs/soundtag) is selected you need to set the [SoundTag](https://sonity.gitbook.io/docs/soundtag) on the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . **SoundTag** If this [SoundTag](https://sonity.gitbook.io/docs/soundtag) is selected the SoundEvents below will be played. **Modifiers** If enabled the selected [modifiers](https://sonity.gitbook.io/docs/modifiers) will be applied to the base [SoundEvent](https://sonity.gitbook.io/docs/soundevent) and the [SoundEvents](https://sonity.gitbook.io/docs/soundevent) of the [SoundTag](https://sonity.gitbook.io/docs/soundtag) . [Modifiers](https://sonity.gitbook.io/docs/modifiers) are used to control how [SoundEvents](https://sonity.gitbook.io/docs/soundevent) are played (e.g. volume, polyphony, fade in length etc). See [Modifiers](https://sonity.gitbook.io/docs/modifiers) for more info. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#debug) Debug ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FFlINxC5F9unsAAvaKYt7%2Fimage33.png&width=768&dpr=3&quality=100&sign=62a9de40&sv=2) Contains settings on how the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be debugged. **Log View** If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be viewed or hidden from the [SoundManager Debug Log SoundEvents](https://sonity.gitbook.io/docs/soundmanager#log-soundevents) . Force show will make it always debug even if [SoundManager Debug Log SoundEvents](https://sonity.gitbook.io/docs/soundmanager#log-soundevents) is disabled. **Draw View** If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be viewed or hidden from the [SoundManager Debug Draw SoundEvents](https://sonity.gitbook.io/docs/soundmanager#draw-soundevents) . **Override Draw Style** Overrides the debug draw style set in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . Override Draw Style: **Font Size Multiplier** Multiplier of the font size. Override Draw Style: **Opacity Multiplier** Multiplier of the opacity of the Debug Draw text. Override Draw Style: **Start Color** The color the text should have when it starts playing. Override Draw Style: **End Color** Which color the text should fade to over the lifetime. Override Draw Style: **Outline Color** The color of the text outline. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#find-references) Find References ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2F6OsEFaNRUE3tSSHgQBpr%2Fimage21.gif&width=768&dpr=3&quality=100&sign=4c1bb2e1&sv=2) **Find References** Finds all the references to the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . **Select All** Selects all the assets with references to the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . **Clear** Removes all the found references. ### [hashtag](https://sonity.gitbook.io/docs/soundevent#asset-guid) Asset GUID The ID of an asset is cached in the editor because in some cases when using addressables a single scriptable object might be instantiated multiple times. This might lead to problems where a simple "Object == Object" check will return false, but a "ID == ID" will return true. If you are upgrading Sonity and use addressable assets you probably want to select all Sonity scriptable objects and run: "Tools/Sonity 🔊/Set Selected Assets as Dirty (Force Reserialize for Resave)" which will force the assets to cache the GUIDs. You can search t:[SoundEvent](https://sonity.gitbook.io/docs/soundevent) , t:[SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) , t:[SoundTag](https://sonity.gitbook.io/docs/soundtag) , t:[SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) , t:[SoundDataGroup](https://sonity.gitbook.io/docs/sounddatagroup) , t:[SoundMix](https://sonity.gitbook.io/docs/soundmix) , t:[SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics) to find all objects. If no GUID is cached then it will use the InstanceID in builds. The free trial version doesn't have full functionality. [PreviousSteam Audio Settingschevron-left](https://sonity.gitbook.io/docs/soundcontainer/steam-audio-settings) [NextSoundEvent Functionschevron-right](https://sonity.gitbook.io/docs/soundevent/soundevent-functions) Last updated 1 month ago * [SoundEvent](https://sonity.gitbook.io/docs/soundevent#soundevent) * [Notes](https://sonity.gitbook.io/docs/soundevent#notes) * [Presets](https://sonity.gitbook.io/docs/soundevent#presets) * [Mute, Solo, Disable](https://sonity.gitbook.io/docs/soundevent#mute-solo-disable) * [Preview](https://sonity.gitbook.io/docs/soundevent#preview) * [Spatialization Info](https://sonity.gitbook.io/docs/soundevent#spatialization-info) * [SoundContainers](https://sonity.gitbook.io/docs/soundevent#soundcontainers) * [Timeline](https://sonity.gitbook.io/docs/soundevent#timeline) * [Base](https://sonity.gitbook.io/docs/soundevent#base) * [Modifiers](https://sonity.gitbook.io/docs/soundevent#modifiers) * [Settings](https://sonity.gitbook.io/docs/soundevent#settings) * [Advanced Settings](https://sonity.gitbook.io/docs/soundevent#advanced-settings) * [Intensity](https://sonity.gitbook.io/docs/soundevent#intensity) * [Trigger Other](https://sonity.gitbook.io/docs/soundevent#trigger-other) * [SoundTag](https://sonity.gitbook.io/docs/soundevent#soundtag) * [Debug](https://sonity.gitbook.io/docs/soundevent#debug) * [Find References](https://sonity.gitbook.io/docs/soundevent#find-references) * [Asset GUID](https://sonity.gitbook.io/docs/soundevent#asset-guid) sun-brightdesktopmoon sun-brightdesktopmoon --- # SoundTrigger | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252F1qfFGK4vgc2SK1KnSNp6%252F9%2520SoundTrigger%2520Reference%25203K%2520LAPTOP.png%3Falt%3Dmedia%26token%3Dbb0f5e1a-9653-4846-9e52-55c74c416ac4&width=768&dpr=3&quality=100&sign=c31f939d&sv=2) SoundTrigger is a component used for easily playing/stopping [SoundEvents](https://sonity.gitbook.io/docs/soundevent) on callbacks built into Unity like Enable, Disable, OnCollisionEnter etc. They contain [SoundEvents](https://sonity.gitbook.io/docs/soundevent) with modifiers and triggers which decide when it should play or stop. [SoundTriggers](https://sonity.gitbook.io/docs/soundtrigger) also have a radius handle, which is visually editable in the scene viewport for easy adjustment of how far [SoundEvents](https://sonity.gitbook.io/docs/soundevent) should be heard. All [SoundTrigger](https://sonity.gitbook.io/docs/soundtrigger) components are multi-object editable. ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FSKd7aIejDcpxMGcrj0O9%252FSoundTrigger%2520Component%2520Add.gif%3Falt%3Dmedia%26token%3Dcd988321-4e0c-447b-aad4-a632a5e14e84&width=768&dpr=3&quality=100&sign=ab737ac5&sv=2) **Distance Radius** Distance of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) (how far it should be heard). **Modifiers** Modifiers are used to control how [SoundEvents](https://sonity.gitbook.io/docs/soundevent) are played (e.g. volume, polyphony, fade in length etc). See [modifiers](https://sonity.gitbook.io/docs/modifiers) for more info. ### [hashtag](https://sonity.gitbook.io/docs/soundtrigger#triggers) **Triggers** Using the triggers you can select when an action happens. ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FiMdJmFr47sb1FUWlYlMs%252FSoundTrigger%2520Triggers.png%3Falt%3Dmedia%26token%3D95b0f89b-5828-422c-bd99-f02ede91d867&width=768&dpr=3&quality=100&sign=eb8dd7c1&sv=2) **On Trigger and On Collision - Tag** If enabled, the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) will only play if the triggering object has a tag matching the selected tags. **On Collision - Velocity to Intensity** If enabled, the velocity magnitude will be passed as an intensity parameter. ### [hashtag](https://sonity.gitbook.io/docs/soundtrigger#actions) **Actions** For each trigger you can select what it should do to the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FEz318pdMglQW2G4uG695%2Fimage7.png&width=768&dpr=3&quality=100&sign=d7990ef1&sv=2) ### [hashtag](https://sonity.gitbook.io/docs/soundtrigger#custom-override) Custom Override You can override the functionality and editor of the [SoundTrigger](https://sonity.gitbook.io/docs/soundtrigger) and extend it with custom functionality. Example result: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2F7vJnrc71X4Xsun3BfOhs%2Fimage30.png&width=768&dpr=3&quality=100&sign=e259b866&sv=2) Create these scripts to get started: [PreviousSoundParameterIntensitychevron-left](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) [NextSoundTrigger Functionschevron-right](https://sonity.gitbook.io/docs/soundtrigger/soundtrigger-functions) Last updated 1 month ago * [Triggers](https://sonity.gitbook.io/docs/soundtrigger#triggers) * [Actions](https://sonity.gitbook.io/docs/soundtrigger#actions) * [Custom Override](https://sonity.gitbook.io/docs/soundtrigger#custom-override) sun-brightdesktopmoon SoundTriggerCustom.cs Copy using Sonity; public class SoundTriggerCustom : SoundTrigger { // Add custom code or functionality here public bool customBoolShouldPlay = true; // Example override, you can override e.g. OnTriggerEnter etc. protected override void OnEnable() { if (customBoolShouldPlay) { base.OnEnable(); } } } SoundTriggerCustomEditor.cs Copy using Sonity.Internal; using UnityEditor; #if UNITY_EDITOR [CustomEditor(typeof(SoundTriggerCustom))] [CanEditMultipleObjects] public class SoundTriggerCustomEditor : SoundTriggerEditor { private SoundTriggerCustom soundTriggerCustom; protected override void OnEnable() { base.OnEnable(); // Get the target property soundTriggerCustom = (SoundTriggerCustom)target; } public override void OnInspectorGUI() { // Draw the new property for the custom editor BeginChange(); SerializedProperty customBoolShouldPlay = serializedObject.FindProperty(nameof(SoundTriggerCustom.customBoolShouldPlay)); EditorGUILayout.PropertyField(customBoolShouldPlay); EndChange(); // Draw the original GUI base.OnInspectorGUI(); } } #endif sun-brightdesktopmoon --- # Steam Audio Integration | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FDQZHA7b3jyqWtdDNbzlt%2Fimage5.png&width=768&dpr=3&quality=100&sign=81603516&sv=2) The Steam Audio Sonity integration can be enabled in the [SoundManager Settings](https://sonity.gitbook.io/docs/soundmanager#third-party-integrations) . You also need to install the [Steam Audio Unity asset packagearrow-up-right](https://github.com/ValveSoftware/steam-audio/releases) . And add the Script Define Symbol "SONITY\_ENABLE\_INTEGRATION\_STEAM\_AUDIO". The free trial version of Sonity doesn’t support this feature because it uses Scripting Define Symbols. It is tested and working on Steam Audio version 4.6.1. Steam Audio adds features like: * [Occlusionarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/guide.html#model-occlusion-by-geometry) of sound sources. * [Reflectionsarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/guide.html#model-reflection-by-geometry) and related environmental audio effects. * [Propagationarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/guide.html#model-sound-paths-from-a-moving-source-to-a-moving-listener) of sound along multiple paths. When using Steam Audio in combination with Voice Preload you should enable Async Startup because Steam Audio isn't ready on Awake(). Also note that Steam Audio at the moment is not available for all platforms. ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration#getting-started) Getting Started 1. Go to the valve github [https://github.com/ValveSoftware/steam-audio/releasesarrow-up-right](https://github.com/ValveSoftware/steam-audio/releases) 2. Download steamaudio\_unity\_X.X.X.zip and locate the file SteamAudio.unitypackage. 3. Drag and drop the Steam Audio unitypackage into Unity and import the contents. 4. Enable “Steam Audio” in the [SoundManager Settings](https://sonity.gitbook.io/docs/soundmanager#third-party-integrations) . 5. Add the Script Define Symbol "SONITY\_ENABLE\_INTEGRATION\_STEAM\_AUDIO" by pressing the “Add Scripting Define Symbol” button. 6. You may need to restart the Unity project. This adds the [SoundContainer Settings - Steam Audio](https://sonity.gitbook.io/docs/soundcontainer/steam-audio-settings) tab where you can select how the sound will be played in Steam Audio. ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2F9CtXuqqNVOCuFiUB4LLA%2Fimage11.gif&width=768&dpr=3&quality=100&sign=3bc2e9a2&sv=2) **SoundContainer - HRTF Plugin Spatialize** Spatialize makes the sound be affected by Steam Audio with effects like occlusion, reflections and more. Disable Spatialize for 2D sounds like music etc. ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration#audio-spatializer) **Audio Spatializer** ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FQQct4k6gj1BnWp1pE3Mp%2Fimage14.png&width=768&dpr=3&quality=100&sign=87ade202&sv=2) You can also change the Spatializer to Steam Audio Spatializer in the project settings. **Project Settings > Audio > Spatializer Plugin** This changes the spatialization for all the sounds in the project. You also need to enable **HRTF Plugin Spatialize** in the [SoundContainer Settings](https://sonity.gitbook.io/docs/soundcontainer#advanced-settings) . ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration#steamaudiosettings) **SteamAudioSettings** ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FKOppcWfoWVtHw2ifE8BI%2Fimage31.png&width=768&dpr=3&quality=100&sign=1adf09f6&sv=2) You can also change settings for Steam Audio in the SteamAudioSettings.asset. Which is automatically created and located at Plugins\\SteamAudio\\Resources. ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration#steam-audio-official-valve-documentation-links) Steam Audio Official Valve documentation links: **Steam Audio - Basics** * [Getting Startedarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/getting-started.html) * [Referencearrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/reference.html) **Steam Audio - Features** * [Tag Acoustic Geometryarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/guide.html#tag-acoustic-geometry) * [Set Up Dynamic Movable Geometryarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/guide.html#set-up-dynamic-movable-geometry) * [Model Occlusion by Geometryarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/guide.html#model-occlusion-by-geometry) * [Model Transmission Through Geometryarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/guide.html#model-transmission-through-geometry) * [Model Reflection by Geometryarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/guide.html#model-reflection-by-geometry) * [Simulate Physics Based Reverb at the Listener Positionarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/guide.html#simulate-physics-based-reverb-at-the-listener-position) * [Create Sound Probes for Baked Sound Propagationarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/guide.html#create-sound-probes-for-baked-sound-propagation) * [Bake Physics Based Reverbarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/guide.html#bake-physics-based-reverb) * [Model Sound Paths From a Moving Source to a Moving Listenerarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/guide.html#model-sound-paths-from-a-moving-source-to-a-moving-listener) * [Enable GPU Accelerationarrow-up-right](https://valvesoftware.github.io/steam-audio/doc/unity/guide.html#enable-gpu-acceleration) [PreviousThird Party Integrationschevron-left](https://sonity.gitbook.io/docs/third-party-integrations) [NextPlayMaker Integrationchevron-right](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration) Last updated 1 month ago * [Getting Started](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration#getting-started) * [Audio Spatializer](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration#audio-spatializer) * [SteamAudioSettings](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration#steamaudiosettings) * [Steam Audio Official Valve documentation links:](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration#steam-audio-official-valve-documentation-links) sun-brightdesktopmoon sun-brightdesktopmoon --- # SoundParameterIntensity | Sonity Docs [hashtag](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity#soundparameterintensity) SoundParameterIntensity ------------------------------------------------------------------------------------------------------------------------------------- [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) is used to pass an intensity value to a [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) when playing a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . This value can be anything you want to affect your sound, e.g. velocity, the size of an explosion, the speed of a car, etc. The [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) can scale and use the intensity parameter to control intensity options e.g. volume, pitch, distortion etc. circle-info ❕ Tip: You can record and debug the intensity at the [Intensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) in the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . ### [hashtag](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity#oneshot-intensity-physics-impacts) Oneshot Intensity - Physics Impacts Example code: Copy using UnityEngine; using Sonity; public class ExampleIntensityParameterCollision: MonoBehaviour { public SoundEvent soundImpact; private SoundParameterIntensity soundIntensityParameter = new SoundParameterIntensity(1f, UpdateMode.Once); void OnCollisionEnter(Collision collision) { // Sets the intensity parameter to the velocity of the collision soundIntensityParameter.Intensity = collision.relativeVelocity.magnitude; // Plays the SoundEvent with the intensity parameter soundImpact.Play(transform, soundIntensityParameter); } } #### [hashtag](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity#physics-impact-soundcontainer) **Physics Impact - SoundContainer** The velocity of the impact is passed once as an intensity parameter which controls the intensity volume and intensity lowpass filter of the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) . (Check out the [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) component for easily playing physics sounds) For volume intensity you can crossfade between any number of layers (eg. hard/medium/soft) easily and accurately. ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FxUdZpwdsiIqszym79lzs%252FSoundContainer%2520physics%2520impact%2520example.gif%3Falt%3Dmedia%26token%3Dd5ca2c8f-c98b-4e79-a999-5ba28581008e&width=768&dpr=3&quality=100&sign=d75aaa24&sv=2) The default settings of the lowpass filter intensity settings make the sound more filtered the lower the intensity value is. E.g. 0 intensity is maximum filter effect and 1 intensity is unfiltered. ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2Fo4Ldxxc1PH7XnGKZUf7K%2Fimage20.png&width=768&dpr=3&quality=100&sign=f9b485d5&sv=2) ### [hashtag](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity#continuous-intensity-car-engine) Continuous Intensity - Car Engine Example code: #### [hashtag](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity#car-engine-soundcontainer) **Car Engine - SoundContainer** The speed of the car is passed as an continuous intensity parameter which controls the intensity pitch and volume of the [SoundContainerarrow-up-right](https://docs.google.com/document/d/1w0XR7moiz718mc4O2G7rkR2CzU43B0bbH9fRRtfcvoU/edit#heading=h.o0ga11n34y22) . ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FZGgDDxuhrcZXaEnxZTq2%2Fimage88.png&width=768&dpr=3&quality=100&sign=61bc7eb1&sv=2) [PreviousSoundParameterchevron-left](https://sonity.gitbook.io/docs/soundparameter) [NextSoundTriggerchevron-right](https://sonity.gitbook.io/docs/soundtrigger) Last updated 1 month ago * [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity#soundparameterintensity) * [Oneshot Intensity - Physics Impacts](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity#oneshot-intensity-physics-impacts) * [Continuous Intensity - Car Engine](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity#continuous-intensity-car-engine) sun-brightdesktopmoon Copy using UnityEngine; using Sonity; public class ExampleIntensityParameterContinuous: MonoBehaviour { public SoundEvent soundCarLoop; public bool soundCarIsPlaying = false; private SoundParameterIntensity soundIntensityParameter = new SoundParameterIntensity(0f, UpdateMode.Continuous); public Rigidbody carRigidbody; void FixedUpdate() { float velocity = carRigidbody.linearVelocity.magnitude; // Sets the intensity parameter to the velocity of the car every physics update intensityParameter.Intensity = velocity; if (!soundCarIsPlaying && velocity > 0.01f) { soundCarIsPlaying = true; // Plays the SoundEvent with the intensity parameter soundCarLoop.Play(transform, soundIntensityParameter); } else if (soundCarIsPlaying && velocity <= 0.01f) { soundCarIsPlaying = false; soundCarLoop.Stop(transform); } } } sun-brightdesktopmoon --- # SoundParameter | Sonity Docs [SoundParameters](https://sonity.gitbook.io/docs/soundparameter) are used to control how [SoundEvents](https://sonity.gitbook.io/docs/soundevent) are played (e.g. volume, polyphony, fade in length etc). They can be passed when playing a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) and set to update either once or continuously. They have similar functionality as the [modifiers](https://sonity.gitbook.io/docs/modifiers) , but with scripting capabilities. Example code: Copy using UnityEngine; using Sonity; public class ExampleSoundParameter : MonoBehaviour { public SoundEvent soundEvent; SoundParameterVolumeDecibel volumeParameter = new SoundParameterVolumeDecibel(0f, UpdateMode.Once); void Start() { // Sets the volume parameter to a random value between -12 dB and 0 dB volumeParameter.VolumeDecibel = Random.Range(-12f, 0f); // Plays the SoundEvent with the sound parameter soundEvent.Play(transform, volumeParameter); } } **Update Modes** The UpdateMode enum determines if the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) will take the parameter into consideration only once at start or if it will be updated continuously. Copy // The SoundParameter will update only once UpdateMode.Once // The SoundParameter will update continuously UpdateMode.Continuous **Parameter Types** The parameter type determines which parameter of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) will be controlled. See [modifiers](https://sonity.gitbook.io/docs/modifiers) for more detailed info on the individual parameters. [PreviousModifierschevron-left](https://sonity.gitbook.io/docs/modifiers) [NextSoundParameterIntensitychevron-right](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) Last updated 1 month ago sun-brightdesktopmoon Copy // Volume offset in decibel. Range -Infinity to 0 public class SoundParameterVolumeDecibel(float volumeDecibel = 0f, UpdateMode updateMode = UpdateMode.Once); // Volume ratio multiplier. Range 0f to 1f public class SoundParameterVolumeRatio(float volumeRatio = 1f, UpdateMode updateMode = UpdateMode.Once); // Pitch offset in semitones public class SoundParameterPitchSemitone(float pitchSemitone = 0f, UpdateMode updateMode = UpdateMode.Once); // Pitch offset ratio multiplier. Range 0 to Infinity public class SoundParameterPitchRatio(float pitchRatio = 1f, UpdateMode updateMode = UpdateMode.Once); // Delay increase. Range 0 to Infinity public class SoundParameterDelay(float delay = 0f); // Makes the sound more 2D (less spatialized). Range 0 to 1 public class SoundParameterIncrease2D(float increase2D = 0f, UpdateMode updateMode = UpdateMode.Once); // Controls the intensity of the SoundContainer // Go to the SoundContainer to change how intensity will affect the sound public class SoundParameterIntensity(float intensity = 1f, UpdateMode updateMode = UpdateMode.Once); // Reverb zone mix offset in decibel. Range -Infinity to 0 public class SoundParameterReverbZoneMixDecibel(float reverbZoneMixDecibel = 0f, UpdateMode updateMode = UpdateMode.Once); // Reverb zone mix ratio multiplier. Range 0 to 1 public class SoundParameterReverbZoneMixRatio(float reverbZoneMixRatio = 1f, UpdateMode updateMode = UpdateMode.Once); // Reverb zone mix ratio multiplier. Range 0 to 1 public class SoundParameterReverbZoneMixRatio(float reverbZoneMixRatio = 1f, UpdateMode updateMode = UpdateMode.Once); // Start position. Range 0 to 1 public class SoundParameterStartPosition(float startPosition = 0f); // If the sound should be played backwards. If enabled, set the start position to the end. // Reverse is only supported for AudioClips which are stored in an uncompressed format or will be decompressed at load time. public class SoundParameterReverse(bool reverse = false); // The polyphony of the SoundEvent. Range 1 to int.MaxValue public class SoundParameterPolyphony(int polyphony = 1); // Distance scale multiplier. Range 0 to Infinity public class SoundParameterDistanceScale(float distanceScale = 1f); // Distortion increase. Range 0 to 1 public class SoundParameterDistortionIncrease(float distortionIncrease = 1f, UpdateMode updateMode = UpdateMode.Once); // Fade in length. Range 0 to Infinity public class SoundParameterFadeInLength(float fadeInLength = 0f, UpdateMode updateMode = UpdateMode.Once); // Fade in shape. Range -16 to 16 (negative is exponential, 0 is linear, positive is logarithmic); public class SoundParameterFadeInShape(float fadeInShape = 2f, UpdateMode updateMode = UpdateMode.Once); // Fade out length. Range 0 to Infinity public class SoundParameterFadeOutLength(float fadeOutLength = 0f, UpdateMode updateMode = UpdateMode.Once); // Fade out shape. Range -16 to 16 (negative is exponential, 0 is linear, positive is logarithmic); public class SoundParameterFadeOutShape(float fadeOutShape = -2f, UpdateMode updateMode = UpdateMode.Once); // If the SoundEvent should follow the Transform position public class SoundParameterFollowPosition(bool followPosition = true, UpdateMode updateMode = UpdateMode.Once); // If reverb zones should be bypassed public class SoundParameterBypassReverbZones(bool bypassReverbZones = false, UpdateMode updateMode = UpdateMode.Once); // If voice effects (distortion/lowpass/highpass) should be bypassed public class SoundParameterBypassVoiceEffects(bool bypassEffects = false, UpdateMode updateMode = UpdateMode.Once); // If listener effects should be bypassed public class SoundParameterBypassListenerEffects(bool bypassListenerEffects = false, UpdateMode updateMode = UpdateMode.Once); sun-brightdesktopmoon --- # PlayMaker Integration | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FDQZHA7b3jyqWtdDNbzlt%2Fimage5.png&width=768&dpr=3&quality=100&sign=81603516&sv=2) The PlayMaker Sonity integration can be enabled in the [SoundManager Settings](https://sonity.gitbook.io/docs/soundmanager#third-party-integrations) . You also need to install the PlayMaker Unity asset package. And add the Script Define Symbol "SONITY\_ENABLE\_INTEGRATION\_PLAYMAKER". The free trial version of Sonity doesn’t support this feature because it uses Scripting Define Symbols. It is tested and working on PlayMaker version 1.9.8. PlayMaker adds easy access to visual scripting. Example usage: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252F0mBUQwewyqFdG0Xls6pG%252FPlayMaker%2520Example.gif%3Falt%3Dmedia%26token%3Dac670e47-253f-4586-a123-13e3d96031fb&width=768&dpr=3&quality=100&sign=7acf9632&sv=2) Below is a list of all available PlayMaker actions for Sonity's third party integration. Most of this information is also available as tooltips by hovering the Action inside Unity. ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-play) Sonity Play Actions Sonity Play Sound Play the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) at the position of this GameObject Sonity Play Sound At Transform Plays the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) at the position of input Vector3 Sonity Play Sound At Vector3 Plays the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) at the position of the owner Transform Parameters SoundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to play SoundTag The [SoundTag](https://sonity.gitbook.io/docs/soundtag) which will determine the Local [SoundTag](https://sonity.gitbook.io/docs/soundtag) of the SoundEvent Vector3 The Vector3 position to play from. Transform The Game Object Transform to play the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) from. Use Parameters Enables the use of [SoundParameters](https://sonity.gitbook.io/docs/soundparameter) . For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundparameter) is used to modify how the SoundEvent is played Actions Sonity Play Sound Play the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) at the position of this GameObject Sonity Play Sound At Transform Plays the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) at the position of input Vector3 Sonity Play Sound At Vector3 Plays the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) at the position of the owner Transform Parameters SoundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to play SoundTag The [SoundTag](https://sonity.gitbook.io/docs/soundtag) which will determine the Local [SoundTag](https://sonity.gitbook.io/docs/soundtag) of the SoundEvent Vector3 The Vector3 position to play from. Transform The Game Object Transform to play the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) from. Use Parameters Enables the use of [SoundParameters](https://sonity.gitbook.io/docs/soundparameter) . For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundparameter) is used to modify how the SoundEvent is played ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-stop) Sonity Stop Actions Sonity Stop Sound Play the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) at the position of this GameObject Sonity Stop At Position Stop the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) playing at the GameObject Transform. Sonity Stop All At Owner Stop all [SoundEvents](https://sonity.gitbook.io/docs/soundevent) playing on this GameObject. Sonity Stop Everywhere Stop all instances of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Sonity Stop Everything Stop the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) with fadeout. Disabling this stops the sound immediately. Parameters SoundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to stop. AllowFadeout Stop the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) with fadeout. Disabling this stops the sound immediately. TargetGameObject The GameObject Transform on which to stop the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-pause-and-unpause) Sonity Pause and Unpause Actions Pause Pauses a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) playing on a GameObject. Pause All At Owner Pauses all [SoundEvents](https://sonity.gitbook.io/docs/soundevent) playing on a GameObject. Pause Everything Pauses all [SoundEvents](https://sonity.gitbook.io/docs/soundevent) currently playing. Pause Everywhere Pause all instances of the chosen [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Unpause Unpauses a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) playing on a GameObject. Unpause All At Owner Unpauses all [SoundEvents](https://sonity.gitbook.io/docs/soundevent) playing on a GameObject. Unpause Everything Unpauses all [SoundEvents](https://sonity.gitbook.io/docs/soundevent) currently playing. Unpause Everywhere Unpauses all instances of the chosen [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Parameters SoundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to pause/unpause. TargetGameObject The GameObject Transform on which to pause/unpause the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . ForcePause Pauses [SoundEvent](https://sonity.gitbook.io/docs/soundevent) even if it is set to "Ignore Local Pause". ForceUnpause Unpauses [SoundEvent](https://sonity.gitbook.io/docs/soundevent) even if it is set to "Ignore Local Pause". ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-soundparameters) Sonity SoundParameters [SoundParameters](https://sonity.gitbook.io/docs/soundparameter) add an extra layer of control that allows for greater modification of [SoundEvents](https://sonity.gitbook.io/docs/soundevent) (e.g. volume, distortion, pitch etc). They can be added when first playing a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) and set to update either once when playback starts or to continuously listen for updates. [Read more about SoundParamters](https://sonity.gitbook.io/docs/soundparameter) . #### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#enabling-soundparameters) **Enabling SoundParameters** By default, [SoundParameters](https://sonity.gitbook.io/docs/soundparameter) are not enabled on a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Enabling Use Parameters in a Play Action will reveal options to add [SoundParameters](https://sonity.gitbook.io/docs/soundparameter) to that event. Once enabled, there are several ways of configuring the parameters of a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . circle-info ❕ Note: You can only use one instance of the same type of each parameter, eg: adding 2 [SoundParameterVolume](https://sonity.gitbook.io/docs/soundparameter) will only use the last one. ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2Fvce7sI5bp3Wjxg16S8Ua%2Fimage99.gif&width=768&dpr=3&quality=100&sign=3eef941a&sv=2) circle-info 💡 TIP - Updating Parameter Values Continuously To create a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) action with an updatable parameter, set UpdateMode to Continuous and store the ParameterValue in an FSM Variable. When you want to update the value just change the FSM Variables and it will automatically update the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Options Use Parameters Enable to show [SoundParameter](https://sonity.gitbook.io/docs/soundparameter) options. Number of Parameters How many SoundParameters are active on this [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Max amount is 8. Show parameters Fold-out menu to show or hide [SoundParameters](https://sonity.gitbook.io/docs/soundparameter) in the GUI. Parameters Parameter type Select which [SoundParameter](https://sonity.gitbook.io/docs/soundparameter) to apply to the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Update mode Determines if the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) will take the parameter into consideration only Once at start or if it will be updated Continuously. Type \[Read only\] What type of value (float, bool, int) the [SoundParameter](https://sonity.gitbook.io/docs/soundparameter) takes. The type cannot be set, only read. Parameter value Value of the [SoundParameter](https://sonity.gitbook.io/docs/soundparameter) when playing the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Can be a value or an FsmVariable. ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-soundevent-info) Sonity SoundEvent Info Actions Get SoundEvent State Returns the current SoundEventState of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Get Last Played Clip Length Returns the current time (in range 0 to 1) of the AudioClip in the last played AudioSource. Get Last Played Clip Time Seconds Returns the current time (in seconds) of the AudioClip in the last played AudioSource. Returns 0 if the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is not playing or null, and if the Transform is null. Get Last Played Clip Time Ratio Returns the progress of playback (in range 0 to 1) of the AudioClip in the last played AudioSource. Returns 0 if the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is not playing or null, and if the Transform is null. Get Time Played Returns the time (in seconds) since the SoundEvent was played. Time is calculated using the time scale selected in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . Returns 0 if the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is not playing or null, and if the Transform is null. Get Contains Loop Returns true if any [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) in the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) are set to loop. Get Max Length Returns the max length (in seconds) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) (calculated from the longest AudioClip). The result is automatically scaled by the pitch of the sound. Parameters SoundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to pause. Target GameObject The GameObjectTransform on which to stop the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Pitch Speed Returned value is adjusted by the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) pitch value. Store State In FsmVariable to store the returned value in. ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-ui) Sonity UI UI SoundEvent Events do not need a GameObject reference. circle-info 💡 TIP - UI Play & Music Play There are many different actions for starting playback of a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . The standard way is using the Play action which allows for positional audio inside Unity. For sounds that do not need to be positioned, such as UI, there are the UIPlay methods. For music you can use MusicPlay. Any action that has “UI” or “Music” included in its name will only work on [SoundEvents](https://sonity.gitbook.io/docs/soundevent) played by the matching action. For example, using the MusicGetSoundEventState Action on a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) that was started using the normal action Play will not work. #### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#ui-play) UI Play Actions UI Play The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to play without needing to input an owner GameObject. Parameters SoundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to play. SoundTag The [SoundTag](https://sonity.gitbook.io/docs/soundtag) which will determine the Local [SoundTag](https://sonity.gitbook.io/docs/soundtag) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Use Parameters The GameObject Transform to play the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) from. #### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#ui-stop) UI Stop Actions UI Stop Stop UI [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . UI Stop All Stop all playing UI [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . Parameters SoundEvent The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to stop. Allow Fadeout Stop the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) with fadeout. Disabling this stops the sound immediately. #### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#ui-pause-and-unpause) UI Pause and Unpause UI Pause Pause the UI [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . UI Pause All Pause all playing UI [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . UI Unpause Unpause the UI [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . UI Unpause All Unpause all playing UI [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Parameters SoundEvent The UI [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to pause. Force Pause Pauses the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) even if it is set to "Ignore Local Pause". Force Unpause Unpauses the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) even if it is set to "Ignore Local Pause". #### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#ui-get-info) UI Get Info Actions UI Get Sound Event State Returns the current SoundEventState of the UI [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . UI Get Last Played Clip Length Returns length of the last played AudioClip as float seconds. Returns 0 if the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is not playing or null, and if the Transform is null. UI Get Last Played Clip Time Seconds Returns the current time (in range 0 to 1) of the AudioClip in the last played AudioSource. Returns 0 if the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is not playing or null, and if the Transform is null. UI Get Last Played Clip Time Ratio Returns the current time (in seconds) of the AudioClip in the last played AudioSource. Returns 0 if the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is not playing or null, and if the Transform is null. UI Get Time Played Returns the time (in seconds) since the UI SoundEvent was played. Time is calculated using the time scale selected in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . Returns 0 if the UI [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is not playing or null, and if the Transform is null. UI Get Transform Returns the owner Transform used when playing a UI [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Parameters Sound Event The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to get information from. Store State In Fsm Variable to store the returned value in. Pitch Speed Returned value is adjusted by the [SoundEvents](https://sonity.gitbook.io/docs/soundevent) pitch value. Eg. -12 semitones will be twice as long. ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-music) Sonity Music Music Event Actions are [SoundEvents](https://sonity.gitbook.io/docs/soundevent) with specific logic related to making music playback easier. Eg: Music Play do not need a GameObject owner reference. ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#music-play) Music Play Actions Music Play Play a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Currently playing music can optionally be set to stop when this event starts playing. Parameters Sound Event The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to play. Stop All Other Music Stop all other music events playing when this [SoundEvent](https://sonity.gitbook.io/docs/soundevent) starts playing. Allow Fadeout Enables or disables fadeout on stopped [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#music-stop) Music Stop Actions Music Stop Stop a Music [SoundEvent](https://sonity.gitbook.io/docs/soundevent) currently playing. Music Stop All Stop all Music [SoundEvent](https://sonity.gitbook.io/docs/soundevent) currently playing. Parameters Allow Fadeout Enables or disables fadeout on stopped [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . #### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#music-pause-and-unpause) Music Pause and Unpause Actions Music Pause Pause a Music [SoundEvent](https://sonity.gitbook.io/docs/soundevent) currently playing. Music Pause All Pause all Music [SoundEvents](https://sonity.gitbook.io/docs/soundevent) currently playing. Music Unpause Unpause a Music [SoundEvent](https://sonity.gitbook.io/docs/soundevent) currently playing. Music Unpause All Unpause all Music [SoundEvents](https://sonity.gitbook.io/docs/soundevent) currently playing. Parameters Sound Event The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to pause. Force Pause Pauses the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) even if it is set to "Ignore Local Pause". Force Unpause Unpauses the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) even if it is set to "Ignore Local Pause". #### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#music-get-info) Music Get Info Actions Music Get Sound Event State Returns the current SoundEventState of the Music [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Music Get Last Played Clip Length Returns length of the last played AudioClip as float seconds. Returns 0 if the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is not playing or null, and if the Transform is null. Music Get Last Played Clip Time Seconds Returns the current time (in range 0 to 1) of the AudioClip in the last played AudioSource. Returns 0 if the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is not playing or null, and if the Transform is null. Music Get Last Played Clip Time Ratio Returns the current time (in seconds) of the AudioClip in the last played AudioSource. Returns 0 if the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is not playing or null, and if the Transform is null. Music Get Time Played Returns the time (in seconds) since the Music [SoundEvent](https://sonity.gitbook.io/docs/soundevent) was played. Time is calculated using the time scale selected in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . Returns 0 if the Music [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is not playing or null, and if the Transform is null. Music Get Transform Returns the owner Transform used when playing a Music [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Parameters Sound Event The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to get information from. Store State In Fsm Variable to store the returned value in. Pitch Speed Returned value is adjusted by the [SoundEvents](https://sonity.gitbook.io/docs/soundevent) pitch value. Eg. -12 semitones will be twice as long. ### [hashtag](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-audio-data-load-unload) Sonity Audio Data Load Unload The Load and Unload Actions lets the user manually load or unload the audio data of a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . By default audio data is loaded when the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) first plays, unless you have enabled Preload Audio Data in the AudioClip. Manually loading or unloading can be used if you need to optimize the RAM usage of the audio assets. Actions Load Audio Data Loads the audio data of any AudioClips assigned to the [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Unload Audio Data Unloads the audio data of any AudioClips assigned to the [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . Parameters Sound Event The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) which to load or unload audio data from. [PreviousSteam Audio Integrationchevron-left](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration) [NextModifierschevron-right](https://sonity.gitbook.io/docs/modifiers) Last updated 1 month ago * [Sonity Play](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-play) * [Sonity Stop](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-stop) * [Sonity Pause and Unpause](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-pause-and-unpause) * [Sonity SoundParameters](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-soundparameters) * [Sonity SoundEvent Info](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-soundevent-info) * [Sonity UI](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-ui) * [Sonity Music](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-music) * [Music Play](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#music-play) * [Music Stop](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#music-stop) * [Sonity Audio Data Load Unload](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration#sonity-audio-data-load-unload) sun-brightdesktopmoon sun-brightdesktopmoon --- # SoundPicker | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FfD7VH0WUJYyOedhN7P3C%2Fimage8.png&width=768&dpr=3&quality=100&sign=2ed7257a&sv=2) [SoundPicker](https://sonity.gitbook.io/docs/soundpicker) is a serializable class for easily selecting multiple [SoundEvents](https://sonity.gitbook.io/docs/soundevent) and [modifiers](https://sonity.gitbook.io/docs/modifiers) . Add a serialized or public [SoundPicker](https://sonity.gitbook.io/docs/soundpicker) to a C# script and edit it in the inspector. The [SoundPicker](https://sonity.gitbook.io/docs/soundpicker) is not nestable in an array or custom class because it is built upon CustomPropertyDrawer. This is because custom serializable classes do not support inheritance and polymorphism for serialization. [SoundPickers](https://sonity.gitbook.io/docs/soundpicker) are multi-object editable. ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FMh8WO6YbJv42LKRKZfM9%2Fimage89.gif&width=768&dpr=3&quality=100&sign=47fd8ee4&sv=2) **SoundEvent** The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to play. **Modifiers** [Modifiers](https://sonity.gitbook.io/docs/modifiers) are used to control how [SoundEvents](https://sonity.gitbook.io/docs/soundevent) are played (e.g. volume, polyphony, fade in length etc). See [modifiers](https://sonity.gitbook.io/docs/modifiers) for more info. Example code: Copy using UnityEngine; using Sonity; public class ExampleSoundPicker : MonoBehaviour { public SoundPicker soundPicker; void Start() { // Plays the SoundPicker at the position of the transform soundPicker.Play(transform); } } [PreviousSoundPhysicschevron-left](https://sonity.gitbook.io/docs/soundphysics) [NextSoundPicker Functionschevron-right](https://sonity.gitbook.io/docs/soundpicker/soundpicker-functions) Last updated 1 month ago --- # SoundTrigger Functions | Sonity Docs ### [hashtag](https://sonity.gitbook.io/docs/soundtrigger/soundtrigger-functions#play) Play Copy // Plays the SoundEvent at the position of the owner Transform public void Play(); public void Play(SoundTag localSoundTag); public void Play(params SoundParameterInternals[] soundParameterInternals); public void Play(SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); Parameters localSoundTag The [SoundTag](https://sonity.gitbook.io/docs/soundtag) which will determine the Local [SoundTag](https://sonity.gitbook.io/docs/soundtag) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) soundParameterInternals For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundparameter) is used to modify how the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played ### [hashtag](https://sonity.gitbook.io/docs/soundtrigger/soundtrigger-functions#playatposition) PlayAtPosition Copy // Plays the SoundEvent at the Vector3 position with another Transform as the owner public void PlayAtPosition(Vector3 position); public void PlayAtPosition(Vector3 position, SoundTag localSoundTag); public void PlayAtPosition(Vector3 position, params SoundParameterInternals[] soundParameterInternals); public void PlayAtPosition(Vector3 position, SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); // Plays the SoundEvent at the Transform position with another Transform as the owner public void PlayAtPosition(Transform position); public void PlayAtPosition(Transform position, SoundTag localSoundTag); public void PlayAtPosition(Transform position, params SoundParameterInternals[] soundParameterInternals); public void PlayAtPosition(Transform position, SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); Parameters owner The owner Transform position The Transform or Vector3 where is should play at (Transform can follow position) localSoundTag The [SoundTag](https://sonity.gitbook.io/docs/soundtag) which will determine the Local [SoundTag](https://sonity.gitbook.io/docs/soundtag) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) soundParameterInternals For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundparameter) is used to modify how the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played ### [hashtag](https://sonity.gitbook.io/docs/soundtrigger/soundtrigger-functions#stop) Stop circle-info 💡 TIP - Stopping Loops You really only need to use stop for looping or longer oneshot sounds (or the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) “Stop if Transform is Null” setting). Use the polyphony setting in the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to manage the number of instances playing. Copy // Stops the SoundEvent at the owner Transform public void Stop(bool allowFadeOut = true); // Stops the SoundEvent at the position Transform public void StopAtPosition(Transform position, bool allowFadeOut = true); Parameters position The position Transform allowFadeOut If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be allowed to fade out. Otherwise it is going to be stopped immediately ### [hashtag](https://sonity.gitbook.io/docs/soundtrigger/soundtrigger-functions#pause-and-unpause) Pause and Unpause Copy // Pauses/unpauses the SoundEvent with the owner Transform locally public void Pause(bool forcePause = false); public void Unpause(); // Pauses/unpauses the SoundEvent everywhere locally public void PauseEverywhere(bool forcePause = false); public void UnpauseEverywhere(); Parameters forcePause If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be paused even if it is set to "Ignore Local Pause" ### [hashtag](https://sonity.gitbook.io/docs/soundtrigger/soundtrigger-functions#get-state) Get State Copy // If playing it returns SoundEventState.Playing // If paused either locally or globally it returns SoundEventState.Paused // If not playing, but it is delayed it returns SoundEventState.Delayed // If not playing and it is not delayed it returns SoundEventState.NotPlaying // If the SoundEvent or Transform is null it returns SoundEventState.NotPlaying public SoundEventState GetSoundEventState(Transform owner); ### [hashtag](https://sonity.gitbook.io/docs/soundtrigger/soundtrigger-functions#load-or-unload-audio-data) Load or Unload Audio Data Copy // Loads the audio data of any AudioClips assigned to the SoundContainers of the SoundEvent public void LoadAudioData(); // Unloads the audio data of any AudioClips assigned to the SoundContainers of the SoundEvent public void UnloadAudioData(); [PreviousSoundTriggerchevron-left](https://sonity.gitbook.io/docs/soundtrigger) [NextSoundPhysicschevron-right](https://sonity.gitbook.io/docs/soundphysics) Last updated 1 month ago --- # Legacy Support | Sonity Docs Sonity has legacy support for deprecated functions and conversions which can upgrade old assets to new standards. ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FDIviTRhdVfYpjM14ClQY%252FLegacy%2520Support.png%3Falt%3Dmedia%26token%3Db1490382-1464-4a71-b25d-d0f711d196e8&width=768&dpr=3&quality=100&sign=1086c464&sv=2) All legacy conversion tools are located at: “Tools/Sonity 🔊/Legacy/” * **Add Scripting Define Symbol for Legacy Functions Music and 2D** (Renamed Music/2D Functions in 1.1.0) * **Convert SoundEvent Modifier Volume and Polyphony to Base** (Added SoundEvent Base Settings in 1.0.6) * **Apply SoundContainer AudioMixerGroup to SoundEvent if None** (Removed SoundContainer AudioMixerGroup in 1.0.6) [PreviousUnity Native Audiochevron-left](https://sonity.gitbook.io/docs/sonity/unity-native-audio) [NextChangelogchevron-right](https://sonity.gitbook.io/docs/sonity/changelog) Last updated 1 month ago --- # How To Guides | Sonity Docs ### [hashtag](https://sonity.gitbook.io/docs/how-to-guides#optimize-audioclip-settings) [Optimize AudioClip Settings](https://sonity.gitbook.io/docs/how-to-guides#optimize-audioclip-settings) How to optimize the settings of your AudioClips to use less RAM and CPU ### [hashtag](https://sonity.gitbook.io/docs/how-to-guides#debug-sounds-and-performance) [Debug Sounds and Performance](https://sonity.gitbook.io/docs/how-to-guides#debug-sounds-and-performance) How to debug which sounds are playing and how much performance they use ### [hashtag](https://sonity.gitbook.io/docs/how-to-guides#rename-a-lot-of-assets) [Rename A Lot of Assets](https://sonity.gitbook.io/docs/how-to-guides/rename-a-lot-of-assets) How to quickly rename assets in Unity with search and replace etc ### [hashtag](https://sonity.gitbook.io/docs/how-to-guides#force-resave-assets) [Force Resave Assets](https://sonity.gitbook.io/docs/how-to-guides/force-resave-assets) How to select a ton of assets and force changes to be saved [PreviousChangelogchevron-left](https://sonity.gitbook.io/docs/sonity/changelog) [NextOptimize AudioClip Settingschevron-right](https://sonity.gitbook.io/docs/how-to-guides/optimize-audioclip-settings) Last updated 1 month ago --- # Create Assets From Selection | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FkJQwPl9k4zBHAeURK8sb%2Fimage28.gif&width=768&dpr=3&quality=100&sign=9dde4c31&sv=2) Right-click in the project menu to bring up the “Create Assets from Selection” menu. With this you can easily create all your sound assets quickly if your AudioClips are named right. * It works with folders as well as files. * If a [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) name contains “loop” it will automatically enable “Loop”, “Follow Position”, “Stop if Transform is Null” and “Random Start Position”. * It will automatically find out if you use space, hyphen “-” or underscore “\_” in your filenames and will style the file ending the same way (e.g. “\_SC”, “-SC” etc.) ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252Fl9CrMyAjfQx2lDgjazc2%252FCreate%2520Assets%2520From%2520Selection.png%3Falt%3Dmedia%26token%3D92ab4124-b453-4750-b996-50dbdb53f802&width=768&dpr=3&quality=100&sign=249078e&sv=2) **Shortcuts** SC+SE from AudioClip Group Multiple SE: Ctrl+Shift+Q SC+SE from AudioClip Group Single SE: Ctrl+Shift+W SoundPolyGroup for SE Multiple: Ctrl+Alt+Shift+Q SoundPolyGroup for SE Single: Ctrl+Alt+Shift+W They are rebindable in the Shortcuts window. **AudioClip Group** AudioClip groups are sounds with the same name, but different numbers in the end e.g 01, 02, 03 etc. **Create SoundContainers and multiple SoundEvents** In this example we select the bow and drill sounds and run “SC+SE from AudioClip Group Multiple SE”: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FOQn2Ax7hZ0w4llWJ0rqG%2Fimage96.gif&width=768&dpr=3&quality=100&sign=db06d5a8&sv=2) This creates 4 SoundContainers and 4 [SoundEvents](https://sonity.gitbook.io/docs/soundevent) , one per AudioClip group. **Create SoundContainers and a single SoundEvent** In this example we select the shoot sounds and run “SC+SE from AudioClip Group Single SE”: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2F5zQmwtQBei35KlkLKoU2%2Fimage19.gif&width=768&dpr=3&quality=100&sign=5c176471&sv=2) They contain 4 different groups which will create 4 [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) , one per group and a single [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . It will try to find a common denominator of the names of the [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) for naming the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . [PreviousGetting Startedchevron-left](https://sonity.gitbook.io/docs/sonity/getting-started) [NextTemplates & Exampleschevron-right](https://sonity.gitbook.io/docs/sonity/templates-and-examples) Last updated 1 month ago --- # SoundPhysics | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FLvx8m5a2juJA2oOZsCTR%252FSoundPhysics%2520Component.gif%3Falt%3Dmedia%26token%3D68392b64-0dc5-474c-acc4-4124996f564b&width=768&dpr=3&quality=100&sign=1a1be430&sv=2) (SoundPhysics is remade in Sonity 1.0.5 with expanded functionality) [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) is a component used for easily playing [SoundEvents](https://sonity.gitbook.io/docs/soundevent) on physics interactions. [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) is split up into 3D/2D versions with and without friction because of performance reasons. If friction sounds aren’t needed and performance is a priority then use the [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) with no friction. A Rigidbody/Rigidbody2D is required on this object. One or several Collider/Collider2D should be placed on this object or its children. Use intensity record in the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) for easy scaling of the velocity into a 0 to 1 range. All [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) components are multi-object editable. **Impact** Is triggered when the object starts touching a collider. OnCollision uses velocity from Collision.relativeVelocity.magnitude and the position of the Collision.contacts with the highest impulse.magnitude. OnTrigger uses velocity from Rigidbody.velocity.magnitude. **Friction** Is triggered when the object is continuously touching a collider. Uses velocity from Rigidbody.velocity.magnitude. **Exit** Is triggered when the object stops touching a collider. Uses velocity from Rigidbody.velocity.magnitude. **SoundEvent** The [SoundEvents](https://sonity.gitbook.io/docs/soundevent) which are to be played. **Play On** Selects if the [SoundEvents](https://sonity.gitbook.io/docs/soundevent) should be played when a OnCollision and/or OnTrigger event occurs. OnTrigger is when you have a collider which is set to “Is Trigger”. **Conditions** If enabled then any [SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) added will be used to decide if the physics interaction should play a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) or not. [SoundPhysicsConditions](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) can also be used for playing different sounds with a single [SoundEvent](https://sonity.gitbook.io/docs/soundevent) by assigning [SoundTags](https://sonity.gitbook.io/docs/soundtag) in the [SoundPhysicsConditions](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) . **SoundTags** If enabled then any [SoundTags](https://sonity.gitbook.io/docs/soundtag) added will be sent when triggering the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . If a [SoundTag](https://sonity.gitbook.io/docs/soundtag) is not null it will override any [SoundTags](https://sonity.gitbook.io/docs/soundtag) which might be sent through the [SoundPhysicsConditions](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) . [SoundTags](https://sonity.gitbook.io/docs/soundtag) can be used for triggering different sounds with a single [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . **Intensity** All [SoundEvents](https://sonity.gitbook.io/docs/soundevent) played with [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) are sent a velocity through the [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) . This can be used to control the sound e.g. making it quieter when the velocity is lower. Read more at [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) . For how to debug playing sounds in the scene/game view check out [SoundManager Draw SoundEvents](https://sonity.gitbook.io/docs/soundmanager#draw-soundevents) . Example of how to record and debug [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) . This is helpful for scaling the incoming velocity values to a 0 to 1 range. ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FhQCbfWbfp7O5esUflMCI%2Fimage6.gif&width=768&dpr=3&quality=100&sign=3bc7b123&sv=2) ### [hashtag](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) SoundPhysicsCondition ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252F2ZnNjKA6Ek7h6hPNEMvd%252FSoundPhysics%2520Condition.gif%3Falt%3Dmedia%26token%3D928feb28-1520-4894-a669-8f972d004a0f&width=768&dpr=3&quality=100&sign=ff547363&sv=2) [SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) objects are used in the ´component to decide if a physics interaction should play a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) or not. They make it easy to manage a large amount of physics objects and linking conditions together with the child nesting feature. You can also use them for playing different sounds with a single [SoundEvent](https://sonity.gitbook.io/docs/soundevent) by using [SoundTags](https://sonity.gitbook.io/docs/soundtag) . All [SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) objects are multi-object editable. **Notes** At the top of the [SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) there is a text field which you can fill with notes. **Children** You can nest [SoundPhysicsConditions](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) so you don't have to update all your [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) components when adding a new [SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) . The children of the parent [SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) are evaluated after the parent. **Parent** The parent [SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) is evaluated before the children. **SoundTag** By utilizing the [SoundTags](https://sonity.gitbook.io/docs/soundtag) you can play different sounds with a single [SoundEvent](https://sonity.gitbook.io/docs/soundevent) (see the example physics assets on how you can set that up). If no [SoundTag](https://sonity.gitbook.io/docs/soundtag) is assigned it won't affect the output [SoundTag](https://sonity.gitbook.io/docs/soundtag) , so if a child has an assigned [SoundTag](https://sonity.gitbook.io/docs/soundtag) and the parent doesn't, the child one will be used. They are useful to split into different child [SoundPhysicsConditions](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) with different [SoundTags](https://sonity.gitbook.io/docs/soundtag) . **Play On** Selects if it should be played when a OnCollision and/or OnTrigger event occurs. OnTrigger is when you have a collider which is set to “Is Trigger”. **Play Disregarding Conditions** If enabled the [SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) will play regardless of its own conditions. Useful to combine with child [SoundPhysicsConditions](https://sonity.gitbook.io/docs/soundphysics#soundphysicscondition) with different [SoundTags](https://sonity.gitbook.io/docs/soundtag) . **Abort All On No Match** If enabled and the assigned condition is not matched it will abort playing and disregard all other conditions. If not enabled and the assigned condition is not matched another condition which is met can play the sound. **Abort All On Match** If enabled and the assigned condition is matched it will abort playing and disregard all other conditions. If not enabled and the assigned condition is matched another condition which is met can play the sound. ### [hashtag](https://sonity.gitbook.io/docs/soundphysics#tag) **Tag** Checks if the Tag of the colliding GameObject matches any of the specified Tags. ### [hashtag](https://sonity.gitbook.io/docs/soundphysics#layer) **Layer** Checks if the Layer of the colliding GameObject matches any of the specified Layers. ### [hashtag](https://sonity.gitbook.io/docs/soundphysics#terrain-name) **Terrain Name** Checks if the name of the most dominant Terrain Layer of the colliding Terrain contains any of the specified strings (it is not case sensitive). E.g. you have multiple Terrain Layers with different grass textures, if the names of the Terrain Layers contain the string it will play the sound. Terrain conditions are only evaluated if the colliding object has a Terrain component. The center point of the [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) object is used to calculate the dominant Terrain Layer because it is more stable than the contacts. ### [hashtag](https://sonity.gitbook.io/docs/soundphysics#terrain-index) **Terrain Index** Checks if the index of the most dominant Terrain Layer of the colliding Terrain is any of the specified indexes. Terrain conditions are only evaluated if the colliding object has a Terrain component. The center point of the [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) object is used to calculate the dominant Terrain Layer because it is more stable than the contacts. ### [hashtag](https://sonity.gitbook.io/docs/soundphysics#component) **Component** Checks if the Components of the colliding GameObject match any of the specified Components. The names are case sensitive. ### [hashtag](https://sonity.gitbook.io/docs/soundphysics#asset-guid) Asset GUID The ID of an asset is cached in the editor because in some cases when using addressables a single scriptable object might be instantiated multiple times. This might lead to problems where a simple "Object == Object" check will return false, but a "ID == ID" will return true. If you are upgrading Sonity and use addressable assets you probably want to select all Sonity scriptable objects and run: "Tools/Sonity 🔊/Set Selected Assets as Dirty (Force Reserialize for Resave)" which will force the assets to cache the GUIDs. You can search t:[SoundEvent](https://sonity.gitbook.io/docs/soundevent) , t:[SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) , t:[SoundTag](https://sonity.gitbook.io/docs/soundtag) , t:[SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) , t:[SoundDataGroup](https://sonity.gitbook.io/docs/sounddatagroup) , t:[SoundMix](https://sonity.gitbook.io/docs/soundmix) , t:[SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics) to find all objects. If no GUID is cached then it will use the InstanceID in builds. The free trial version doesn't have full functionality. [PreviousSoundTrigger Functionschevron-left](https://sonity.gitbook.io/docs/soundtrigger/soundtrigger-functions) [NextSoundPickerchevron-right](https://sonity.gitbook.io/docs/soundpicker) Last updated 1 month ago --- # Unity Native Audio | Sonity Docs Sonity is built around the native audio system in Unity. So everything that Unity audio supports Sonity also supports. You can use built in features like: #### [hashtag](https://sonity.gitbook.io/docs/sonity/unity-native-audio#audioclip) [AudioCliparrow-up-right](https://docs.unity3d.com/Manual/class-AudioClip.html) Settings for your audio data. circle-info 💡 TIP - AudioClip Settings Music and longer sounds should probably be set to streaming as to use less memory. If you have problems with e.g. stuttering audio, try changing the Load Type of the AudioClips. Read more on: [How To - Optimize AudioClip Settings](https://sonity.gitbook.io/docs/how-to-guides/optimize-audioclip-settings) . #### [hashtag](https://sonity.gitbook.io/docs/sonity/unity-native-audio#audiomixer) [AudioMixerarrow-up-right](https://docs.unity3d.com/Manual/AudioMixer.html) For channel based effects like reverb sends, compression, ducking etc. Contains [AudioMixerGroupsarrow-up-right](https://docs.unity3d.com/Manual/AudioMixerInspectors.html) , which [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) and [SoundEvents](https://sonity.gitbook.io/docs/soundevent) can be assigned to output into. Can also expose parameters to enable real time editing of e.g. volume and reverb effects (see for example [TemplateSoundVolumeManager](https://sonity.gitbook.io/docs/sonity/templates-and-examples#templatesoundvolumemanager.cs) ). circle-info 💡 TIP - AudioMixer Performance Tips If you have issues with audio performance you might want to make sure you’re not using an unnecessary amount of AudioMixerGroups (like a hundred of them). Because changing AudioMixerGroup for a Voice uses performance (when playing a new Voice Sonity tries to find an unused Voice which uses the same AudioMixerGroup). Use AudioMixerGroups when you want effects per group or e.g. ducking or for larger groups of sounds, but maybe not a have a unique one for each sound. #### [hashtag](https://sonity.gitbook.io/docs/sonity/unity-native-audio#audio-mixer-snapshot) [Audio Mixer Snapshotarrow-up-right](https://docs.unity3d.com/ScriptReference/Audio.AudioMixerSnapshot.html) For switching between different effect settings in the Audio Mixer. #### [hashtag](https://sonity.gitbook.io/docs/sonity/unity-native-audio#reverb-zones) [Reverb Zonesarrow-up-right](https://docs.unity3d.com/Manual/class-AudioReverbZone.html) For reverb with different settings in different zones. #### [hashtag](https://sonity.gitbook.io/docs/sonity/unity-native-audio#audio-project-settings) [Audio Project Settingsarrow-up-right](https://docs.unity3d.com/Manual/class-AudioManager.html) For global settings of the audio like Buffer Size (latency), Speaker Mode (5.1, surround etc) and Spatializer Plugin (VR, vertical spatialization, steam audio, oculus/meta spatializer etc). circle-info 💡 TIP - Audio Buffer Size & Voice Count If you experience audio performance problems/stutter/dropouts you might want to raise your DSP Buffer Size to Good Latency or Best Performance. And maybe lower the number of voices your project is allocated. 32 Real Voices should be sufficient for most games and you really never need to go above 64 Real Voices in my experience. #### [hashtag](https://sonity.gitbook.io/docs/sonity/unity-native-audio#audio-listener) [Audio Listenerarrow-up-right](https://docs.unity3d.com/Manual/class-AudioListener.html) Need to be placed in the scene for audio to be heard. Is usually placed on the main camera or player. [PreviousFAQchevron-left](https://sonity.gitbook.io/docs/sonity/faq) [NextLegacy Supportchevron-right](https://sonity.gitbook.io/docs/sonity/legacy-support) Last updated 1 month ago --- # SoundPicker Functions | Sonity Docs ### [hashtag](https://sonity.gitbook.io/docs/soundpicker/soundpicker-functions#play) Play Copy // Plays the SoundEvent at the position of the owner Transform public void Play(Transform owner); public void Play(Transform owner, SoundTag localSoundTag); public void Play(Transform owner, params SoundParameterInternals[] soundParameterInternals); public void Play(Transform owner, SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); Parameters owner The owner Transform localSoundTag The [SoundTag](https://sonity.gitbook.io/docs/soundtag) which will determine the Local [SoundTag](https://sonity.gitbook.io/docs/soundtag) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) soundParameterInternals For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundparameter) is used to modify how the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played ### [hashtag](https://sonity.gitbook.io/docs/soundpicker/soundpicker-functions#playatposition) PlayAtPosition Copy // Plays the SoundEvent at the Vector3 position with another Transform as the owner public void PlayAtPosition(Transform owner, Vector3 position); public void PlayAtPosition(Transform owner, Vector3 position, SoundTag localSoundTag); public void PlayAtPosition(Transform owner, Vector3 position, params SoundParameterInternals[] soundParameterInternals); public void PlayAtPosition(Transform owner, Vector3 position, SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); // Plays the SoundEvent at the Transform position with another Transform as the owner public void PlayAtPosition(Transform owner, Transform position); public void PlayAtPosition(Transform owner, Transform position, SoundTag localSoundTag); public void PlayAtPosition(Transform owner, Transform position, params SoundParameterInternals[] soundParameterInternals); public void PlayAtPosition(Transform owner, Transform position, SoundTag localSoundTag, params SoundParameterInternals[] soundParameterInternals); Parameters owner The owner Transform position The Transform or Vector3 where is should play at (Transform can follow position) localSoundTag The [SoundTag](https://sonity.gitbook.io/docs/soundtag) which will determine the Local [SoundTag](https://sonity.gitbook.io/docs/soundtag) of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) soundParameterInternals For example [SoundParameterVolumeDecibel](https://sonity.gitbook.io/docs/soundparameter) is used to modify how the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is played ### [hashtag](https://sonity.gitbook.io/docs/soundpicker/soundpicker-functions#stop) Stop circle-info 💡 TIP - Stopping Loops You really only need to use stop for looping or longer oneshot sounds (or the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) “Stop if Transform is Null” setting). Use the polyphony setting in the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to manage the number of instances playing. Copy // Stops the SoundEvent at the owner Transform public void Stop(Transform owner, bool allowFadeOut = true); // Stops the SoundEvent at the position Transform public void StopAtPosition(Transform position, bool allowFadeOut = true); Parameters owner The owner Transform position The position Transform allowFadeOut If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be allowed to fade out. Otherwise it is going to be stopped immediately ### [hashtag](https://sonity.gitbook.io/docs/soundpicker/soundpicker-functions#pause-and-unpause) Pause and Unpause Copy // Pauses/unpauses the SoundEvent with the owner Transform locally public void Pause(Transform owner, bool forcePause = false); public void Unpause(Transform owner); // Pauses/unpauses the SoundEvent everywhere locally public void PauseEverywhere(bool forcePause = false); public void UnpauseEverywhere(); Parameters owner The owner Transform forcePause If the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be paused even if it is set to "Ignore Local Pause" ### [hashtag](https://sonity.gitbook.io/docs/soundpicker/soundpicker-functions#get-state) Get State Copy // If playing it returns SoundEventState.Playing // If paused either locally or globally it returns SoundEventState.Paused // If not playing, but it is delayed it returns SoundEventState.Delayed // If not playing and it is not delayed it returns SoundEventState.NotPlaying // If the SoundEvent or Transform is null it returns SoundEventState.NotPlaying public SoundEventState GetSoundEventState(Transform owner); Parameters owner The owner Transform ### [hashtag](https://sonity.gitbook.io/docs/soundpicker/soundpicker-functions#load-or-unload-audio-data) Load or Unload Audio Data Copy // Loads the audio data of any AudioClips assigned to the SoundContainers of the SoundEvent public void LoadAudioData(); // Unloads the audio data of any AudioClips assigned to the SoundContainers of the SoundEvent public void UnloadAudioData(); [PreviousSoundPickerchevron-left](https://sonity.gitbook.io/docs/soundpicker) [NextSoundVolumeGroupchevron-right](https://sonity.gitbook.io/docs/soundvolumegroup) Last updated 1 month ago --- # Templates & Examples | Sonity Docs Sonity contains examples and script templates of advanced functionality which you can use in your game. #### [hashtag](https://sonity.gitbook.io/docs/sonity/templates-and-examples#example_audiomixer.mixer) Example\_AudioMixer.mixer Is an example AudioMixer with groups such as Example\_AMB, Example\_MUS, Example\_SFX, Example\_UI and Example\_VO. #### [hashtag](https://sonity.gitbook.io/docs/sonity/templates-and-examples#templatesoundmusicmanager.cs) TemplateSoundMusicManager.cs Template of a singleton music playback system. Add to a GameObject in the scene and use like this: Copy SonityTemplate.TemplateSoundMusicManager.Instance.PlayMainMenu(); #### [hashtag](https://sonity.gitbook.io/docs/sonity/templates-and-examples#templatesoundplayui.cs) TemplateSoundPlayUI.cs Template of a singleton used to play e.g. UI sounds. Useful when you want to play [SoundEvents](https://sonity.gitbook.io/docs/soundevent) in a lot of places through code. Add to a GameObject in the scene and use like this: Copy SonityTemplate.TemplateSoundPlayUI.Instance.PlayButtonClick(); #### [hashtag](https://sonity.gitbook.io/docs/sonity/templates-and-examples#templatesoundvolumemanager.cs) TemplateSoundVolumeManager.cs Template of a singleton AudioMixer volume controller. The default settings work with the provided "Example\_AudioMixer.mixer". Add to a GameObject in the scene and use like this: Copy SonityTemplate.TemplateSoundVolumeManager.Instance.SetVolumeMaster(1f); [PreviousCreate Assets From Selectionchevron-left](https://sonity.gitbook.io/docs/sonity/create-assets-from-selection) [NextFAQchevron-right](https://sonity.gitbook.io/docs/sonity/faq) Last updated 1 month ago --- # Changelog | Sonity Docs #### [hashtag](https://sonity.gitbook.io/docs/sonity/changelog#id-1.1.1-2d-3d-info-and-fixes-2025-september) **1.1.1 - 2D/3D Info & Fixes (2025 September)** Please remove the whole Sonity folder before upgrading. New Feature: Added 3D/2D sound info for the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) and [SoundEvents](https://sonity.gitbook.io/docs/soundevent) for better overview. New Feature: Added SoundContainer Distance Scale info and batch replace when multiple objects are selected. New Feature: Added [SoundContainer preset](https://sonity.gitbook.io/docs/soundcontainer#presets) "UI" and and fixed so all Presets set Reverb Zone Mix. Legacy: [Support for renamed music & 2D functions](https://sonity.gitbook.io/docs/sonity/legacy-support) with "Tools/Sonity 🔊/Legacy/Add Scripting Define Symbol for Legacy Functions Music and 2D" Fix: If materials are pink, select all "ExampleMaterial" and upgrade to URP with Edit -> Rendering -> Materials -> Convert Selected Built-in Materials to URP. Fix: Fixed so [Log SoundEvents Owner](https://sonity.gitbook.io/docs/soundmanager#log-soundevents) will show the proper owner when Polyphony Mode Limited Globally is used. Fix: Fixed bug where steam audio sources werent force-updated, which made occlussion not work. Fix: Fixed [SoundEvent](https://sonity.gitbook.io/docs/soundevent) mute, solo and disable color transparency. Fix: [SoundPreset](https://sonity.gitbook.io/docs/soundpreset) when creating assets added SetDirty. Fix: Editor Sound Preview AudioListener fixed HideFlags. Fix: Added nullchecks to [SoundManager](https://sonity.gitbook.io/docs/soundmanager) Log and changed the default values. Fix: Changed so all asmdefs use GUIDs. Documentation: Added info about legacy support in documentation. #### [hashtag](https://sonity.gitbook.io/docs/sonity/changelog#id-1.1.0-steam-audio-and-playmaker-integration-2025-june) **1.1.0 - Steam Audio & PlayMaker Integration (2025 June)** Please remove the whole Sonity folder before upgrading. Rename: Renamed Play2D() to UIPlay() and PlayMusic() to MusicPlay() with the same pattern for all all other Music & 2D/UI functions. New Feature: Added integration for [Steam Audio](https://sonity.gitbook.io/docs/third-party-integrations/steam-audio-integration) , enabling features like occlussion, reflection and propagation. New Feature: Added integration for [PlayMaker](https://sonity.gitbook.io/docs/third-party-integrations/playmaker-integration) , adding actions to implement sounds using visual scripting. New Feature: Added [async startup](https://sonity.gitbook.io/docs/soundmanager#docs-internal-guid-dcaf7a58-7fff-9584-39bc-aabab3d35a26) , enabling quicker load times when using the addressable AudioMixer. New Feature: Added Example scene for [AudioListenerDistance Override](https://sonity.gitbook.io/docs/soundmanager#audiolistenerdistance-component) . Fix: Renamed "Adressable" to "Addressable" for eg SONITY\_ENABLE\_ADDRESSABLE\_AUDIOMIXER. Fix: Fixed bug where Music/UI Stop, Pause, Unpause wouldn't work if Limited Globally polyphony was used. Fix: Fixed bug where WebGL build could give the error "An invalid seek position was passed to this function". Fix: Fixed so when [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) are added, removed or changed in the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) at runtime it will update live in the editor. Fix: Fixed bug where StopEverything, StopAllAtOwner, StopAtPosition might give an error. Fix: Fixed bug where virtualized loops random start position wouldn't be randomized. Fix: Fixed bug where volume increase settings mismatch would make the sound preview not work properly. Fix: Fixed bug where play on [Trigger On Stop](https://sonity.gitbook.io/docs/soundevent#trigger-on-stop) in combination with StopAllAtOwner might cause errors. Fix: Fixed bug where SoundEventCopy would copy the wrong volumeRatio value. Fix: Fixed so Enable Volume Increase volume is set on awake. Fix: Fixed so [SoundTrigger](https://sonity.gitbook.io/docs/soundtrigger) initialises when it is triggered. Fix: Polished the [TemplateSoundVolumeManager](https://sonity.gitbook.io/docs/sonity/templates-and-examples#templatesoundvolumemanager.cs) . Fix: Fixed the [SoundPreset](https://sonity.gitbook.io/docs/soundpreset) default settings. Fix: Fixed bug where GetAngleToAudioListener would throw warnings. Fix: Fixed so that the AudioListener is reset in edit mode when previewing sounds. Fix: Changed so GetLastPlayedClipLength returns Mathf.Infinity when its null (returning 0 caused problems when TriggerOnTail and delay was combined). #### [hashtag](https://sonity.gitbook.io/docs/sonity/changelog#id-1.0.6-the-big-volume-and-debug-update-2024-november) **1.0.6 - The Big Volume & Debug Update (2024 November)** Please remove the whole Sonity folder before upgrading because scripts were moved. Support: Added support for Unity 6 (velocity replaced with linearVelocity). New Feature: [Added support to increase the volume](https://sonity.gitbook.io/docs/soundmanager#settings) of [SoundEvents](https://sonity.gitbook.io/docs/soundevent) and [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) by +24 dB each and [SoundVolumeGroups](https://sonity.gitbook.io/docs/soundvolumegroup) by +12 dB. New Feature: Added [SoundEvent Base Volume & Polyphony settings](https://sonity.gitbook.io/docs/soundevent#base) (convert old to new with "Tools/Sonity 🔊/Convert SoundEvent Modifier Volume and Polyphony to Base"). New Feature: Added [SoundVolumeGroup](https://sonity.gitbook.io/docs/soundvolumegroup) objects for linked [SoundEvent](https://sonity.gitbook.io/docs/soundevent) volume control. New Feature: Added [SoundManager Debug Log SoundEvents to console](https://sonity.gitbook.io/docs/soundmanager#log-soundevents) . New Feature: Added [debug settings per SoundEvent](https://sonity.gitbook.io/docs/soundevent#debug) for e.g. hiding or changing color of debug drawing and logging. New Feature: Added [new editor tools "Selection History", "Reference Finder" and "Select Same Type"](https://sonity.gitbook.io/docs/soundmanager/editor-tools) . New Feature: Added [SoundContainer setting "HRTF Spatialize"](https://sonity.gitbook.io/docs/soundcontainer#advanced-settings) for external spatializer plugin support. New Feature: Added fields for the [AudioListener and the AudioListenerDistance for easy debugging](https://sonity.gitbook.io/docs/soundmanager#debug) . New Feature: Added support for having the [AudioMixer as an addressable asset in the SoundManager](https://sonity.gitbook.io/docs/soundmanager#docs-internal-guid-dcaf7a58-7fff-9584-39bc-aabab3d35a26) . New Feature: Added "Note" fields for all scripable objects. New Feature: Added addressable support for scriptable object asset comparison by adding custom GUIDs to all scriptable objects. New Feature: Added SoundEvent.GetContainsLoop(). New Feature: Added SoundEvent.GetLastPlayedAudioSource(). New Feature: Added [SoundManager Debug Draw SoundEvents](https://sonity.gitbook.io/docs/soundmanager#draw-soundevents) added "Hide Closer Than" in game view setting. Documentation: Added links in the documentation changelog. Fix: Removed AudioMixerGroup from the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) . Convert with: "Tools/Sonity 🔊/Legacy/Apply SoundContainer AudioMixerGroup to [SoundEvent](https://sonity.gitbook.io/docs/soundevent) if None". Fix: Fixed so preview uses Global Volume. Fix: Fixed bug where [SoundPreset](https://sonity.gitbook.io/docs/soundpreset) [SoundEvent](https://sonity.gitbook.io/docs/soundevent) creation would return null [SoundTag](https://sonity.gitbook.io/docs/soundtag) . Fix: Removed ducking limiter from AudioMixer example because it sometimes seemed to make audio silent when lots of things were playing. Fix: Better find AudioListener & AudioListenerDistance where disabled objects doesnt count. Fix: Fixed problem where sound would be stopped when RunInBackground is disabled and not restart when Unity regains focus. Fix: Removed debug of missing [SoundManager](https://sonity.gitbook.io/docs/soundmanager) when application is quitting. Fix: Added checks and info that the [SoundPicker](https://sonity.gitbook.io/docs/soundpicker) is not nestable in an array or custom class because it is built upon CustomPropertyDrawer. Fix: Cleaned up [SoundMix](https://sonity.gitbook.io/docs/soundmix) functions. Fix: Fixed the icons for the scriptable object with new higher resolution versions and better import settings. Fix: Replaced deprecated FindObjectOfType and FindObjectsOfType with newer versions when supported. Fix: Fixed example scenes Unity downgrade bug where BoxCollider sizes were set to size 2. Documentation: Fixed info about [SoundMix](https://sonity.gitbook.io/docs/soundmix) and AudioMixerGroup. Change: Made Advanced subcategory for Settings in [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) , [SoundEvents](https://sonity.gitbook.io/docs/soundevent) and the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . Change: Removed the create [SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) for SE shortcuts. Change: Fixed the default [SoundManager](https://sonity.gitbook.io/docs/soundmanager) Instance Statistics settings. Change: Increased the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) "ReverbZoneMix Distance Increase" from 0.1 to 0.5. #### [hashtag](https://sonity.gitbook.io/docs/sonity/changelog#id-1.0.5.1-fixes-2024-may) **1.0.5.1 - Fixes (2024 May)** Fix: Fixed bug where AudioListener wasn't checked if it was disabled properly. Fix: Fixed bug where SoundPreset copied [SoundEvent](https://sonity.gitbook.io/docs/soundevent) modifiers and [SoundEvent](https://sonity.gitbook.io/docs/soundevent) [SoundTag](https://sonity.gitbook.io/docs/soundtag) settings by reference instead of by value. #### [hashtag](https://sonity.gitbook.io/docs/sonity/changelog#id-1.0.5-soundphysics-update-2023-december) **1.0.5 - SoundPhysics Update (2023 December)** New Tutorial: [SoundPhysics & Intensity Tutorialarrow-up-right](https://youtu.be/ehnwL678N4E) New Feature: Support for addressables (deleting [SoundEvents](https://sonity.gitbook.io/docs/soundevent) in runtime). New Feature: [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) is expanded with support for Is Trigger and exit sounds. New Feature: New [SoundPhysicsConditions](https://sonity.gitbook.io/docs/soundphysics) object for advanced reusable conditions and terrain layer support. New Feature: Added a [SoundPreset](https://sonity.gitbook.io/docs/soundpreset) object enabling custom presets for [SoundEvents](https://sonity.gitbook.io/docs/soundevent) and [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) . New Feature: Added Pause/Unpause functions e.g. Pause/Unpause AllAtOwner, Everywhere, Everything, 2D, All2D, Music, AllMusic. New Feature: Added [SoundManager](https://sonity.gitbook.io/docs/soundmanager) functions and settings Global Pause and Global Volume. New Feature: Added [SoundManager](https://sonity.gitbook.io/docs/soundmanager) setting for Sound Time Scale and default is changed from RealtimeSinceStartup to UnscaledTime. New Feature: Added [SoundEvent](https://sonity.gitbook.io/docs/soundevent) settings Ignore Local Pause and Ignore Global Pause. New Feature: Added GetMusic and Get2D functions like e.g. GetMusicSoundEventState(). New Feature: Better UnityEvent support by adding [SoundEvent](https://sonity.gitbook.io/docs/soundevent) functions with less parameters like StopAllowFadeOut and StopImmediate etc. Deprication: [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) is reworked with arrays of SoundEvents, automatic conversion system is added in the editor. Deprication: [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) is reworked to use object references so old tags must be remade. Documentation how to: Added How To - Optimize AudioClip Settings. Documentation how to: Added How To - Rename A Lot of Assets. Documentation how to: Added How To - Debug Sounds and Performance. Documentation: Documented [SoundTrigger](https://sonity.gitbook.io/docs/soundtrigger) and [SoundPicker](https://sonity.gitbook.io/docs/soundpicker) functions. Documentation: Updated info on AudioMixerGroup performance tips. Documentation: Added video tutorial links. Change: SoundPhysics is split for performance reasons into SoundPhysics, SoundPhysics2D, SoundPhysicsNoFriction, SoundPhysics2DNoFriciton. Change: Renamed [SoundTrigger](https://sonity.gitbook.io/docs/soundtrigger) enum StopNoFadeOut to StopImmediate. Change: Renamed StopAllAt2D() to StopAll2D(). Change: Renamed tools and create assets to "Sonity 🔊". Change: Renamed GetLastPlayedClipTime() to GetLastPlayedClipTimeSeconds. Addition: Added GetLastPlayedClipTimeRatio(). Addition: Added SoundTrigger Actions: Pause, Pause Forced, Unpause. Addition: Added SoundEventState.Paused. Addition: Added [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) example scenes including friction, exit, Trigger On etc. Addition: Added Intensity Scale Add and Scale Multiplier and Scale Max to 1 button. Addition: Added Intensity Debug Zoom for easier visual debugging. Addition: Added Tools "Set Selected Assets as Dirty (Force Reserialize for Resave)". Addition: Expanded Example\_AudioMixerWithLimiter with AMB, MUS, SFX, UI, VO. Fix: [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) distance scale is hidden when distance is disabled. Fix: Increased the contrast of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) and [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) icons. Fix: Fixed so automatic crossfades work with sound names ending with "loop". Fix: Fixed [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) continuous threshold stopping sounds and restarting loops. Fix: Fixed problem where [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) friction didnt work as expected. Fix: Fixed bug where [SoundParameters](https://sonity.gitbook.io/docs/soundparameter) weren't nullchecked. Fix: Fixed so [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) volume can be increased when multiple objects are selected and volume is at -0 dB. Fix: Optimized [SoundEvent](https://sonity.gitbook.io/docs/soundevent) recorded intensity drawing. Fix: Replaced all ToLower with ToLowerInvariant for greater language support. Fix: Fixed bug with create assets filename extension. Fix: Fixed nullcheck in [SoundPicker](https://sonity.gitbook.io/docs/soundpicker) for SoundManager.Instance. Legacy support: Fixed Unity 2018 compability by fixing: asmdef to non guid mode, SubsystemRegistration, GetContact.impulse, editor enum and header names. #### [hashtag](https://sonity.gitbook.io/docs/sonity/changelog#id-1.0.4-free-trial-release-2023-june) **1.0.4 - Free Trial Release (2023 June)** New Feature: Free trial version released. Fix: Fixed bug where audio positions were based on the previous frame. Fix: Fixed bug where disabled [SoundEvents](https://sonity.gitbook.io/docs/soundevent) played in builds. Fix: Fixed scripts for free trial version. #### [hashtag](https://sonity.gitbook.io/docs/sonity/changelog#id-1.0.3-support-for-disabling-domain-reloading-2023-june) **1.0.3 - Support for Disabling Domain Reloading (2023 June)** New Feature: Support for disabling domain reloading in the “enter play mode options”. New Feature: [Override Listener Distance with the AudioListenerDistance component](https://sonity.gitbook.io/docs/soundmanager) . Fix: Parented all Sonity scene objects created in runtime under the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . Fix: Improved documentation on how to bind shortcuts. Fix: Fixed SoundTriggerCustomEditor example code. Fix: Fixed preview TriggerOnTail tail length 0 bug. #### [hashtag](https://sonity.gitbook.io/docs/sonity/changelog#id-1.0.2.1-hotfix-2023-may) **1.0.2.1 - Hotfix (2023 May)** Hotfix: Fixed error in SoundContainer settings editor. #### [hashtag](https://sonity.gitbook.io/docs/sonity/changelog#id-1.0.2-mixed-fixes-2023-may) **1.0.2 - Mixed Fixes (2023 May)** New Feature: [Pass Parameter setting in the SoundEvent](https://sonity.gitbook.io/docs/soundevent#settings) for passing [SoundParameters](https://sonity.gitbook.io/docs/soundparameter) to sub [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . New Feature: Added GetSpectrumData() to get the spectrum data from AudioSources. Support: Added support for using multiple disabled AudioListeners. Support: Added support for [SoundTrigger](https://sonity.gitbook.io/docs/soundtrigger) Custom Override and added examples in the documentation. Support: Fixed support in examples and the timeline for the new Input System Package. Fix: Fixed bug where [SoundEvents](https://sonity.gitbook.io/docs/soundevent) with global polyphony couldn't be stopped. Fix: Fixed nullcheck in [SoundPicker](https://sonity.gitbook.io/docs/soundpicker) for SoundManager.Instance. Fix: The [SoundManager](https://sonity.gitbook.io/docs/soundmanager) and sub objects are now moved to Vector3.zero at start. Fix: [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) removed collider requirement warning. Fix: Preparing code for trial .dll version. Fix: Fixed Find Assets OrderBy bug. Example: Added example scene showcasing [SoundPicker](https://sonity.gitbook.io/docs/soundpicker) . Documentation: Added tips and info about "Unity Native Audio Support" in documentation. Documentation: [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) added info about rigidbody requirements. Documentation: Updated asmdef info in documentation. Documentation: Fixed documentation [SoundParameter](https://sonity.gitbook.io/docs/soundparameter) incorrect example code. Documentation: Fixed DontDestroyOnLoad tooltip. Documentation: Fixed [Modifier](https://sonity.gitbook.io/docs/modifiers) tooltips. Documentation: Fixed [SoundParameterIntensity](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) summary. Documentation: Fixed Play2D summary. #### [hashtag](https://sonity.gitbook.io/docs/sonity/changelog#id-1.0.1-gun-tutorial-2022-november) **1.0.1 - Gun Tutorial (2022 November)** New Feature: [Automatic asset creator](https://sonity.gitbook.io/docs/sonity/create-assets-from-selection) finds common denominator name. New Feature: [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) presets added set automatic looping and automatic crossfades. Example: Added new examples used in the new gun tutorials. Documentation: Updated documentation. Documentation: Minor spelling corrections of tooltips and documentation. Change: Changed so timeline zooms when holding down control and scrolling with mousewheel. Change: Changed so [SoundEvent](https://sonity.gitbook.io/docs/soundevent) [SoundTag](https://sonity.gitbook.io/docs/soundtag) always use modifiers. Change: Trigger On Tail default length changed to 0. Change: Trigger On Tail added warning if length is less than shortest AudioClip. Fix: Fixed bug with serialized cache bools. Fix: Fixed bug with [SoundTag](https://sonity.gitbook.io/docs/soundtag) position. Fix: Fixed bug with preview [SoundEvent](https://sonity.gitbook.io/docs/soundevent) distance scale. Fix: Fixed so debug logs only print in developent builds and the editor. Fix: Fixed nullcheck for camera in "Draw SoundEvents in Game View". Fix: [SoundEvent](https://sonity.gitbook.io/docs/soundevent) and [SoundManager](https://sonity.gitbook.io/docs/soundmanager) GetMaxLength removed forceUpdate. Fix: All helpboxes now respect GUI Warnings setting. Fix: Optimized [SoundManager](https://sonity.gitbook.io/docs/soundmanager) update. Fix: Cleared SoundEventInstanceDictionaryValue.cs Fix: Changed template scripts to useDontDestroyOnLoad to public. #### [hashtag](https://sonity.gitbook.io/docs/sonity/changelog#id-1.0.0-first-release-2022-october) **1.0.0 - First Release (2022 October)** Release. [PreviousLegacy Supportchevron-left](https://sonity.gitbook.io/docs/sonity/legacy-support) [NextHow To Guideschevron-right](https://sonity.gitbook.io/docs/how-to-guides) Last updated 1 month ago --- # FAQ | Sonity Docs ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#docs-internal-guid-00427613-7fff-fd2c-a924-b1f2f2da0d44) Support and Contact If you need support you can join the Sonity discord server and ask me for help or send me an email. You can also contact me if you need a special license or have questions about licencing. Discord - [https://sonigon.com/sonity-discord/arrow-up-right](https://sonigon.com/sonity-discord/) Email - [victor@sonigon.comenvelope](mailto:victor@sonigon.com) ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#supported-versions) Supported Versions Sonity is fully supported and tested on Unity 6, 2022, 2021, 2020, 2019 with IL2CPP. Unity 2018.3.0 or newer: Everything works except “Debug SoundEvents Live (In Scene View)” and Terrain example. Minor GUI tweaks for compatibility. The asset store “supported version” field is bugged which I’ve reported to Unity. ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#webgl) WebGL Everything in Sonity works except DSP (distortion/lowpass/highpass). ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#free-trial-version) Free Trial Version There is now a free trial version! [https://assetstore.unity.com/packages/tools/audio/sonity-audio-middleware-free-trial-244369arrow-up-right](https://assetstore.unity.com/packages/tools/audio/sonity-audio-middleware-free-trial-244369) It supports all features except those which use script define symbols (because .dll's don't support conditional compilation). ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#sales-deals-discounts) Sales / Deals / Discounts I can't choose when Sonity on the Unity Assetstore has a sale, I can only accept when they email me if I want to join a certain sale period. This is the type of of emails which are sent to me with discount offers: ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FYqwQ3b2dwVXMrwVRiEtN%252FScreenshot%25202025-12-11%2520123030.png%3Falt%3Dmedia%26token%3Dbf8c9af0-eb56-45bd-b87c-a743c1531f5a&width=768&dpr=3&quality=100&sign=8f70070&sv=2) ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#eula-licencing-and-seats) EULA, Licencing and Seats Sonity uses the standard [Unity Asset Store EULAarrow-up-right](https://unity.com/legal/as-terms) . Contact me if you need a special license or have questions about licencing. Email - [victor@sonigon.comenvelope](mailto:victor@sonigon.com) **Unity EULA - Explanation about seats and licenses** * Everyone working on the project need their own license, including contractors. * The Sonity Unity Asset Store license is for a single user at a time. * If multiple people use Sonity, you need multiple licenses. **Unity** [**EULA**arrow-up-right](https://unity.com/legal/as-terms) **- Section 2.3.2 and 2.3.4:** “END-USER is granted a single seat license to install and use” “a person must have its own license to the Asset” “For example, a person who is a Contractor must have a seat license \[...\], and the person who is hirer of the Contractor must have a seat license” From 2025-01-10 ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#compatibility-with-adressables) Compatibility with Adressables Sonity supports using adressables to add and delete [SoundEvents](https://sonity.gitbook.io/docs/soundevent) in realtime since version 1.0.5. ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#compatibility-with-vr-spatializer-plugins-unity-native-audio) Compatibility with VR, Spatializer Plugins, Unity Native Audio Sonity is built around the native audio system (AudioSources) in Unity, so everything that Unity audio supports Sonity also supports. You can of course replace the spatializers (HRTF libraries) with e.g. steam audio, resonance, oculus spatializer etc. These are some examples of compatible spatializers [(read more here)arrow-up-right](https://docs.unity3d.com/Manual/VRAudioSpatializer.html) * Steam Audio Spatializer * Oculus Spatializer Unity * Google Resonance Audio Spatializer * Vive 3DSP Audio SDK Spatializer * Microsoft Spatializer * Apple PHASE Spatializer * Qualcomm 3D Spatializer You need to enable HRTF Spatializer on the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) for this to work. ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#compatibility-with-in-game-voice-chats) Compatibility with In-Game Voice Chats Sonity is built around the native audio system (AudioSources) in Unity. So everything that Unity audio supports Sonity also supports. Sonity users have reported that Sonity works with: * Vivox Voice Chat * Dissonance Voice Chat ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#unity-audiosources-and-sonity) Unity AudioSources and Sonity You can run Unity AudioSources separately at the same time as Sonity. Basically Sonity uses Unity AudioSources in the background. circle-info Tip: You might want to increase the polyphony limit to allow for both Sonity and any other audio system to play at the same time. ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#disabling-domain-reloading) Disabling Domain Reloading Disabling domain reloading in the “enter play mode options” is supported since Sonity 1.0.3. ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#testimonies-from-users) Testimonies From Users **User on Sonity vs Fmod:** “I'm telling you, we had like 1 and a half days left of this gamejam and we couldn't get FMOD to work with GitHub, so my whole team got Sonity, knowing nothing about how it works or anything. And like after 1 hour I understood all the essential parts of Sonity and like no other Middleware has been able to do that for me atleast.” - Fyoum **User on ease of use:** “Yeah its honestly as simple as install Sonity, slap some audio files in Unity, right click and use the Sonity tools to generate the needed files. From there you can tweak and edit the audio and easily preview in editor. Engineering side is as simple as referencing the SoundEven file you generated above and calling Play(transform) on it. I'm not an audio person (Technical Artist) and I found it very easy to pickup. From my tech art background and tool experience, I'm impressed with the time the Sonity devs put in to streamline the import and setup process. I really appreciate that they put in the extra work to make the editor side easy and quick to use.” - Dangledorf ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#pros-vs-master-audio) Pros vs Master Audio **Thoughts on Sonity vs Master Audio by Pablo:** Sonity has a more intuitive and easy to use UI based on scriptable object assets instead of having everything as prefabs as Master Audio does. This makes it a lot easier to work with because you can multi-edit everything and all changes are automatically saved instead of you having to apply the prefab. Other Sonity exclusive features: * Quickly add/update variations. No need for adding child objects for every variation as you do in Master Audio. * Change fade in/out length easily with SoundModifiers. * A SoundTrigger component which lets you play sounds easily without having to code. * SoundPolyGroups which can help you to limit the polyphony in demanding applications, e.g. all bullet impacts can share one group of polyphony and use less voices. * Automatic asset creation enables you to quickly create and set up thousands of assets in minutes. * DSP (distortion/filters) per voice enables for a more natural sound where sounds can e.g. be filtered based on distance. **Thoughts on Sonity vs Master Audio by Baloneysandwich:** As a user of Master Audio for many years, it filled a gap in Unity's audio system well. I appreciate the work they have put in. However, 30 minutes into the new Trial that u/vengstrom put together, I can say that Sonity is worth a look and likely is superior. The scriptable object workflow alone sets it apart. You don't ever have to make another string literal reference in code. :) Mostly though you can tell that the author has done a lot of games and wanted to solve the issue where FMOD/WWise don't let you be quite close enough to the game in the Unity editor. For creators who like to iterate tightly on audio and code and gamefeel, the external tooling of the big packages can be a drag. I'm looking forward to spending more time with Sonity and anticipate I'll be switching a couple of my in-progress games to it. ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#pros-vs-unitys-built-in-audio-system) Pros vs Unity’s Built in Audio System Unity’s built in audio system is very bare-bones. You have to take care of everything, like e.g. making sound objects, then a good editor for them, pooling, whereas Sonity has a lot of built in functionality which will save you a lot of time! **Features of Sonity which Unity doesn't:** * Random audioclips * Random pitch/volume * Easily layer sounds * Automatic sound pooling * Easily live and multi-edit the sounds while the game is playing * Custom low/highpass filters and distortion per sound * Object based assets ([SoundEvents](https://sonity.gitbook.io/docs/soundevent) ) instead of having to create your own data structure * Support for adressables with the adressable AudioMixer * Control your sounds with [SoundParameters](https://sonity.gitbook.io/docs/soundparameter/soundparameterintensity) in realtime * [Automatically create your assets for you](https://sonity.gitbook.io/docs/sonity/create-assets-from-selection) * [Visually debug sounds ingame](https://sonity.gitbook.io/docs/soundmanager#draw-soundevents) * Built in music functionality like playlists, stems and intros * Compontens for playing sounds without coding, eg: [SoundTrigger](https://sonity.gitbook.io/docs/soundtrigger) & [SoundPhysics](https://sonity.gitbook.io/docs/soundphysics) * Support for increasing the volume of your sounds above +0dB ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#pros-vs-fmod) Pros vs Fmod This is based on my experience of using Fmod over many years. **Integration:** Sonity is more tightly integrated into Unity with an in engine editor and helper objects. Non-sound parts of the team (like design) can easily set up new sounds themselves without needing to learn Fmod. **Platform support:** Because Sonity is written in C# it works natively across all platforms which Unity supports. **Source code:** The source code is included in the software so if there is any problem with a new Unity release and I haven’t had time to fix it you can quickly solve the problem yourself. **Version control:** You don’t need to have multiple separate repos as you do for Fmod, everything is self contained in Unity. **Banks:** You never have to build banks from your Fmod project into Unity and sync them. All Sonity sound assets are right there in your project, no banks required. **Price:** Pay only once per seat instead of per release/platform as you have to do with Fmod. **Unique features:** Features unique to Sonity which don’t exist in Fmod: * Automatic asset creation. * Being able to multi-edit everything. * Debugging sounds live graphically can be very helpful and recording parameters. **More clean and easier to use code** In Sonity you'd write this to play a sound with it automatically taking care of instancing/pooling/releasing/positioning Copy footstep.Play(transform); Whereas playing a sound in Fmod is quite convoluted and easier to mess up. This is equivalent Fmod code: Copy footstep = FMODUnity.RuntimeManager.CreateInstance("event:/Footstep"); footstep.set3DAttributes(FMODUnity.RuntimeUtils.To3DAttributes(gameObject)); footstep.start(); footstep.release(); **Polyphony** In Sonity, polyphony can be limited per owner. Fmod has no such options. This is a problem for optimization and voice stealing in demanding high performance situations. **Randomization** Sonity has a better pseudo random feature, where it globally remembers more of the previously played AudioClips for less repetitive sounding playback. **Voice Stealing in Sonity** In Sonity if polyphony is full and you want to play a new sound, it will play the new sound and stop the sound with the lowest volume. Which is perfect because it always makes a new sound play instead of skipping it. **Voice Stealing in Fmod** Fmod doesn’t have a voice stealing mode which plays new sounds and steals the lowest volume one. For example in Fmod using stealing mode “Quietest”, if you play sounds which trigger progressively in a line from the AudioListener outwards, then Fmod will only play the closest (loudest) ones and not steal the quietest one to play the new one. Then you’ll have to use stealing mode “Oldest” in Fmod, but that is not very good because it only steals the oldest one disregarding volume/distance. Which can be a problem if you have quiet sounds happening far away and they steal all the older but louder instances closer to the AudioListener. So in Fmod there is no good solution which solves all voice stealing problems. ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#pros-vs-fabric-2) Pros vs Fabric 2 This is based on my experience of watching videos of fabric. The user interface of fabric is very barebones and looks very un-intuitive vs Sonity. Fabric uses gameobjects in the hierarchy instead of scriptable objects like the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) , which is worse for e.g. multi-editing/live editing/saving etc. ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#pros-vs-mmsoundmanager-in-feel-by-more-mountains) Pros vs MMSoundManager in Feel by More Mountains This is based on my experience of reading the documentation. The interface of the is very barebones and looks very un-intuitive vs Sonity. It only supports one layer/audiosource at a time so it's going to be difficult to work with multi layered sounds, both for preview and implementation. Volume is in ratio eg. 0-1 and not decibel, which makes it really hard to dial in the correct volume. Pitch is the same, it's not based on semitones and is also really difficult to work with. Both volume and pitch are also min/max values and not base values with an added random offset . So if you’d want to eg. lower the volume you’d have to change both values and then recalculate and type in the random range yourself. There are no distance envelopes for spatial spread, and no control at all over spatial blend, which I really think makes audio sounds better. ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#console-eg.-xbox-and-playstation-support) Console eg. Xbox and Playstation support Sonity is built upon Unity native audio eg. AudioSources and AudioMixerGroups. So everything that Unity supports, Sonity also supports. The only limitation with audio for consoles is that you can only have 1 audio backend. You can't use both Unity audio and Fmod/Wwise etc in the same project. Though you can use both Sonity and separate AudioSources because they're the same backend. ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#surround-5.1-7.1-support) Surround 5.1, 7.1 support Sonity uses Unity’s sound system (AudioSources), so it has the same multi-channel output capabilities as Unity's internal system. All spatialized sounds will get output to their respective channels automatically if you have set up the “AudioSettings SpeakerMode” correctly. E.g. a spatialized sound playing behind the audio listener to the left will output to the rear left speaker in a 5.1 surround setup. For non-spatialized sounds (like ambiences), if you input multi-channel files it will output multi-channel into their respective channels for the audio output automatically. E.g. a 6 channel ambience sound in a 5.1 setup will output to; front left, front right, center, rear left, rear right, LFE (subwoofer) respectively. ### [hashtag](https://sonity.gitbook.io/docs/sonity/faq#press-kit-and-high-resolution-logos) Press Kit and High Resolution Logos Developer: Victor Engström. Located in Sweden Release Date: 2022 October 11 Start of Development: 2016 December 2 (~6 years) Website: [http://www.sonity.org/arrow-up-right](http://www.sonity.org/) Social: [https://sonigon.com/sonity-discord/arrow-up-right](https://sonigon.com/sonity-discord/) Logos: [Dropbox Linkarrow-up-right](https://www.dropbox.com/scl/fo/wwe9sn21gciopelp57j1h/AICV5eg03bg3IXGQpyErB7I?rlkey=dcz8iqdex2rzserhd51sh1ga7&dl=0) [PreviousTemplates & Exampleschevron-left](https://sonity.gitbook.io/docs/sonity/templates-and-examples) [NextUnity Native Audiochevron-right](https://sonity.gitbook.io/docs/sonity/unity-native-audio) Last updated 1 month ago --- # SoundVolumeGroup | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FiLfEs8FxEMwW59mClek4%2Fimage93.png&width=768&dpr=3&quality=100&sign=a324d4c3&sv=2) [SoundVolumeGroup](https://sonity.gitbook.io/docs/soundvolumegroup) objects are used for grouped live volume control of multiple [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . You can assign them in the [SoundEvent settings](https://sonity.gitbook.io/docs/soundevent#settings) . It is perfect for quickly mixing the volume of a large group of sounds. It also supports +12dB volume if you “[Enable Volume Increase](https://sonity.gitbook.io/docs/soundmanager#settings) ” in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . The volume is not meant to be changed at runtime in builds. If you want to control the volume in builds, take a look at the [TemplateSoundVolumeManager](https://sonity.gitbook.io/docs/sonity/templates-and-examples#templatesoundvolumemanager.cs) script. All [SoundVolumeGroup](https://sonity.gitbook.io/docs/soundvolumegroup) objects are multi-object editable. Example use: Add the same [SoundVolumeGroup](https://sonity.gitbook.io/docs/soundvolumegroup) to all e.g. gunshot [SoundEvents](https://sonity.gitbook.io/docs/soundevent) so you quickly can change their volumes. ### [hashtag](https://sonity.gitbook.io/docs/soundvolumegroup#asset-guid) Asset GUID The ID of an asset is cached in the editor because in some cases when using addressables a single scriptable object might be instantiated multiple times. This might lead to problems where a simple "Object == Object" check will return false, but a "ID == ID" will return true. If you are upgrading Sonity and use addressable assets you probably want to select all Sonity scriptable objects and run: "Tools/Sonity 🔊/Set Selected Assets as Dirty (Force Reserialize for Resave)" which will force the assets to cache the GUIDs. You can search t:[SoundEvent](https://sonity.gitbook.io/docs/soundevent) , t:[SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) , t:[SoundTag](https://sonity.gitbook.io/docs/soundtag) , t:[SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) , t:[SoundDataGroup](https://sonity.gitbook.io/docs/sounddatagroup) , t:[SoundMix](https://sonity.gitbook.io/docs/soundmix) , t:[SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics) to find all objects. If no GUID is cached then it will use the InstanceID in builds. The free trial version doesn't have full functionality. [PreviousSoundPicker Functionschevron-left](https://sonity.gitbook.io/docs/soundpicker/soundpicker-functions) [NextSoundMixchevron-right](https://sonity.gitbook.io/docs/soundmix) Last updated 1 month ago --- # SoundMix | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2Fq720iEFWhmQyXikFBzDa%2Fimage91.gif&width=768&dpr=3&quality=100&sign=cdf41d2&sv=2) [SoundMix](https://sonity.gitbook.io/docs/soundmix) objects are used for grouped control of e.g. volume or distance scale for multiple [SoundEvents](https://sonity.gitbook.io/docs/soundevent) at the same time. You can assign them in the [SoundEvent settings](https://sonity.gitbook.io/docs/soundevent#settings) . Because [SoundMix](https://sonity.gitbook.io/docs/soundmix) use [modifiers](https://sonity.gitbook.io/docs/modifiers) they only calculate the values once when the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) is started. If you want to have realtime volume control over sounds, use an AudioMixerGroup. To learn more, take a look at the [TemplateSoundVolumeManager](https://sonity.gitbook.io/docs/sonity/templates-and-examples#templatesoundvolumemanager.cs) script. All [SoundMix](https://sonity.gitbook.io/docs/soundmix) objects are multi-object editable. Example use: Set up a “Master\_MIX” and a “SFX\_MIX” where the Master\_MIX is a parent of the SFX\_MIX. **Notes** At the top of the [SoundMix](https://sonity.gitbook.io/docs/soundmix) there is a text field which you can fill with notes. **Modifiers** [Modifiers](https://sonity.gitbook.io/docs/modifiers) are used to control how [SoundEvents](https://sonity.gitbook.io/docs/soundevent) are played (e.g. volume, polyphony, fade in length etc). See [modifiers](https://sonity.gitbook.io/docs/modifiers) for more info. ### [hashtag](https://sonity.gitbook.io/docs/soundmix#asset-guid) Asset GUID The ID of an asset is cached in the editor because in some cases when using addressables a single scriptable object might be instantiated multiple times. This might lead to problems where a simple "Object == Object" check will return false, but a "ID == ID" will return true. If you are upgrading Sonity and use addressable assets you probably want to select all Sonity scriptable objects and run: "Tools/Sonity 🔊/Set Selected Assets as Dirty (Force Reserialize for Resave)" which will force the assets to cache the GUIDs. You can search t:[SoundEvent](https://sonity.gitbook.io/docs/soundevent) , t:[SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) , t:[SoundTag](https://sonity.gitbook.io/docs/soundtag) , t:[SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) , t:[SoundDataGroup](https://sonity.gitbook.io/docs/sounddatagroup) , t:[SoundMix](https://sonity.gitbook.io/docs/soundmix) , t:[SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics) to find all objects. If no GUID is cached then it will use the InstanceID in builds. The free trial version doesn't have full functionality. [PreviousSoundVolumeGroupchevron-left](https://sonity.gitbook.io/docs/soundvolumegroup) [NextSoundPolyGroupchevron-right](https://sonity.gitbook.io/docs/soundpolygroup) Last updated 1 month ago --- # SoundPolyGroup | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FD8mcgUccYrkCTMZRF1VX%2Fimage10.png&width=768&dpr=3&quality=100&sign=ba90be0&sv=2) [SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) objects are used to create a polyphony limit shared by multiple different [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . You can assign them in the [SoundEvent settings](https://sonity.gitbook.io/docs/soundevent#settings) . The priority for voice allocation is calculated by multiplying the priority set in the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) by the volume of the instance. A perfect use case would be to have a [SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) for all bullet impacts of all the different materials so that when combined, they don’t use too many voices. If you want simple individual polyphony control, use the polyphony modifier on the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . All [SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) objects are multi-object editable. **Notes** At the top of the [SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) there is a text field which you can fill with notes. **Polyphony Limit** The maximum number of [SoundEvents](https://sonity.gitbook.io/docs/soundevent) which can be played at the same time in this [SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) . ### [hashtag](https://sonity.gitbook.io/docs/soundpolygroup#asset-guid) Asset GUID The ID of an asset is cached in the editor because in some cases when using addressables a single scriptable object might be instantiated multiple times. This might lead to problems where a simple "Object == Object" check will return false, but a "ID == ID" will return true. If you are upgrading Sonity and use addressable assets you probably want to select all Sonity scriptable objects and run: "Tools/Sonity 🔊/Set Selected Assets as Dirty (Force Reserialize for Resave)" which will force the assets to cache the GUIDs. You can search t:[SoundEvent](https://sonity.gitbook.io/docs/soundevent) , t:[SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) , t:[SoundTag](https://sonity.gitbook.io/docs/soundtag) , t:[SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) , t:[SoundDataGroup](https://sonity.gitbook.io/docs/sounddatagroup) , t:[SoundMix](https://sonity.gitbook.io/docs/soundmix) , t:[SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics) to find all objects. If no GUID is cached then it will use the InstanceID in builds. The free trial version doesn't have full functionality. [PreviousSoundMixchevron-left](https://sonity.gitbook.io/docs/soundmix) [NextSoundTagchevron-right](https://sonity.gitbook.io/docs/soundtag) Last updated 1 month ago --- # SoundPreset | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FzwCzdq51eyzVUTKbpGQK%252FSoundPreset.png%3Falt%3Dmedia%26token%3Dcc6c9828-ce52-4bc5-81f7-8bc11c961997&width=768&dpr=3&quality=100&sign=7046e91d&sv=2) Use [SoundPreset](https://sonity.gitbook.io/docs/soundpreset) to apply settings to [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) and [SoundEvents](https://sonity.gitbook.io/docs/soundevent) automatically by matching the names of your assets. Its matched and applied when you [Create Assets From Selection](https://sonity.gitbook.io/docs/sonity/create-assets-from-selection) or manually from the [SoundContainer Presets](https://sonity.gitbook.io/docs/soundcontainer#presets) and the [SoundEvent Presets](https://sonity.gitbook.io/docs/soundevent#presets) toolbars. Example use: Name UI sounds to “UI\_” and use Is Prefix “UI\_” to automatically assign settings like disabling distance and setting Spatial Blend to 0. The settings are applied ordering from the one highest up and going downwards and can match an asset multiple times overwriting previous values. You can have multiple [SoundPreset](https://sonity.gitbook.io/docs/soundpreset) objects. **Notes** At the top of the [SoundPreset](https://sonity.gitbook.io/docs/soundpreset) there is a text field which you can fill with notes. **Example\_SoundPreset** If you want a starting point for your [SoundPreset](https://sonity.gitbook.io/docs/soundpreset) , look at the Example\_SoundPreset. Note: The [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) and [SoundEvents](https://sonity.gitbook.io/docs/soundevent) have volume -12dB so you can increase the volume later. You can compensate by increasing the volume in the AudioMixer. All the [SoundEvents](https://sonity.gitbook.io/docs/soundevent) are also assigned to a AudioMixerGroup in the Example\_AudioMixer. ### [hashtag](https://sonity.gitbook.io/docs/soundpreset#example-templates) **Example Templates** **Template Default (Matches to all to catch any stray sounds without prefix)** Default settings Outputs to SFX **Template AMB (2D Ambience)** Distance disabled Spatial Blend 0 **Template MUS (Music)** Distance disabled Spatial Blend 0 Never Steal Voice Never Steal Voice Effects Priority 1 **Template SFX (Sound Effects)** Default settings **Template UI (User Interface)** Distance disabled Spatial Blend 0 **Template VO (Voice/Dialogue)** Random Pitch disabled ### [hashtag](https://sonity.gitbook.io/docs/soundpreset#settings) Settings **Disable All** If disabled no settings from the [SoundPreset](https://sonity.gitbook.io/docs/soundpreset) will be applied automatically and not available in the preset menus. ### [hashtag](https://sonity.gitbook.io/docs/soundpreset#preset) Preset **Disable** If disabled this specific preset won’t be available. **Automatic Loop** If enabled and the [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) name contains “loop” then it will automatically enable “Loop”, “Follow Position”, “Stop if Transform is Null” and “Random Start Position”. This will be applied after all the other settings are copied. Is not applied if you manually select a preset from the [SoundContainer Presets](https://sonity.gitbook.io/docs/soundcontainer#presets) dropdown. **From SoundContainer** The [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) you want to copy the settings from. Copies everything except: * AudioClips **From SoundEvent** The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) you want to copy the settings from. Copies everything except: * SoundContainers * Timeline Settings * Intensity Scale Add/Multiplier * TriggerOn SoundEvents * SoundTag SoundEvents ### [hashtag](https://sonity.gitbook.io/docs/soundpreset#match) Match **Auto Match** If enabled then automatic matching will be used when you [Create Assets From Selection](https://sonity.gitbook.io/docs/sonity/create-assets-from-selection) and in the [SoundContainer Presets](https://sonity.gitbook.io/docs/soundcontainer#presets) and the [SoundEvent Presets](https://sonity.gitbook.io/docs/soundevent#presets) “Auto Match”. Disable if you just want presets to apply manually to your assets. Auto matching is not case sensitive. **Apply On All** If enabled the settings assigned will be applied to all assets on asset creation and “Auto Match”. Useful to combine with other settings with conditions added later in the chain to assign settings to assets which doesn’t match the names. **Is Prefix** If the prefix of an asset matches the strings, the settings will be applied. Example prefixes: “AMB”, “MUS”, “SFX”, “UI”, “VO”. **Is Not Prefix** If the prefix of an asset doesn’t match the strings, the settings will be applied. **Contains** If the name of an asset contains the strings, the settings will be applied. **Not Contains** If the name of an asset doesn’t contain the strings, the settings will be applied. [PreviousSoundTagchevron-left](https://sonity.gitbook.io/docs/soundtag) [NextSoundDataGroupchevron-right](https://sonity.gitbook.io/docs/sounddatagroup) Last updated 1 month ago --- # SoundDataGroup | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2Fi3T1H1ATAdxsQkg1lNtD%2Fimage85.gif&width=768&dpr=3&quality=100&sign=278c9f5d&sv=2) [SoundDataGroup](https://sonity.gitbook.io/docs/sounddatagroup) objects are used to easily load and unload the audio data of the [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . All [SoundDataGroup](https://sonity.gitbook.io/docs/sounddatagroup) objects are multi-object editable. **Notes** At the top of the [SoundDataGroup](https://sonity.gitbook.io/docs/sounddatagroup) there is a text field which you can fill with notes. **Child SoundDataGroups** Nesting [SoundDataGroups](https://sonity.gitbook.io/docs/sounddatagroup) makes it easy to load/unload all audio data or just parts of it. **SoundEvents** The [SoundEvent](https://sonity.gitbook.io/docs/soundevent) whoms audio data will be loaded or unloaded **Drop SoundEvents/Folders Here** Here you can drag and drop [SoundEvents](https://sonity.gitbook.io/docs/soundevent) or folders with [SoundEvents](https://sonity.gitbook.io/docs/soundevent) in them. ### [hashtag](https://sonity.gitbook.io/docs/sounddatagroup#functions-load-unload) Functions Load/Unload Copy // Loads the audio data for the AudioClips of the assigned SoundEvents. public void LoadAudioData(bool includeChildren); // Unloads the audio data for the AudioClips of the assigned SoundEvents. public void UnloadAudioData(bool includeChildren); Parameters includeChildren If to load/unload all the audio data of all the child SoundDataGroups also. ### [hashtag](https://sonity.gitbook.io/docs/sounddatagroup#asset-guid) Asset GUID The ID of an asset is cached in the editor because in some cases when using addressables a single scriptable object might be instantiated multiple times. This might lead to problems where a simple "Object == Object" check will return false, but a "ID == ID" will return true. If you are upgrading Sonity and use addressable assets you probably want to select all Sonity scriptable objects and run: "Tools/Sonity 🔊/Set Selected Assets as Dirty (Force Reserialize for Resave)" which will force the assets to cache the GUIDs. You can search t:[SoundEvent](https://sonity.gitbook.io/docs/soundevent) , t:[SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) , t:[SoundTag](https://sonity.gitbook.io/docs/soundtag) , t:[SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) , t:[SoundDataGroup](https://sonity.gitbook.io/docs/sounddatagroup) , t:[SoundMix](https://sonity.gitbook.io/docs/soundmix) , t:[SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics) to find all objects. If no GUID is cached then it will use the InstanceID in builds. The free trial version doesn't have full functionality. [PreviousSoundPresetchevron-left](https://sonity.gitbook.io/docs/soundpreset) Last updated 1 month ago --- # SoundTag | Sonity Docs ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FPyWMtKnpxGS9bUoLexX4%2Fimage40.png&width=768&dpr=3&quality=100&sign=c8693340&sv=2) [SoundTag](https://sonity.gitbook.io/docs/soundtag) objects are passed to modify how a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) should be played. You can assign them in the [SoundEvents SoundTag section](https://sonity.gitbook.io/docs/soundevent#soundtag) . You can either pass them when playing a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) for setting the local [SoundTag](https://sonity.gitbook.io/docs/soundtag) . Or you can set the global [SoundTag](https://sonity.gitbook.io/docs/soundtag) in the [SoundManager](https://sonity.gitbook.io/docs/soundmanager) . This is useful for e.g; weapon reverb zones. You can set the [SoundTag](https://sonity.gitbook.io/docs/soundtag) corresponding to the acoustic space which the listener is in. And when you play the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) , your gun reflection layers can correspond to the acoustic space. Used in a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) : ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252FPnUCsAlV0VjHvJYB3Tq0%252FSoundTag%2520Used%2520in%2520a%2520SoundEvent.png%3Falt%3Dmedia%26token%3D8f612e28-5da6-4370-8a05-39f31df4db62&width=768&dpr=3&quality=100&sign=79137d69&sv=2) **Notes** At the top of the [SoundTag](https://sonity.gitbook.io/docs/soundtag) there is a text field which you can fill with notes. ### [hashtag](https://sonity.gitbook.io/docs/soundtag#asset-guid) Asset GUID The ID of an asset is cached in the editor because in some cases when using addressables a single scriptable object might be instantiated multiple times. This might lead to problems where a simple "Object == Object" check will return false, but a "ID == ID" will return true. If you are upgrading Sonity and use addressable assets you probably want to select all Sonity scriptable objects and run: "Tools/Sonity 🔊/Set Selected Assets as Dirty (Force Reserialize for Resave)" which will force the assets to cache the GUIDs. You can search t:[SoundEvent](https://sonity.gitbook.io/docs/soundevent) , t:[SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) , t:[SoundTag](https://sonity.gitbook.io/docs/soundtag) , t:[SoundPolyGroup](https://sonity.gitbook.io/docs/soundpolygroup) , t:[SoundDataGroup](https://sonity.gitbook.io/docs/sounddatagroup) , t:[SoundMix](https://sonity.gitbook.io/docs/soundmix) , t:[SoundPhysicsCondition](https://sonity.gitbook.io/docs/soundphysics) to find all objects. If no GUID is cached then it will use the InstanceID in builds. The free trial version doesn't have full functionality. [PreviousSoundPolyGroupchevron-left](https://sonity.gitbook.io/docs/soundpolygroup) [NextSoundPresetchevron-right](https://sonity.gitbook.io/docs/soundpreset) Last updated 1 month ago --- # Getting Started | Sonity Docs ### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#video-tutorials) Video Tutorials A great way to get started is watching the tutorial videos. #### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#sonity-showcase) Sonity - Showcase [Link to videoarrow-up-right](https://www.youtube.com/watch?v=Ik56geuZ1iA&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=1) [0:00arrow-up-right](https://www.youtube.com/watch?v=Ik56geuZ1iA&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=1&t=0s) Intro [0:19arrow-up-right](https://www.youtube.com/watch?v=Ik56geuZ1iA&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=1&t=19s) Features [1:31arrow-up-right](https://www.youtube.com/watch?v=Ik56geuZ1iA&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=1&t=91s) Outro #### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#sonity-quickstart-tutorial) Sonity - Quickstart Tutorial [Link to videoarrow-up-right](https://www.youtube.com/watch?v=3gSttAnbg6Y&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3) [0:00arrow-up-right](https://www.youtube.com/watch?v=3gSttAnbg6Y&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=2) Intro [0:19arrow-up-right](https://www.youtube.com/watch?v=3gSttAnbg6Y&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=2&t=19s) Installation [0:49arrow-up-right](https://www.youtube.com/watch?v=3gSttAnbg6Y&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=2&t=49s) Asset Creation [1:41arrow-up-right](https://www.youtube.com/watch?v=3gSttAnbg6Y&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=2&t=101s) Asset Editing [2:53arrow-up-right](https://www.youtube.com/watch?v=3gSttAnbg6Y&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=2&t=173s) SoundTrigger Implementation [3:15arrow-up-right](https://www.youtube.com/watch?v=3gSttAnbg6Y&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=2&t=195s) C# Implementation [4:34arrow-up-right](https://www.youtube.com/watch?v=3gSttAnbg6Y&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=2&t=274s) Outro #### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#sonity-realistic-gun-sounds-tutorial) Sonity - Realistic Gun Sounds Tutorial [Link to videoarrow-up-right](https://www.youtube.com/watch?v=fCaEeRm9pRo&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3) [0:00arrow-up-right](https://www.youtube.com/watch?v=fCaEeRm9pRo&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3&t=0s) Intro [0:45arrow-up-right](https://www.youtube.com/watch?v=fCaEeRm9pRo&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3&t=45s) Distance Crossfades [3:22arrow-up-right](https://www.youtube.com/watch?v=fCaEeRm9pRo&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3&t=202s) Pistol Shot Editing [4:30arrow-up-right](https://www.youtube.com/watch?v=fCaEeRm9pRo&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3&t=270s) Adding SoundTags [5:44arrow-up-right](https://www.youtube.com/watch?v=fCaEeRm9pRo&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3&t=344s) Play Shot Sound in C# [6:42arrow-up-right](https://www.youtube.com/watch?v=fCaEeRm9pRo&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3&t=402s) Set Global SoundTags [8:07arrow-up-right](https://www.youtube.com/watch?v=fCaEeRm9pRo&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3&t=487s) Mixing Reflections [8:46arrow-up-right](https://www.youtube.com/watch?v=fCaEeRm9pRo&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3&t=526s) Using the Lowpass Filter [10:00arrow-up-right](https://www.youtube.com/watch?v=fCaEeRm9pRo&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3&t=600s) Using Distortion [10:41arrow-up-right](https://www.youtube.com/watch?v=fCaEeRm9pRo&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3&t=641s) Outro #### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#sonity-soundphysics-and-intensity-tutorial) Sonity - SoundPhysics & Intensity Tutorial [Link to videoarrow-up-right](https://www.youtube.com/watch?v=ehnwL678N4E&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3) [0:00arrow-up-right](https://www.youtube.com/watch?v=ehnwL678N4E&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=3&t=0s) Introduction [1:45arrow-up-right](https://youtu.be/ehnwL678N4E?feature=shared&t=106s) SoundPhysics Basic: Impact and Intensity, Crossfading velocity layers [9:55arrow-up-right](https://www.youtube.com/watch?v=ehnwL678N4E&t=596s) SoundPhysics Intermediate: Friction, Exit and OnTrigger [16:56arrow-up-right](https://www.youtube.com/watch?v=ehnwL678N4E&t=1016s) SoundPhysics Advanced A: Using SoundPhysicsConditions [21:52arrow-up-right](https://www.youtube.com/watch?v=ehnwL678N4E&t=1312s) SoundPhysics Advanced B: Using SoundTags [32:09arrow-up-right](https://youtu.be/ehnwL678N4E?feature=shared&t=1929s) Outro #### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#sonity-1.0.6-the-big-volume-and-debug-update) Sonity 1.0.6 - The Big Volume & Debug Update [Link to videoarrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=1) [0:15arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=15s) Introduction [0:29arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=29s) SoundEvent Base Settings [1:02arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=62s) AudioMixerGroup Legacy Conversion [1:34arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=94s) Enable Volume Increase [3:41arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=221s) Log SoundEvents [4:16arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=256s) SoundEvents Debug Settings [4:44arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=284s) Editor Tools [5:21arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=321s) Editor Tools - Reference Finder [5:34arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=334s) Editor Tools - Select Same Type [5:54arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=354s) Editor Tools - Selection History [6:29arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=389s) Notes Fields [6:49arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=409s) SoundPresets [8:44arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=524s) AudioListenerDistance [10:37arrow-up-right](https://www.youtube.com/watch?v=SX4dQFX-5Yw&t=637s) Outro #### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#sonity-1.1.1-steam-audio-playmaker--tips-and-tricks) Sonity 1.1.1 - Steam Audio, PlayMaker + tips & tricks [Link to videoarrow-up-right](https://www.youtube.com/watch?v=jl0hOuqpZEU&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=1) [0:08arrow-up-right](https://www.youtube.com/watch?v=jl0hOuqpZEU&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=1&t=8s) Whats New [0:25arrow-up-right](https://www.youtube.com/watch?v=jl0hOuqpZEU&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=1&t=25s) Steam Audio Integration [5:40arrow-up-right](https://www.youtube.com/watch?v=jl0hOuqpZEU&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=1&t=340s) PlayMaker Integration [6:37arrow-up-right](https://www.youtube.com/watch?v=jl0hOuqpZEU&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=1&t=397s) 2D/3D Information Panel [8:04arrow-up-right](https://www.youtube.com/watch?v=jl0hOuqpZEU&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=1&t=484s) Tip: Volume Increase with AudioMixerGroups [9:32arrow-up-right](https://www.youtube.com/watch?v=jl0hOuqpZEU&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=1&t=572s) Tip: Legacy support for PlayMusic and Play2D [10:13arrow-up-right](https://www.youtube.com/watch?v=jl0hOuqpZEU&list=PL8HmiLFR3c5RyFFc_mqQVagE-qrdtMP6z&index=1&t=613s) Outro ### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#installation) Installation 1. After purchase, go to the Package Manager, show “My Assets” and search for “Sonity”. 2. Then click on “Sonity” and press “Download”, then “Import”. 3. It should be located at “Assets\\Plugins\\Sonity” circle-info **💡 TIP - Materials for URP** If materials are pink, select all “ExampleMaterial” and upgrade to URP with: Edit → Rendering → Materials → Convert Selected Built-in Materials to URP. ### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#upgrade) Upgrade 1. Backup your project before adding or updating Sonity. 2. Delete the whole Sonity folder if it says so in the Sonity Changelog.txt. 3. Import and install the latest version of Sonity from the Asset Store. 4. Restart Unity if needed. **How to Upgrade Free Trial** Just delete the “Sonity” folder and import the [paid versionarrow-up-right](https://assetstore.unity.com/packages/tools/audio/sonity-audio-middleware-229857) of Sonity, all assets created with the [free trialarrow-up-right](https://assetstore.unity.com/packages/tools/audio/sonity-audio-middleware-free-trial-244369) will continue to work. circle-info **💡 TIP - Upgrading** If you’re upgrading from an earlier version you might need to remove the whole “Sonity” folder in the project. And if you´re still having trouble, try removing the “.asmdef” files, search for “t:asmdef Sonity.” and then re-import those files again. Also, if you have your own .asmdef files in your project, you might have to reference both Sonity Runtime .asmdef files to use Sonity. ### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#adding-the-soundmanager) Adding the SoundManager The [SoundManager](https://sonity.gitbook.io/docs/soundmanager) is used to play sounds and manage global settings. An instance in the scene is required to play [SoundEvents](https://sonity.gitbook.io/docs/soundevent) . You can either add the pre-made prefab called “[SoundManager](https://sonity.gitbook.io/docs/soundmanager) ” or add the “Sonity - Sound Manager” component to an empty GameObject in the scene. circle-info ❕ Tip: Don’t forget to set up the Distance Scale to match the scale of your project.Tip: More info at [SoundManager](https://sonity.gitbook.io/docs/soundmanager) Component. ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FPyWoYljrKkM36frVWGFc%2Fimage32.gif&width=768&dpr=3&quality=100&sign=196cf933&sv=2) ### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#asset-creation) Asset Creation The asset hierarchy for playing sounds is: AudioClip → [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) → [SoundEvents](https://sonity.gitbook.io/docs/soundevent) If you have a bunch of AudioClips in your project, just select them (or their folder). Then right click to bring up the “Create” → “Sonity” → “Create Assets from Selection” menu and press the desired button. More info at [Create Assets From Selection](https://sonity.gitbook.io/docs/sonity/create-assets-from-selection) . ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FkJQwPl9k4zBHAeURK8sb%2Fimage28.gif&width=768&dpr=3&quality=100&sign=9dde4c31&sv=2) ### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#asset-editing) Asset Editing The [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) and [SoundEvents](https://sonity.gitbook.io/docs/soundevent) contain the settings of how your sounds are played. They are made of scriptable objects, so all changes you make in runtime are updated live and saved. All Sonity scriptable objects and components are multi-object editable. #### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#soundcontainer-intro) **SoundContainer Intro** ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2F3478075546-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FECYQ2OSoWTLdq4EUgnCW%252Fuploads%252Fu2BzlGogMuaiiuHSwZiP%252FSoundContainer%2520Intro.gif%3Falt%3Dmedia%26token%3Da9145dd4-420e-4e12-83bd-8b53167febde&width=768&dpr=3&quality=100&sign=be376abc&sv=2) [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) are the building blocks of Sonity. They contain AudioClips and options of how the sound should be played. All [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) are multi-object editable. **Overview of settings:** * [Looping](https://sonity.gitbook.io/docs/soundcontainer#settings) * [Volume](https://sonity.gitbook.io/docs/soundcontainer#volume) * [Pitch](https://sonity.gitbook.io/docs/soundcontainer#pitch) * [Spatial Blend](https://sonity.gitbook.io/docs/soundcontainer#spatial-blend) * [Spatial Spread](https://sonity.gitbook.io/docs/soundcontainer#spatial-spread) * [Stereo Pan](https://sonity.gitbook.io/docs/soundcontainer#stereo-pan) * [Reverb Zone Mix](https://sonity.gitbook.io/docs/soundcontainer#reverb-zone-mix) * [Distortion](https://sonity.gitbook.io/docs/soundcontainer#distortion) * [Lowpass Filter](https://sonity.gitbook.io/docs/soundcontainer#lowpass) * [Highpass Filter](https://sonity.gitbook.io/docs/soundcontainer#highpass) circle-info ❕ Tip: Don’t forget to use the [presets](https://sonity.gitbook.io/docs/soundpreset) . More info at [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) . #### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#soundevent-intro) **SoundEvent Intro** ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2FWW7f0kNDb5g90KP0gAeY%2Fimage92.gif&width=768&dpr=3&quality=100&sign=177a0cd6&sv=2) [SoundEvents](https://sonity.gitbook.io/docs/soundevent) are what you play in Sonity. They contain SoundContainers and options of how the sound should be played. All [SoundEvents](https://sonity.gitbook.io/docs/soundevent) are multi-object editable. **Overview of settings:** * [Timeline](https://sonity.gitbook.io/docs/soundevent#timeline) * [Modifier volume, pitch, fade in/out, etc](https://sonity.gitbook.io/docs/soundevent#modifiers) * [Intensity](https://sonity.gitbook.io/docs/soundevent#intensity) * Trigger another [SoundEvent](https://sonity.gitbook.io/docs/soundevent) on [Play](https://sonity.gitbook.io/docs/soundevent#trigger-on-play) , [Stop](https://sonity.gitbook.io/docs/soundevent#trigger-on-stop) , [Tail](https://sonity.gitbook.io/docs/soundevent#trigger-on-tail) , [Tag](https://sonity.gitbook.io/docs/soundevent#trigger-on-tail) More info at [SoundEvent](https://sonity.gitbook.io/docs/soundevent) . ### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#shortcuts) Shortcuts These are the default shortcuts used by Sonity and [Sonity Tools](https://sonity.gitbook.io/docs/soundmanager/editor-tools) . You can customize them at Edit → Shortcuts. Shortcut Command Create Assets From Selection/SC from AudioClips Multiple Create Assets From Selection/SC from AudioClips Single Ctrl+Shift+Q Create Assets From Selection/SC+SE from AudioClip Group Multiple SE Ctrl+Shift+W Create Assets From Selection/SC+SE from AudioClip Group Single SE Create Assets From Selection/SE from SC Multiple Create Assets From Selection/SE from SC Single Ctrl+Alt+Shift+F Reference Finder 🔍 /Find References for Selected Assets Ctrl+Alt+A Reference Finder 🔍 /Open Reference Finder Window Ctrl+Alt+Shift+A Select Same Type 👆 /In Folder Select Same Type 👆 /In Subfolders U Selection History 📜 /Back Shift+U Selection History 📜 /Forward Ctrl+Q Sound Preview - Play Ctrl+W Sound Preview - Stop **Create Assets From Selection Shortcuts** Ctrl+Shift+Q - SC+SE from AudioClip Group Multiple SE Ctrl+Shift+W - SC+SE from AudioClip Group Single SE **Preview Shortcuts** Ctrl+Q - Play (Previews the selected [SoundEvent](https://sonity.gitbook.io/docs/soundevent) or [SoundContainer](https://sonity.gitbook.io/docs/soundcontainer) ). Ctrl+W - Stop (Stops any playing preview of [SoundEvents](https://sonity.gitbook.io/docs/soundevent) and [SoundContainers](https://sonity.gitbook.io/docs/soundcontainer) , press two times to skip fade out). **Timeline Shortcuts & Controls** Zoom: Mousewheel scroll. Pan: Mousewheel hold and drag (or left mouse button also if outside of item). Volume: Hold and drag top of item up/down or click on the volume to write the decibel value. Move item: Hold and drag on item left/right. Focus on items: F ### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#playing-with-soundtrigger) Playing with SoundTrigger To play a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) , create a gameobject and add a [SoundTrigger](https://sonity.gitbook.io/docs/soundtrigger) component to it. Then select the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) you want to play and when you want it to play like in the example below: More info at [SoundTrigger](https://sonity.gitbook.io/docs/soundtrigger) . ![](https://sonity.gitbook.io/docs/~gitbook/image?url=https%3A%2F%2Fcontent.gitbook.com%2Fcontent%2FECYQ2OSoWTLdq4EUgnCW%2Fblobs%2F6bFtVcW36lo1lxOUXQj7%2Fimage95.gif&width=768&dpr=3&quality=100&sign=25de1808&sv=2) ### [hashtag](https://sonity.gitbook.io/docs/sonity/getting-started#playing-with-c) Playing with C# To play a [SoundEvent](https://sonity.gitbook.io/docs/soundevent) , create a C# script and include the “Sonity” namespace. Then make a public “[SoundEvent](https://sonity.gitbook.io/docs/soundevent) ” property, select the desired SoundEvent in the inspector. Use the functions of the [SoundEvent](https://sonity.gitbook.io/docs/soundevent) to play and stop your [SoundEvents](https://sonity.gitbook.io/docs/soundevent) like in the example below. More info at [SoundEvent Functions](https://sonity.gitbook.io/docs/soundevent/soundevent-functions) and the [SoundManager Functions](https://sonity.gitbook.io/docs/soundmanager/soundmanager-functions) . Example code: Copy using UnityEngine; using Sonity; public class PlayStopExample : MonoBehaviour { public SoundEvent soundEvent; void PlayExample() { // Plays the SoundEvent at the position of the transform soundEvent.Play(transform); } void StopExample() { // Stops the SoundEvent playing at the transform soundEvent.Stop(transform); } } [PreviousSonitychevron-left](https://sonity.gitbook.io/docs) [NextCreate Assets From Selectionchevron-right](https://sonity.gitbook.io/docs/sonity/create-assets-from-selection) Last updated 1 month ago ---