00001 #ifndef SCORE_SPRITE_H
00002 #define SCORE_SPRITE_H
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #include <QPointF>
00025 #include <QSizeF>
00026 #include <QGraphicsPixmapItem>
00027 #include <QGraphicsTextItem>
00028
00029
00030
00031 #include "thememanager.h"
00032 #include "pixmapsprite.h"
00033
00034
00037 class ScoreSprite : public PixmapSprite
00038 {
00039
00040 public:
00048 ScoreSprite(QString id, ThemeManager* theme, int advancePeriod, int no, QGraphicsScene* scene);
00049
00052 ~ScoreSprite();
00053
00057 virtual void advance(int phase);
00058
00062 virtual int type() const {return QGraphicsItem::UserType+10;}
00063
00067 virtual void changeTheme();
00068
00073 void setLevel(int level, int no);
00074
00079 void setPlayerName(QString s,int no);
00080
00085 void setWon(QString s,int no);
00086
00091 void setDraw(QString s,int no);
00092
00097 void setLoss(QString s,int no);
00098
00103 void setBreak(QString s,int no);
00104
00108 void setTurn(int no);
00109
00114 void setInput(int device, int no);
00115
00116 private:
00117
00118 QGraphicsTextItem* mWon[2];
00119
00120
00121 QGraphicsTextItem* mDraw[2];
00122
00123
00124 QGraphicsTextItem* mLoss[2];
00125
00126
00127 QGraphicsTextItem* mBreak[2];
00128
00129
00130 QGraphicsTextItem* mName[2];
00131
00132
00133 PixmapSprite* mInput[2];
00134
00135
00136 int mInputFrame[2];
00137
00138
00139 int mTurn;
00140
00141 };
00142
00143 #endif