I am refering the Avatar Service from the App42. I have got specific N number of avatars which I am creating at the time of first login now When the user wish he should be able to change the avatar from my specified N number of avatars. I do use the
avatarService.ChangeCurrentAvatar(userName,avatarName, new UnityCallBack());
and it gives the response to Is Current :True.
When I do quit the app and gain fetch the avatar the service gives me the last uploaded avtar. Please do help me to get the newer avatar.
Thank you
EDIT 1: Code Snippet
From AvatarScript
public void getCurrentAvatar(string name){
if(name != null){
avatarService.GetCurrentAvatar(name,avatarListener);
}
}
public void getCurrentAvatarTexture(string urlForAvatar,string nmOfAvatar){ StartCoroutine(fetchAvatar(urlForAvatar,nmOfAvatar));
}
IEnumerator fetchAvatar(string url,string nmOfAvatar1){
WWW www=new WWW(url);
yield return www;
currentAvatar = (Texture2D) www.texture;
assignCurrentAvatar(currentAvatar,nmOfAvatar1);
}
From Response Script
AvatarScript.sharedAvatarScript.getCurrentAvatarTexture(avatar.GetUrl(),avatar.GetName());