コード例 #1
0
ファイル: Player.cs プロジェクト: nickrnky/cloneshot
 public void RpcPlaySound(Assets.Scripts.SoundController.PlayMode Mode, SoundEffects SoundEffect)
 {
     if (isLocalPlayer)
     {
         if (SoundManager != null)
         {
             SoundManager.ProcessSoundEffect(Mode, SoundEffect);
         }
     }
 }
コード例 #2
0
    public void ProcessSoundEffect(Assets.Scripts.SoundController.PlayMode Mode, SoundEffects SoundEffect)
    {
        AudioClip clip = SoundEffectManager.GetClip(SoundEffect);

        if (clip != null)
        {
            SoundControllerInstance instance = new SoundControllerInstance(Mode, clip);
            ProcessSoundEffect(instance);
        }
    }