Exemplo n.º 1
0
        protected override void OnReleaseRes()
        {
            if (Asset is GameObject)
            {
            }
            else
            {
                Resources.UnloadAsset(Asset);
            }

            Asset = null;
            mResLoader.ReleaseAll();
            mResLoader = null;
            ResMgr.Instance.SharedLoadedReses.Remove(this);
        }
Exemplo n.º 2
0
        // Use this for initialization
        IEnumerator Start()
        {
            yield return(new WaitForSeconds(2f));

            mResLoader.LoadAsync <AudioClip>("resources://hit", hitClip => {
                Debug.Log(hitClip.name);
                Debug.Log(Time.deltaTime);
            });

            Debug.Log(Time.deltaTime);

            mResLoader.LoadSync <GameObject>("resources://HomePanel");

            yield return(new WaitForSeconds(2f));

            mResLoader.LoadSync <AudioClip>("resources://bgm");

            mResLoader.LoadSync <AudioClip>("resources://Audio/hit");

            yield return(new WaitForSeconds(5f));

            mResLoader.ReleaseAll();
        }
Exemplo n.º 3
0
 // Update is called once per frame
 void OnDestroy()
 {
     mResLoader.ReleaseAll();
 }
Exemplo n.º 4
0
 // Update is called once per frame
 void OnDestroy()
 {
     mResLoader.ReleaseAll();
     mResLoader = null;
 }
Exemplo n.º 5
0
 void OnDestroy()
 {
     Debug.Log("UIYYYPanel");
     mResLoader.ReleaseAll();
 }