コード例 #1
0
    void OnReceivedTexture(ItemTextureCache.ImageStatus statusMsg, Texture2D texture)
    {
        UITexture uiTexture = gameObject.GetComponentInChildren <UITexture>();

        uiTexture.material                 = new Material(uiTexture.material.shader);
        uiTexture.mainTexture              = texture;
        uiTexture.transform.localPosition -= Vector3.forward * 2;
    }
コード例 #2
0
 void OnReceivedImageTextureTwo(ItemTextureCache.ImageStatus statusMsg, Texture2D texture)
 {
     if (statusMsg == ItemTextureCache.ImageStatus.Cache)
     {
         IntegrationTest.Pass(gameObject);
     }
     else
     {
         IntegrationTest.Fail(gameObject);
     }
 }
コード例 #3
0
 void OnReceivedItemTexture(ItemTextureCache.ImageStatus statusMsg, Texture2D texture)
 {
     if (statusMsg == ItemTextureCache.ImageStatus.Web)
     {
         ItemTextureCache.instance.GetItemTexture("http://www.desicomments.com/dc3/01/209982/209982.gif", OnReceivedImageTextureTwo);
     }
     else
     {
         IntegrationTest.Fail(gameObject);
     }
 }
コード例 #4
0
    void OnReceivedItemTexture(ItemTextureCache.ImageStatus statusMsg, Texture2D texture)
    {
        if (isFirstCall)
        {
            if (statusMsg != ItemTextureCache.ImageStatus.Web)
            {
                IntegrationTest.Fail(gameObject);
            }

            isFirstCall = false;
        }
        else
        {
            if (statusMsg == ItemTextureCache.ImageStatus.Cache)
            {
                IntegrationTest.Pass(gameObject);
            }
            else
            {
                IntegrationTest.Fail(gameObject);
            }
        }
    }
コード例 #5
0
 void OnReceivedItemTexture(ItemTextureCache.ImageStatus imgStatus, Texture2D texture)
 {
     GetComponentInChildren <UITexture>().mainTexture = texture;
 }