Code: Select all
void
PlayerBox::draw(gcn::Graphics *graphics)
{
if (mPlayer)
{
// Draw character
int x, y, bs;
bs = getFrameSize();
x = getWidth() / 2 - 16 + bs;
y = getHeight() / 2 + bs;
mPlayer->draw(static_cast<Graphics*>(graphics), x, y);
for (int i = 0; i < EQUIPMENT_SIZE; i++)
{
Item *item = mEquipment->getEquipment(i);
ItemInfo const *info = &item->getInfo();
if (item->getId() > 2)
{
mPlayer->setSprite(6, item->getId());
}
}
}
}