-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathStatsPanel.h
55 lines (40 loc) · 1.01 KB
/
StatsPanel.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
52
53
54
55
#ifndef __STATSPANEL_H__
#define __STATSPANEL_H__
/**
* StatsPanel.h
*
* $Revision$
* $Id$
*
*
*/
#include "StatsListener.h"
#include "Graphics.h"
#include "Panel.h"
#include "TetrisStats.h"
#include "TickListener.h"
#include "Config.h"
#include <sstream>
class CStatsPanel : public VStatsListener, public VPanel, public VTickListener {
public:
CStatsPanel(const CTetrisStats *stats, const int x, const int y);
virtual ~CStatsPanel();
virtual void draw(void);
virtual void handleChangeInStats(const int score, const int level, const int reml, const int remll);
virtual int handleTick();
private:
SGraphics *g;
SConfig *s;
SGraphics::GCOLOR m_foreground2;
int m_score;
int m_level;
int m_reml;
int m_remll;
int m_flashCount;
static const int m_flashDelay = 400;
bool m_flashOn;
std::string intToString(const int i);
// temporary for effect
void drawBackground();
};
#endif // __STATSPANEL_H__