Jeck - The shop anti-aliasing stuff is rendered inside of shop->Render(), so that it renders on top of the cards, but under other UI elements handled by ShopItems (the price dialog, etc). Moved the light flicker inside of ShopItems instead (for now, as this is pretty damn inelegant). As far as the 5551 issue goes, I don't see how using a jpeg would do much harm, but leave the decision up to others :)

This commit is contained in:
wagic.jeck
2009-11-03 20:55:04 +00:00
parent 7f0f632b2c
commit ffa8408a5f
4 changed files with 21 additions and 19 deletions

View File

@@ -53,9 +53,6 @@ void GameStateShop::Start()
JRenderer::GetInstance()->EnableVSync(true);
lightAlpha = 0;
alphaChange = 0;
shop = NULL;
load();
@@ -169,11 +166,6 @@ void GameStateShop::Update(float dt)
shop->Update(dt);
}
alphaChange = (500 - (rand() % 1000)) * dt;
lightAlpha+= alphaChange;
if (lightAlpha < 0) lightAlpha = 0;
if (lightAlpha > 50) lightAlpha = 50;
}
@@ -185,16 +177,10 @@ void GameStateShop::Render()
if (mBg) r->RenderQuad(mBg,0,0);
JQuad * quad = resources.RetrieveTempQuad("shop_light.png");
if (quad){
r->SetTexBlend(BLEND_SRC_ALPHA, BLEND_ONE);
quad->SetColor(ARGB(lightAlpha,255,255,255));
r->RenderQuad(quad,0,0);
r->SetTexBlend(BLEND_SRC_ALPHA, BLEND_ONE_MINUS_SRC_ALPHA);
}
if (shop)
shop->Render();
if (mStage == STAGE_SHOP_MENU && menu){
menu->Render();
}