rez • on • ant
- continuing to sound.
- capable of inducing.
- marked by grandiloquence.
Resonant is a powerful modular audio manager and sound randomizer. Leveraging capabilities for randomized, looping sound clips, randomized volume and pitch modulation, and customizable audio events/reactions, Resonant is extendable and multi-purposed. Though it's powerful trigger/reaction system, design audio events and reactions to real-time code.
- Install the latest release from the GitHub repository, unzip it, and place the folder into your Unity project's
Packages
folder. - Return to Unity, and the package should automatically be recognized and visible in the Package Manager.
- A sample scene can be found at:
Resonant/Example/Example.unity
. - Opening this scene may prompt you to install Text Mesh Pro. Simply click on Import TMP Essentials to do so.
- Resonant is built on top of Unity's
AudioSource
/AudioClip
system.AudioSource
s can be controlled through the Resonant system usingResonantSource
,ResonantRandomizer
, orResonantSoundbank
Components
. - All three Resonant components require an
AudioSource
, and may modify it's parameters (e.g. volume) at runtime. However, otherAudioClip
settings (e.g. 3D sound, mixers, etc.) can still be changed to improve or customize your audio setup. - The only Resonant component that does not require a
ResonantBehaviour
/ResonantManager
to function is aResonantRandomizer
. ResonantBehaviours
can be used to create complex reaction setups when certain states are triggered. All reactions can be found inResonant/Runtime/Reactions
, and are fully documented.
- Add a
ResonantRandomizer
Component
to aGameObject
. - Assign it the
AudioCLips
you wish to play. Delay Modulation
represents the randomly-choen amount of time between each looping clip.Volume Modulation
represents the range away from the starting volume that theAudioSource
's volume can be randomly set to whenAudioClips
are randomly played.Pitch Modulation
represents the range away from the starting pitch that theAudioSource
's pitch can be randomly set to whenAudioClips
are randomly played.- If you want the
ResonantRandomizer
to start playing when the game begins, turn onLoop On Start
.
ResonantBehaviour
data is saved asScriptableObjects
, which can be created withCreate/Resonant Behaviour
.- Rename your newly created behaviour, then right click on it and select
Edit Resonant Behaviour
. This will open the Resonant Editor window. - Click on the Add trigger button to add a new trigger, and give it an ID. This trigger will be called by you through your code. (Click on the '-' button to delete this trigger)
- Select the
ResonantReaction
of your choice from the dropdown next to the Add reaction button, and add it. (Click on the '-' button to delete this reaction) ResonantReactions
can have many fields and functionalities. All reactions can be found inResonant/Runtime/Reactions
, and are fully documented.- Assign the
ResonantReaction
'sID
. This ID should match the ID(s) of theResonantSource
s,ResonantRandomizer
s, and/orResonantSoundbank
s in your scene that you want it to affect. - Don't forget to save with the Save button!
- In your scene add a
ResonantManager
to aGameObject
, and assign it theResonantBehaviour
that you just created. - At runtime, call
ResonantManager.Trigger
, and pass it the ID of the trigger you created. (Note:ResonantTrigger
IDs are not the same asResonantReaction
IDs)