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; }
void OnReceivedImageTextureTwo(ItemTextureCache.ImageStatus statusMsg, Texture2D texture) { if (statusMsg == ItemTextureCache.ImageStatus.Cache) { IntegrationTest.Pass(gameObject); } else { IntegrationTest.Fail(gameObject); } }
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); } }
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); } } }
void OnReceivedItemTexture(ItemTextureCache.ImageStatus imgStatus, Texture2D texture) { GetComponentInChildren <UITexture>().mainTexture = texture; }