1/***************************************************************************
2* KBlocks, a falling blocks game for KDE *
3* Copyright (C) 2010 Zhongjie Cai <squall.leonhart.cai@gmail.com> *
4* *
5* This program is free software; you can redistribute it and/or modify *
6* it under the terms of the GNU General Public License as published by *
7* the Free Software Foundation; either version 2 of the License, or *
8* (at your option) any later version. *
9***************************************************************************/
10#ifndef KBLOCKSSCORE_H
11#define KBLOCKSSCORE_H
12
13enum KBlocks_Score_Type
14{
15 KBlocksScore_Level_x_Factor = 0,
16 KBlocksScore_Level_x_Level_x_Factor,
17 KBlocksScore_Max_Count
18};
19
20class KBlocksScore
21{
22 public:
23 KBlocksScore();
24 ~KBlocksScore();
25
26 int getScorePoint();
27 int getLineCount();
28 int getGameLevel();
29
30 void setLevelUpFactor(int type, int factor);
31 void setScoreUpFactor(int factor);
32
33 bool addScore(int lines);
34 void clearScore();
35
36 private:
37 int mPoint;
38 int mLines;
39 int mLevel;
40
41 int mType;
42 int mLFactor;
43 int mSFactor;
44};
45
46#endif
47
48