diff options
author | Filippos Karapetis | 2013-08-19 03:08:11 +0300 |
---|---|---|
committer | Filippos Karapetis | 2013-08-19 03:08:58 +0300 |
commit | d531484350291f037c896c05fdaf691231ef3c04 (patch) | |
tree | be07e362767f156842dac5353522dd7b4b16c555 /engines/drascula/actors.cpp | |
parent | d17dcc1cbed57b0c6861b5b0c91106aa26aa6b83 (diff) | |
download | scummvm-rg350-d531484350291f037c896c05fdaf691231ef3c04.tar.gz scummvm-rg350-d531484350291f037c896c05fdaf691231ef3c04.tar.bz2 scummvm-rg350-d531484350291f037c896c05fdaf691231ef3c04.zip |
DRASCULA: Some renaming. Also, get rid of some extraneous globals
This removes the superfluous talkHeight, talkWidth and timeDiff
variables. It also changes _loadedDifferentChapter to be a boolean
Diffstat (limited to 'engines/drascula/actors.cpp')
-rw-r--r-- | engines/drascula/actors.cpp | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/engines/drascula/actors.cpp b/engines/drascula/actors.cpp index 9d5d6550fa..e0983809fa 100644 --- a/engines/drascula/actors.cpp +++ b/engines/drascula/actors.cpp @@ -135,7 +135,7 @@ void DrasculaEngine::startWalking() { else characterMoved = 0; } - startTime = getTime(); + _startTime = getTime(); } void DrasculaEngine::moveCharacters() { @@ -239,7 +239,7 @@ void DrasculaEngine::moveCharacters() { factor_red[curY + curHeight], frontSurface, screenSurface); } } else if (characterMoved == 1) { - curPos[0] = _frameX[num_frame]; + curPos[0] = _frameX[_characterFrame]; curPos[1] = frame_y + DIF_MASK_HARE; curPos[2] = curX; curPos[3] = curY; @@ -369,13 +369,11 @@ void DrasculaEngine::quadrant_4() { } void DrasculaEngine::increaseFrameNum() { - timeDiff = getTime() - startTime; - - if (timeDiff >= 6) { - startTime = getTime(); - num_frame++; - if (num_frame == 6) - num_frame = 0; + if (getTime() - _startTime >= 6) { + _startTime = getTime(); + _characterFrame++; + if (_characterFrame == 6) + _characterFrame = 0; if (curDirection == kDirectionUp) { curX -= stepX; |