summaryrefslogtreecommitdiff
path: root/noncore/games/kpacman/referee.cpp
Unidiff
Diffstat (limited to 'noncore/games/kpacman/referee.cpp') (more/less context) (show whitespace changes)
-rw-r--r--noncore/games/kpacman/referee.cpp54
1 files changed, 27 insertions, 27 deletions
diff --git a/noncore/games/kpacman/referee.cpp b/noncore/games/kpacman/referee.cpp
index 567a8ed..9edaabd 100644
--- a/noncore/games/kpacman/referee.cpp
+++ b/noncore/games/kpacman/referee.cpp
@@ -95,8 +95,8 @@ void Referee::paintEvent( QPaintEvent *e)
95 } 95 }
96 96
97 if ((gameState.testBit(GameOver) || gameState.testBit(Demonstration)) && 97 if ((gameState.testBit(GameOver) || gameState.testBit(Demonstration)) &&
98 rect.intersects(pix->rect(board->position(fruithome), i18n("GAME OVER")))) 98 rect.intersects(pix->rect(board->position(fruithome), tr("GAME OVER"))))
99 pix->draw(board->position(fruithome), Widget, i18n("GAME OVER"), RED); 99 pix->draw(board->position(fruithome), Widget, tr("GAME OVER"), RED);
100 100
101 for (Energizer *e = energizers->first(); e != 0; e = energizers->next()) { 101 for (Energizer *e = energizers->first(); e != 0; e = energizers->next()) {
102 if (e && e->state() == on && 102 if (e && e->state() == on &&
@@ -157,16 +157,16 @@ void Referee::paintEvent( QPaintEvent *e)
157 pix->draw(pacman->position(), Widget, PacmanPix, pacman->pix()); 157 pix->draw(pacman->position(), Widget, PacmanPix, pacman->pix());
158 158
159 if (gameState.testBit(Player) && 159 if (gameState.testBit(Player) &&
160 rect.intersects(pix->rect(board->position(monsterhome, 0), i18n("PLAYER ONE")))) 160 rect.intersects(pix->rect(board->position(monsterhome, 0), tr("PLAYER ONE"))))
161 pix->draw(board->position(monsterhome, 0), Widget, i18n("PLAYER ONE"), CYAN); 161 pix->draw(board->position(monsterhome, 0), Widget, tr("PLAYER ONE"), CYAN);
162 162
163 if (gameState.testBit(Ready) && 163 if (gameState.testBit(Ready) &&
164 rect.intersects(pix->rect(board->position(fruithome), i18n("READY!")))) 164 rect.intersects(pix->rect(board->position(fruithome), tr("READY!"))))
165 pix->draw(board->position(fruithome), Widget, i18n("READY!"), YELLOW); 165 pix->draw(board->position(fruithome), Widget, tr("READY!"), YELLOW);
166 166
167 if (gameState.testBit(Paused) && 167 if (gameState.testBit(Paused) &&
168 rect.intersects(pix->rect((BoardWidth*BoardHeight)/2-BoardWidth, i18n("PAUSED")))) 168 rect.intersects(pix->rect((BoardWidth*BoardHeight)/2-BoardWidth, tr("PAUSED"))))
169 pix->draw((BoardWidth*BoardHeight)/2-BoardWidth, Widget, i18n("PAUSED"), RED, BLACK); 169 pix->draw((BoardWidth*BoardHeight)/2-BoardWidth, Widget, tr("PAUSED"), RED, BLACK);
170} 170}
171 171
172void Referee::timerEvent( QTimerEvent *e ) 172void Referee::timerEvent( QTimerEvent *e )
@@ -840,10 +840,10 @@ void Referee::pause()
840 stop(); 840 stop();
841 stopEnergizer(); 841 stopEnergizer();
842 gameState.setBit(Paused); 842 gameState.setBit(Paused);
843 repaint(pix->rect((BoardWidth*BoardHeight)/2-BoardWidth, i18n("PAUSED")), FALSE); 843 repaint(pix->rect((BoardWidth*BoardHeight)/2-BoardWidth, tr("PAUSED")), FALSE);
844 } else { 844 } else {
845 gameState.clearBit(Paused); 845 gameState.clearBit(Paused);
846 repaint(pix->rect((BoardWidth*BoardHeight)/2-BoardWidth, i18n("PAUSED")), FALSE); 846 repaint(pix->rect((BoardWidth*BoardHeight)/2-BoardWidth, tr("PAUSED")), FALSE);
847 if (pausedTimer) { 847 if (pausedTimer) {
848 pausedTimer = 0; 848 pausedTimer = 0;
849 start(); 849 start();
@@ -906,33 +906,33 @@ void Referee::introPaint(int t)
906 QString pts; 906 QString pts;
907 907
908 switch (t) { 908 switch (t) {
909 case 0 : repaint(pix->draw(16, 6, RoomPix, i18n("CHARACTER"), WHITE, QColor(), AlignLeft), FALSE); 909 case 0 : repaint(pix->draw(16, 6, RoomPix, tr("CHARACTER"), WHITE, QColor(), AlignLeft), FALSE);
910 repaint(pix->draw(36, 6, RoomPix, i18n("/"), WHITE, QColor(), AlignLeft), FALSE); 910 repaint(pix->draw(36, 6, RoomPix, tr("/"), WHITE, QColor(), AlignLeft), FALSE);
911 repaint(pix->draw(40, 6, RoomPix, i18n("NICKNAME"), WHITE, QColor(), AlignLeft), FALSE); 911 repaint(pix->draw(40, 6, RoomPix, tr("NICKNAME"), WHITE, QColor(), AlignLeft), FALSE);
912 break; 912 break;
913 case 1 : introMonster(0); 913 case 1 : introMonster(0);
914 break; 914 break;
915 case 2 : repaint(pix->draw(16, 10, RoomPix, i18n("-SHADOW"), RED, QColor(), AlignLeft), FALSE); 915 case 2 : repaint(pix->draw(16, 10, RoomPix, tr("-SHADOW"), RED, QColor(), AlignLeft), FALSE);
916 break; 916 break;
917 case 3 : repaint(pix->draw(38, 10, RoomPix, i18n("\"BLINKY\""), RED, QColor(), AlignLeft), FALSE); 917 case 3 : repaint(pix->draw(38, 10, RoomPix, tr("\"BLINKY\""), RED, QColor(), AlignLeft), FALSE);
918 break; 918 break;
919 case 4 : introMonster(1); 919 case 4 : introMonster(1);
920 break; 920 break;
921 case 5 : repaint(pix->draw(16, 16, RoomPix, i18n("-SPEEDY"), PINK, QColor(), AlignLeft), FALSE); 921 case 5 : repaint(pix->draw(16, 16, RoomPix, tr("-SPEEDY"), PINK, QColor(), AlignLeft), FALSE);
922 break; 922 break;
923 case 6 : repaint(pix->draw(38, 16, RoomPix, i18n("\"PINKY\""), PINK, QColor(), AlignLeft), FALSE); 923 case 6 : repaint(pix->draw(38, 16, RoomPix, tr("\"PINKY\""), PINK, QColor(), AlignLeft), FALSE);
924 break; 924 break;
925 case 7 : introMonster(2); 925 case 7 : introMonster(2);
926 break; 926 break;
927 case 8 : repaint(pix->draw(16, 22, RoomPix, i18n("-BASHFUL"), CYAN, QColor(), AlignLeft), FALSE); 927 case 8 : repaint(pix->draw(16, 22, RoomPix, tr("-BASHFUL"), CYAN, QColor(), AlignLeft), FALSE);
928 break; 928 break;
929 case 9 : repaint(pix->draw(38, 22, RoomPix, i18n("\"INKY\""), CYAN, QColor(), AlignLeft), FALSE); 929 case 9 : repaint(pix->draw(38, 22, RoomPix, tr("\"INKY\""), CYAN, QColor(), AlignLeft), FALSE);
930 break; 930 break;
931 case 10 : introMonster(3); 931 case 10 : introMonster(3);
932 break; 932 break;
933 case 11 : repaint(pix->draw(16, 28, RoomPix, i18n("-POKEY"), ORANGE, QColor(), AlignLeft), FALSE); 933 case 11 : repaint(pix->draw(16, 28, RoomPix, tr("-POKEY"), ORANGE, QColor(), AlignLeft), FALSE);
934 break; 934 break;
935 case 12 : repaint(pix->draw(38, 28, RoomPix, i18n("\"CLYDE\""), ORANGE, QColor(), AlignLeft), FALSE); 935 case 12 : repaint(pix->draw(38, 28, RoomPix, tr("\"CLYDE\""), ORANGE, QColor(), AlignLeft), FALSE);
936 break; 936 break;
937 case 13 : pts.sprintf("%d", pointScore); 937 case 13 : pts.sprintf("%d", pointScore);
938 repaint(pix->draw(28, 44, RoomPix, pts.data(), WHITE, QColor(), AlignRight), FALSE); 938 repaint(pix->draw(28, 44, RoomPix, pts.data(), WHITE, QColor(), AlignRight), FALSE);
@@ -1096,8 +1096,8 @@ void Referee::play()
1096 emit setLevel(level); 1096 emit setLevel(level);
1097 emit setPoints(points); 1097 emit setPoints(points);
1098 1098
1099 repaint(pix->rect(board->position(monsterhome, 0), i18n("PLAYER ONE")), FALSE); 1099 repaint(pix->rect(board->position(monsterhome, 0), tr("PLAYER ONE")), FALSE);
1100 repaint(pix->rect(board->position(fruithome), i18n("READY!")), FALSE); 1100 repaint(pix->rect(board->position(fruithome), tr("READY!")), FALSE);
1101 1101
1102 timerCount = 0; 1102 timerCount = 0;
1103 QTimer::singleShot(playerDurMS, this, SLOT(ready())); 1103 QTimer::singleShot(playerDurMS, this, SLOT(ready()));
@@ -1114,7 +1114,7 @@ void Referee::ready()
1114 emit setLifes(--lifes); 1114 emit setLifes(--lifes);
1115 gameState.clearBit(Player); 1115 gameState.clearBit(Player);
1116 gameState.clearBit(Init); 1116 gameState.clearBit(Init);
1117 repaint(pix->rect(board->position(monsterhome, 0), i18n("PLAYER ONE")), FALSE); 1117 repaint(pix->rect(board->position(monsterhome, 0), tr("PLAYER ONE")), FALSE);
1118 repaintFigures(); 1118 repaintFigures();
1119 QTimer::singleShot(playerDurMS, this, SLOT(ready())); 1119 QTimer::singleShot(playerDurMS, this, SLOT(ready()));
1120 return; 1120 return;
@@ -1122,12 +1122,12 @@ void Referee::ready()
1122 1122
1123 if (gameState.testBit(Ready)) { 1123 if (gameState.testBit(Ready)) {
1124 gameState.clearBit(Ready); 1124 gameState.clearBit(Ready);
1125 repaint(pix->rect(board->position(fruithome), i18n("READY!")), FALSE); 1125 repaint(pix->rect(board->position(fruithome), tr("READY!")), FALSE);
1126 start(); 1126 start();
1127 } else { 1127 } else {
1128 gameState.setBit(Ready); 1128 gameState.setBit(Ready);
1129 gameState.clearBit(Init); 1129 gameState.clearBit(Init);
1130 repaint(pix->rect(board->position(fruithome), i18n("READY!")), FALSE); 1130 repaint(pix->rect(board->position(fruithome), tr("READY!")), FALSE);
1131 QTimer::singleShot(readyDurMS, this, SLOT(ready())); 1131 QTimer::singleShot(readyDurMS, this, SLOT(ready()));
1132 } 1132 }
1133} 1133}
@@ -1294,7 +1294,7 @@ void Referee::killedPlay()
1294 energizers->at(e)->setOff(); 1294 energizers->at(e)->setOff();
1295 repaint(pix->rect(board->position(energizer, e), EnergizerPix), FALSE); 1295 repaint(pix->rect(board->position(energizer, e), EnergizerPix), FALSE);
1296 } 1296 }
1297 repaint(pix->rect(board->position(fruithome), i18n("GAME OVER")), FALSE); 1297 repaint(pix->rect(board->position(fruithome), tr("GAME OVER")), FALSE);
1298 QTimer::singleShot(gameOverDurMS, this, SLOT(hallOfFame())); 1298 QTimer::singleShot(gameOverDurMS, this, SLOT(hallOfFame()));
1299 } else { 1299 } else {
1300 gameState.clearBit(Init); 1300 gameState.clearBit(Init);