Fixed the crash I just introduced when buying boosters.
This commit is contained in:
@@ -217,13 +217,15 @@ void CardDisplay::Render(){
|
|||||||
mObjects[mCurr]->Render();
|
mObjects[mCurr]->Render();
|
||||||
CardGui * cardg = ((CardGui *)mObjects[mCurr]);
|
CardGui * cardg = ((CardGui *)mObjects[mCurr]);
|
||||||
Pos pos = Pos(CardGui::BigWidth / 2, CardGui::BigHeight / 2 - 10, 1.0, 0.0, 220);
|
Pos pos = Pos(CardGui::BigWidth / 2, CardGui::BigHeight / 2 - 10, 1.0, 0.0, 220);
|
||||||
|
int drawMode = DrawMode::kNormal;
|
||||||
if (game)
|
if (game)
|
||||||
{
|
{
|
||||||
pos.actY = 150;
|
pos.actY = 150;
|
||||||
if (x < (CardGui::BigWidth / 2)) pos.actX = SCREEN_WIDTH - 10 - CardGui::BigWidth / 2;
|
if (x < (CardGui::BigWidth / 2)) pos.actX = SCREEN_WIDTH - 10 - CardGui::BigWidth / 2;
|
||||||
|
drawMode = CardSelectorSingleton::Instance()->GetDrawMode();
|
||||||
}
|
}
|
||||||
|
|
||||||
cardg->DrawCard(pos, CardSelectorSingleton::Instance()->GetDrawMode());
|
cardg->DrawCard(pos, drawMode);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user