-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathobjects.h
51 lines (46 loc) · 820 Bytes
/
objects.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#ifndef OBJECTS_H
#define OBJECTS_H
#include <QObject>
#include "map.h"
class Objects {
public:
Objects(int, Map*);
// virtual ~Objects();
virtual void setPic(QString) = 0;
int get_x();
int get_y();
int get_line();
int get_row();
void change_line(int);
void change_row(int);
QPixmap getPic();
bool get_alive();
QRect get_volume();
void set_volume();
virtual void attacked(int);
void add_hp(int);
int get_curHP();
int get_maxHP();
Map* get_pos();
int get_width();
int get_height();
void set_dirc(int);
int get_dirc();
void change_rect();
bool is_show();
protected:
int maxHP;
bool is_alive;
Map* position;
int curHP;
QRect volume;
int x;
int y;
int line;
int row;
QPixmap pic;
int pic_num;
int dirc;
bool show_rect;
};
#endif // OBJECTS_H