Jeck - Initialize player avatar to NULL, cleanup some minor debug leftovers. Still eventually crashes with corrupted MTGCardInstance reference.

This commit is contained in:
wagic.jeck
2009-09-03 20:10:59 +00:00
parent c6f319d685
commit 8ea9222122
2 changed files with 2 additions and 2 deletions

View File

@@ -105,7 +105,6 @@ JQuad * CardGui::alternateThumbQuad(MTGCard * card){
}
if(q && q->mTex)
q->SetHotSpot(q->mTex->mWidth/2,q->mTex->mHeight/2);
else q = q;
return q;
}
@@ -128,7 +127,7 @@ void CardGui::alternateRender(MTGCard * card, const Pos& pos){
float scale = pos.actZ * 250 / q->mHeight;
q->SetColor(ARGB((int)pos.actA,255,255,255));
renderer->RenderQuad(q, pos.actX, pos.actY, pos.actT, scale, scale);
}else q = q;
}
// Write the title
JLBFont * font = resources.GetJLBFont("magic");
float backup_scale = font->GetScale();

View File

@@ -13,6 +13,7 @@ Player::Player(MTGPlayerCards * deck, string file, string fileSmall) : Damageabl
manaPool = NEW ManaPool(this);
canPutLandsIntoPlay = 1;
mAvatar = NULL;
mAvatarTex = NULL;
type_as_damageable = DAMAGEABLE_PLAYER;
}