Exemplo n.º 1
0
void InfoBoxWarehouse::drawGood( const Good::Type &goodType, int col, int paintY )
{
  std::string goodName = GoodHelper::getName( goodType );

  Font font = Font::create( FONT_2 );
  int qty = _warehouse->getGoodStore().getCurrentQty(goodType);

  // pictures of goods
  const Picture& pic = GoodHelper::getPicture( goodType );
  getBgPicture().draw( pic, col * 150 + 15, paintY );

  std::string outText = StringHelper::format( 0xff, "%d %s", qty, goodName.c_str() );
  font.draw( _getBgPicture(), outText, col * 150 + 45, paintY, false );
}
Exemplo n.º 2
0
void GuiInfoBox::draw( GfxEngine& engine )
{
  engine.drawPicture( getBgPicture(), getScreenLeft(), getScreenTop() );
  Widget::draw( engine );
}