Inheritance: MonoBehaviour
    void playSongLocal(PreloadSong song)
    {
        //		StopWithFade ();
        source.Stop();
        if (lastPreloadedSong != null)
        {
            lastPreloadedSong.audioSource.Stop();
        }
        lastPreloadedSong = song;
        song.audioSource.Play();
//		StartCoroutine (APICacheManager.Instance.downloadAudio(song.musicPath, onReady, song.local));
    }
Beispiel #2
0
    public void SetSongLocal(PreloadSong song)
    {
        isReady = true;

        if (song != localSong || !local)
        {
            this.text.text = song.songName;
            if (song.thumbnail != null)
            {
                this.image.texture = song.thumbnail;
            }
            else
            {
                this.image.texture = defaultImage;
            }
        }
        else
        {
        }
        localSong = song;

        local = true;
    }