Ejemplo n.º 1
0
 public override void OnSceneVisible()
 {
     Debug.Log("OnSceneVisible_B");
     resourceRequestSet = new ResourceRequestSet();
     for (var i = 0; i < 100; i++)
     {
         resourceRequestSet.Add(
             string.Format("http://pictogram-free.com/thumbnail/s_{0}.png", (i + 1).ToString("000")),
             ResourceType.Texture);
     }
     ResourceManager.Instance.RegisterRequestSet(
         RequestResourceLabel,
         resourceRequestSet);
 }
Ejemplo n.º 2
0
    public override void OnSceneInvisible()
    {
        Debug.Log("OnSceneInvisible_B");
        ResourceManager.Instance.UnregisterRequestSet(RequestResourceLabel);
        listShowedResourceName.Clear();

        foreach (Transform trans in _layout.transform)
        {
            if (trans.gameObject.activeSelf == true)
            {
                Object.Destroy(trans.gameObject);
            }
        }

        resourceRequestSet = null;
    }