-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathgame.h
More file actions
45 lines (37 loc) · 830 Bytes
/
game.h
File metadata and controls
45 lines (37 loc) · 830 Bytes
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
#ifndef GAME_H
#define GAME_H
#include <QDialog>
#include "gamethread.h"
#include "artificialintelligence.h"
namespace Ui {
class Game;
}
class Game : public QDialog
{
Q_OBJECT
public:
explicit Game(QWidget *parent = 0);
~Game();
GameThread *gThread;
ArtificialIntelligence *AI;
int list[5];
int counter;
int player_score, computer_score;
void updatePlayer(QImage img);
void updateList(int i);
public slots:
void onFieldChanged(int);
QImage chooseSign(int);
private slots:
void on_Start_clicked();
void on_Stop_clicked();
private:
Ui::Game *ui;
QImage img3, img2, img1, rock, paper, scissors;
int size, com_sign;
void updateResult(int);
void updateScore(int);
int checkPlayer();
int max_c(int a, int b, int c, int d);
};
#endif // GAME_H