HOPKINS: Remove a couple of useless variables and associated dead code

This commit is contained in:
Strangerke 2013-02-19 07:54:57 +01:00
parent 38e9dbfe3f
commit 72f7421b6d
5 changed files with 2 additions and 15 deletions

View File

@ -327,14 +327,6 @@ void FontManager::box(int idx, int messageId, const Common::String &filename, in
_text[idx]._pos.x = i;
textPosX = _vm->_eventsManager._startPos.x + i;
} else {
if (_vm->_globals.nbrligne == (SCREEN_WIDTH - 1)) {
while (_vm->_globals._boxWidth + textPosX > 638 && textPosX > -2)
textPosX -= 2;
}
if (_vm->_globals.nbrligne == (SCREEN_WIDTH * 2)) {
while (_vm->_globals._boxWidth + textPosX > 1278 && textPosX > -2)
textPosX -= 2;
}
_text[idx]._pos.x = textPosX;
}
}

View File

@ -107,7 +107,6 @@ Globals::Globals() {
_oldDirectionSpriteIdx = 59;
_lastDirection = DIR_NONE;
NUM_FICHIER_OBJ = 0;
nbrligne = 0;
_boxWidth = 0;
_objectWidth = _objectHeight = 0;
_catalogPos = 0;
@ -238,7 +237,6 @@ void Globals::clearAll() {
for (int idx = 0; idx < 6; ++idx)
CACHE_BANQUE[idx] = g_PTRNUL;
nbrligne = 80;
INIT_ANIM();
_boxWidth = 0;

View File

@ -307,7 +307,6 @@ public:
bool NOMARCHE;
int iRegul;
byte *BUF_ZONE;
int nbrligne; // Useless variable?
BqeAnimItem Bqe_Anim[35];
byte *SPRITE_ECRAN;
byte *PERSO;

View File

@ -2196,7 +2196,6 @@ void HopkinsEngine::playEnding() {
void HopkinsEngine::displayPlane() {
_soundManager.WSOUND(28);
_globals.iRegul = 1;
_globals.nbrligne = SCREEN_WIDTH;
_graphicsManager.lockScreen();
_graphicsManager.clearScreen();
_graphicsManager.unlockScreen();

View File

@ -94,10 +94,9 @@ struct RouteItem {
int16 _X;
int16 _Y;
Directions _dir;
int16 _unk;
bool isValid() const { return _X != -1 || _Y != -1; }
void invalidate() { _X = _Y = _unk = -1; _dir = DIR_NONE; }
void set(int16 X, int16 Y, Directions dir) { _X = X; _Y = Y; _dir = dir; _unk = 0; }
void invalidate() { _X = _Y = -1; _dir = DIR_NONE; }
void set(int16 X, int16 Y, Directions dir) { _X = X; _Y = Y; _dir = dir; }
};