Commit b8f1b0f2 authored by alistert's avatar alistert

Bonus player drawing optimisation.

parent 9c12f2d7
......@@ -191,7 +191,8 @@ void BonusPlayer::draw (unsigned int ticks, Anim* animSet) {
anim = animSet + anims[animType];
anim->disableDefaultOffset();
anim->setFrame(ticks / 75, true);
anim->drawScaled(ITOF(canvasW >> 1), ITOF(canvasH - ((((anim->getHeight() >> 1) + 28) * canvasW) / SW)), ITOF(canvasW) / SW);
if (canvasW <= SW) anim->draw(ITOF((canvasW - anim->getWidth()) >> 1), ITOF(canvasH - anim->getHeight() - 28));
else anim->drawScaled(ITOF(canvasW >> 1), ITOF(canvasH - ((((anim->getHeight() >> 1) + 28) * canvasW) / SW)), ITOF(canvasW) / SW);
return;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment