Jeck - Initialize player avatar to NULL, cleanup some minor debug leftovers. Still eventually crashes with corrupted MTGCardInstance reference.
This commit is contained in:
@@ -105,7 +105,6 @@ JQuad * CardGui::alternateThumbQuad(MTGCard * card){
|
|||||||
}
|
}
|
||||||
if(q && q->mTex)
|
if(q && q->mTex)
|
||||||
q->SetHotSpot(q->mTex->mWidth/2,q->mTex->mHeight/2);
|
q->SetHotSpot(q->mTex->mWidth/2,q->mTex->mHeight/2);
|
||||||
else q = q;
|
|
||||||
return q;
|
return q;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -128,7 +127,7 @@ void CardGui::alternateRender(MTGCard * card, const Pos& pos){
|
|||||||
float scale = pos.actZ * 250 / q->mHeight;
|
float scale = pos.actZ * 250 / q->mHeight;
|
||||||
q->SetColor(ARGB((int)pos.actA,255,255,255));
|
q->SetColor(ARGB((int)pos.actA,255,255,255));
|
||||||
renderer->RenderQuad(q, pos.actX, pos.actY, pos.actT, scale, scale);
|
renderer->RenderQuad(q, pos.actX, pos.actY, pos.actT, scale, scale);
|
||||||
}else q = q;
|
}
|
||||||
// Write the title
|
// Write the title
|
||||||
JLBFont * font = resources.GetJLBFont("magic");
|
JLBFont * font = resources.GetJLBFont("magic");
|
||||||
float backup_scale = font->GetScale();
|
float backup_scale = font->GetScale();
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ Player::Player(MTGPlayerCards * deck, string file, string fileSmall) : Damageabl
|
|||||||
manaPool = NEW ManaPool(this);
|
manaPool = NEW ManaPool(this);
|
||||||
canPutLandsIntoPlay = 1;
|
canPutLandsIntoPlay = 1;
|
||||||
mAvatar = NULL;
|
mAvatar = NULL;
|
||||||
|
mAvatarTex = NULL;
|
||||||
type_as_damageable = DAMAGEABLE_PLAYER;
|
type_as_damageable = DAMAGEABLE_PLAYER;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user