1
// $Id: pingu_info.cxx,v 1.8 2003/02/19 09:50:36 grumbel Exp $
3
// Pingus - A free Lemmings clone
4
// Copyright (C) 1999 Ingo Ruhnke <grumbel@gmx.de>
6
// This program is free software; you can redistribute it and/or
7
// modify it under the terms of the GNU General Public License
8
// as published by the Free Software Foundation; either version 2
9
// of the License, or (at your option) any later version.
11
// This program is distributed in the hope that it will be useful,
12
// but WITHOUT ANY WARRANTY; without even the implied warranty of
13
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
// GNU General Public License for more details.
16
// You should have received a copy of the GNU General Public License
17
// along with this program; if not, write to the Free Software
18
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21
#include <ClanLib/Display/Display/display.h>
22
#include <ClanLib/Display/Font/font.h>
23
#include "pingus_resource.hxx"
24
#include "pingu_info.hxx"
26
#include "string_converter.hxx"
27
#include "my_gettext.hxx"
29
PinguInfo::PinguInfo()
32
font = PingusResource::load_font("Fonts/courier_small","fonts");
41
CL_Display::fill_rect(x_pos + CL_Display::get_width() - 220,
42
y_pos + CL_Display::get_height() - 55,
43
x_pos + CL_Display::get_width() - 5,
44
y_pos + CL_Display::get_height() - 5,
45
0.2f, 0.2f, 0.2f, 1.0f);
49
snprintf(str, 128, _("pingu_id %d"), pingu->get_id());
50
font->print_left(x_pos + CL_Display::get_width() - 185,
51
y_pos + CL_Display::get_height() - 50,
54
if (pingu->get_action()) {
55
snprintf(str, 128, _("action %s"), pingu->get_name().c_str());
57
snprintf(str, 128, _("action none"));
60
font->print_left(x_pos + CL_Display::get_width() - 185,
61
y_pos + CL_Display::get_height() - 30,
62
string_downcase(str));
64
font->print_left(x_pos + CL_Display::get_width() - 200,
65
y_pos + CL_Display::get_height() - 50,
71
PinguInfo::set_pingu(Pingu* p)