Пример #1
0
 public void SetLoaderObject(LoaderObject loader)
 {
     this.filePath = loader.GetFilePath();
     oggLoader = loader as SoundLoaderObject;
     if (oggLoader == null) {
     Debug.LogError("Loader for " + this.filePath + " is not an OggSoundLoaderObject");
     }
 }
Пример #2
0
 public void SetLoaderObject(LoaderObject loader)
 {
     this.filePath = loader.GetFilePath();
     oggLoader     = loader as SoundLoaderObject;
     if (oggLoader == null)
     {
         Debug.LogError("Loader for " + this.filePath + " is not an OggSoundLoaderObject");
     }
 }
Пример #3
0
 protected void DoUpdate()
 {
     if (oggLoader != null) {
     if (oggLoader.IsLoaded()) {
         this.oggSound = oggLoader.GetSound();
         this.audio.clip = oggLoader.GetSound();
         oggLoader = null;
     }
     }
 }
Пример #4
0
 protected void DoUpdate()
 {
     if (oggLoader != null)
     {
         if (oggLoader.IsLoaded())
         {
             this.oggSound   = oggLoader.GetSound();
             this.audio.clip = oggLoader.GetSound();
             oggLoader       = null;
         }
     }
 }
Пример #5
0
        public icUnitySound CreateOggSoundMaterial(string filePath, GameObject go)
        {
            icUnitySound so = go.GetComponent <icUnitySound>();

            if (so == null)
            {
                so = go.AddComponent <icUnitySound>();
            }

            SoundLoaderObject lo = new SoundLoaderObject(filePath, this.threadedLoader);

            so.SetLoaderObject(lo);
            this.threadedLoader.AddLoaderInfo(lo);

            return(so);
        }
Пример #6
0
        public icUnitySound CreateOggSoundMaterial(string filePath, GameObject go)
        {
            icUnitySound so = go.GetComponent<icUnitySound>();

            if (so == null)
            so = go.AddComponent<icUnitySound>();

            SoundLoaderObject lo = new SoundLoaderObject(filePath, this.threadedLoader);
            so.SetLoaderObject(lo);
            this.threadedLoader.AddLoaderInfo(lo);

            return so;
        }