-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathplayer.h
49 lines (40 loc) · 977 Bytes
/
player.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
#ifndef PLAYER_H
#define PLAYER_H
#include <QObject>
#include <QGraphicsItem>
#include <QMediaPlayer>
#include <QAudioOutput>
#include <QGraphicsPixmapItem>
#include <QGraphicsScene>
#include <QKeyEvent>
#include <QMouseEvent>
#include "score.h"
#include "health.h"
#include "movableObjects.h"
/*******************************************/
/*******************************************/
/**************** PLAYER *****************/
/*******************************************/
/*******************************************/
namespace insemi
{
class Player: public MovableObjects //public QObject, public QGraphicsPixmapItem
{
Q_OBJECT
public:
Player(QGraphicsItem*parent = 0);
Score* score;
Health* health;
// goal position ship
void setWannaBeX( int x);
void setWannaBeY( int y);
int playerWidth;
public slots:
void move();
private:
QMediaPlayer * bulletsound;
int wannaBeX = 0;
int wannaBeY = 0;
};
}
#endif // PLAYER_H