Sound Layers Setup (Unity Plugin)

From PopcornFX
Jump to: navigation, search

Since v2.5, the PopcornFX plugin supports PopcornFX' sound layers.

Unity-logo-g.png

Setup Sound Layer in PopcornFX Editor

  1. In the PopcornFX Editor, add a sound layer to your effect.
    NewSoundLayer.gif
  2. Set the SoundPath to a sound file in your project.
    SetSoundPath.png
  3. Bake your effect with dependencies. This should copy the sound file to your baked pack along with the other dependencies.

Setup in Unity

  1. Add a PKFxSoundManager component (from the PKFxManager assembly) in your scene.
    UnitySoundManagerComponent.png
  2. Attach your FX containing a sound layer to a PKFxFX component.
    SoundLayerFxUnity.gif
  3. Click "Assets > PopcornFX > Move Sounds From Pack to Resources".
    This will scan the PackFX directory looking for sound files and move them to Assets/Resources/PKFxSounds so that Unity can play them.
    You may need to refresh your project view for the sound to play along with your FX.
    UnitySoundLayerMoveSoundFiles.png
    For every file moved, you'll get a log in the console.
    UnitySoundLayerMoveSoundFilesLog.png
  4. Hit play, see FX, hear sound, rejoice!