Erwan - cache fixes - Code review highly appreciated, please criticize my code!
- fix issue 65 (quads when no image load slowly in shop/deck editor) - Possibly fix issue 92, please let me know if it reproduces - Fix issue 97 (Deck editor: weird behavior of deck display) - Fix issue 39 - please verify - Issue 56 can probably be closed as well - Fix issue 86
This commit is contained in:
@@ -638,15 +638,15 @@ MTGCardInstance * AIPlayerBaka::FindCardToPlay(ManaCost * pMana, const char * ty
|
||||
}
|
||||
|
||||
AIPlayerBaka::AIPlayerBaka(MTGPlayerCards * deck, string file, string fileSmall, string avatarFile) : AIPlayer(deck, file, fileSmall) {
|
||||
mAvatarTex = resources.RetrieveTexture(avatarFile,RETRIEVE_VRAM,TEXTURE_SUB_AVATAR);
|
||||
mAvatarTex = resources.RetrieveTexture(avatarFile,RETRIEVE_LOCK,TEXTURE_SUB_AVATAR);
|
||||
|
||||
if(!mAvatarTex){
|
||||
avatarFile = "baka.jpg";
|
||||
mAvatarTex = resources.RetrieveTexture(avatarFile,RETRIEVE_VRAM,TEXTURE_SUB_AVATAR);
|
||||
mAvatarTex = resources.RetrieveTexture(avatarFile,RETRIEVE_LOCK,TEXTURE_SUB_AVATAR);
|
||||
}
|
||||
|
||||
if(mAvatarTex)
|
||||
mAvatar = resources.RetrieveQuad(avatarFile, 0, 0, 35, 50,"bakaAvatar",RETRIEVE_VRAM,TEXTURE_SUB_AVATAR);
|
||||
mAvatar = resources.RetrieveQuad(avatarFile, 0, 0, 35, 50,"bakaAvatar",RETRIEVE_NORMAL,TEXTURE_SUB_AVATAR);
|
||||
else
|
||||
mAvatar = NULL;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user