]> git.llucax.com Git - z.facultad/75.42/plaqui.git/blob - Client/src/item_tank.cpp
Se agrega un archivo que falto subir en el ultimo commit XD
[z.facultad/75.42/plaqui.git] / Client / src / item_tank.cpp
1
2 #include "item_tank.h"
3 #include <sstream>
4
5 ViewTank::ViewTank(Glib::ustring _name, int orientacion):ViewItem(_name)
6 {
7         switch (orientacion) {
8                 case 0:
9                         image.set(PACKAGE_DATA_DIR"/plaqui-client/pixmaps/tanque_e.png");
10                         in_x = 5;
11                         in_y = 16;
12                         out_x = 64-16;
13                         out_y = 64;
14                         offset_x = 0;
15                         offset_y = 0;
16                         item_offset_x = 0;
17                         item_offset_y = 0;
18                 break;
19                 case 1:
20                         image.set(PACKAGE_DATA_DIR"/plaqui-client/pixmaps/tanque_o.png");
21                         in_x = 64-5;
22                         in_y = 16;
23                         out_x = 16;
24                         out_y = 64;
25                         offset_x = 0;
26                         offset_y = 0;
27                         item_offset_x = 0;
28                         item_offset_y = 0;
29         }
30         image.show();
31         set_size_request();
32 }
33
34 ViewTank::~ViewTank()
35 {
36 }
37
38 std::string ViewTank::get_extra()
39 {
40         std::stringstream ss;
41         std::string s;
42         ss << extra;
43         ss >> s;
44         return s;
45 }
46