crash fix in buying booster

this should be in game only
This commit is contained in:
Anthony Calosa
2017-02-24 15:04:12 +08:00
parent efac298eb0
commit d0b2340a73
+13 -10
View File
@@ -530,18 +530,21 @@ void CardGui::Render()
} }
//for necro //for necro
if (!shadow) if(game)
shadow = card->getObserver()->getResourceManager()->GetQuad("shadow");
if (shadow)
{ {
int myA = 0; if (!shadow)
if(game && card->has(Constants::NECROED))//no peeking... shadow = card->getObserver()->getResourceManager()->GetQuad("shadow");
myA = 255; if (shadow)
else {
myA = 0; int myA = 0;
if(game && card->has(Constants::NECROED))//no peeking...
myA = 255;
else
myA = 0;
shadow->SetColor(ARGB(myA,255,255,255)); shadow->SetColor(ARGB(myA,255,255,255));
renderer->RenderQuad(shadow.get(), actX, actY, actT, (28 * actZ + 1) / 16, 40 * actZ / 16); renderer->RenderQuad(shadow.get(), actX, actY, actT, (28 * actZ + 1) / 16, 40 * actZ / 16);
}
} }
PlayGuiObject::Render(); PlayGuiObject::Render();