Commit 79e276c8 authored by Ian Wadham's avatar Ian Wadham

Change the version number. Turn off debugging output from the game-engine.

svn path=/trunk/KDE/kdegames/kgoldrunner/; revision=1150877
parent ed4f986b
......@@ -680,19 +680,15 @@ bool KGoldrunner::identifyMoveAction (QKeyEvent * event, bool pressed)
result = true;
if ((ACTION ("move_left"))->shortcuts().contains(keystroke)) {
kDebug() << "move_left" << "pressed" << pressed; // IDW
game->kbControl (LEFT, pressed);
}
else if ((ACTION ("move_right"))->shortcuts().contains(keystroke)) {
kDebug() << "move_right" << "pressed" << pressed; // IDW
game->kbControl (RIGHT, pressed);
}
else if ((ACTION ("move_up"))->shortcuts().contains(keystroke)) {
kDebug() << "move_up" << "pressed" << pressed; // IDW
game->kbControl (UP, pressed);
}
else if ((ACTION ("move_down"))->shortcuts().contains(keystroke)) {
kDebug() << "move_down" << "pressed" << pressed; // IDW
game->kbControl (DOWN, pressed);
}
else {
......
......@@ -61,7 +61,7 @@ KGrLevelPlayer::KGrLevelPlayer (QObject * parent, KRandomSequence * pRandomGen)
{
t.start(); // IDW
dbgLevel = 2;
dbgLevel = 0;
}
int KGrLevelPlayer::playerCount = 0;
......@@ -317,8 +317,6 @@ void KGrLevelPlayer::startDigging (Direction diggingDirection)
t.elapsed()}; // IDW test
(* thisBrick) = brick;
dugBricks.append (thisBrick);
// kDebug() << "DIG" << thisBrick->id << thisBrick->countdown
// << "time" << (t.elapsed() - thisBrick->startTime);
}
}
......@@ -334,22 +332,16 @@ void KGrLevelPlayer::processDugBricks (const int scaledTime)
dugBrick->cycleTimeLeft += digCycleTime;
if (--dugBrick->countdown == digClosingCycles) {
// Start the brick-closing animation (non-repeating).
// kDebug() << "Brick" << dugBrick->digI << dugBrick->digJ <<
// "count" << dugBrick->countdown;
emit startAnimation (dugBrick->id, false,
dugBrick->digI, dugBrick->digJ,
(digClosingCycles * digCycleTime),
STAND, CLOSE_BRICK);
}
if (dugBrick->countdown == digKillingTime) {
// kDebug() << "Brick" << dugBrick->digI << dugBrick->digJ <<
// "count" << dugBrick->countdown;
// Close the hole and maybe capture the hero or an enemy.
grid->changeCellAt (dugBrick->digI, dugBrick->digJ, BRICK);
}
if (dugBrick->countdown <= 0) {
// kDebug() << "DIG" << dugBrick->id << dugBrick->countdown
// << "time" << (t.elapsed() - dugBrick->startTime);
// Dispose of the dug brick and remove it from the list.
emit deleteSprite (dugBrick->id);
delete dugBrick;
......@@ -361,7 +353,6 @@ void KGrLevelPlayer::processDugBricks (const int scaledTime)
void KGrLevelPlayer::prepareToPlay()
{
kDebug() << "Set mouse to:" << targetI << targetJ;
if ((controlMode == MOUSE) || (controlMode == LAPTOP)) {
emit setMousePos (targetI, targetJ);
}
......@@ -476,7 +467,6 @@ void KGrLevelPlayer::setDirectionByKey (const Direction dirn,
int sign = pressed ? +1 : -1;
dX = dX + sign * movement [dirn][X];
dY = dY + sign * movement [dirn][Y];
kDebug() << "dX" << dX << "dY" << dY; // IDW
}
}
}
......@@ -500,7 +490,7 @@ Direction KGrLevelPlayer::getDirection (int heroI, int heroJ)
// (if there are multi-key holds) into either horizontal or vertical.
direction = setDirectionByDelta (dX, dY, heroI, heroJ);
/* dbe2 IDW*/ dbe "T %04d recIndex %03d delta [%02d, %02d] "
dbe2 "T %04d recIndex %03d delta [%02d, %02d] "
"hero at [%02d, %02d] direction %d\n",
T, recIndex - 1, dX, dY, heroI, heroJ, direction);
}
......@@ -512,26 +502,20 @@ Direction KGrLevelPlayer::setDirectionByDelta (const int di, const int dj,
const int heroI, const int heroJ)
{
Direction dirn = STAND;
kDebug() << "di" << di << "dj" << dj;
if ((dj > 0) && (grid->heroMoves (heroI, heroJ) & dFlag [DOWN])) {
// kDebug() << "Go down";
dirn = DOWN;
}
else if ((dj < 0) && (grid->heroMoves (heroI, heroJ) & dFlag [UP])) {
// kDebug() << "Go up";
dirn = UP;
}
else if (di > 0) {
// kDebug() << "Go right";
dirn = RIGHT;
}
else if (di < 0) {
// kDebug() << "Go left";
dirn = LEFT;
}
else { // Note: di is zero, but dj is not necessarily zero.
// kDebug() << "Stand";
dirn = STAND;
}
return dirn;
......@@ -788,7 +772,6 @@ void KGrLevelPlayer::tick (bool missed, int scaledTime)
// IDW Need a better condition here. (playState == Playing) was to stop
// IDW the HOLD_KEY option recording a whole lot of STAND directions before
// IDW the first key is pressed. (direction != NO_DIRECTION) is previous code.
kDebug() << "Record playState" << playState << "dirn" << direction;
record (2, DIRECTION_CODE + direction);
}
}
......
......@@ -27,7 +27,7 @@ static const char description[] =
I18N_NOOP ("KGoldrunner is a game of action and puzzle solving");
// The intention is to keep the KGoldrunner version number in line with KDE.
static const char version[] = "4.3";
static const char version[] = "4.6";
static bool gameDataOK();
static void addCredits (KAboutData & about);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment