[Scummvm-git-logs] scummvm master -> 3de1ba11b3dff52a5449d6ef9435572238f16958
bonki
bonki at users.noreply.github.com
Fri Mar 2 23:07:34 CET 2018
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
3de1ba11b3 TUCKER: Use Verb enum in more places
Commit: 3de1ba11b3dff52a5449d6ef9435572238f16958
https://github.com/scummvm/scummvm/commit/3de1ba11b3dff52a5449d6ef9435572238f16958
Author: Adrian Frühwirth (bonki at users.noreply.github.com)
Date: 2018-03-02T22:52:41+01:00
Commit Message:
TUCKER: Use Verb enum in more places
Changed paths:
engines/tucker/locations.cpp
engines/tucker/tucker.cpp
diff --git a/engines/tucker/locations.cpp b/engines/tucker/locations.cpp
index dc7e43f..28fca11 100644
--- a/engines/tucker/locations.cpp
+++ b/engines/tucker/locations.cpp
@@ -1350,7 +1350,7 @@ void TuckerEngine::updateSprite_locationNum21() {
void TuckerEngine::execData3PreUpdate_locationNum21() {
if (_xPosCurrent > 460 && _flagsTable[58] == 0 && _nextAction == 0) {
- _currentActionVerb = 0;
+ _currentActionVerb = kVerbWalk;
_pendingActionDelay = 0;
_flagsTable[59] = 1;
_nextAction = 2;
@@ -1754,7 +1754,7 @@ void TuckerEngine::execData3PreUpdate_locationNum28() {
_csDataLoaded = false;
_pendingActionDelay = 0;
_pendingActionIndex = 0;
- _currentActionVerb = 0;
+ _currentActionVerb = kVerbWalk;
}
}
@@ -2356,7 +2356,7 @@ void TuckerEngine::execData3PreUpdate_locationNum53() {
_csDataLoaded = false;
_pendingActionDelay = 0;
_pendingActionIndex = 0;
- _currentActionVerb = 0;
+ _currentActionVerb = kVerbWalk;
}
}
diff --git a/engines/tucker/tucker.cpp b/engines/tucker/tucker.cpp
index 7c0204a..e4d7cde 100644
--- a/engines/tucker/tucker.cpp
+++ b/engines/tucker/tucker.cpp
@@ -247,7 +247,8 @@ void TuckerEngine::resetVariables() {
_pendingActionDelay = 0;
_charPositionFlagNum = 0;
_charPositionFlagValue = 0;
- _actionVerb = kVerbWalk;
+ _actionVerb = _currentActionVerb = _previousActionVerb = kVerbWalk;
+ _actionVerbLocked = false;
_nextAction = 0;
_selectedObjectNum = 0;
_selectedObjectType = 0;
@@ -255,7 +256,6 @@ void TuckerEngine::resetVariables() {
_actionObj1Type = _actionObj2Type = 0;
_actionObj1Num = _actionObj2Num = 0;
_actionRequiresTwoObjects = false;
- _actionVerbLocked = false;
_actionPosX = 0;
_actionPosY = 0;
_selectedObjectLocationMask = false;
@@ -302,8 +302,6 @@ void TuckerEngine::resetVariables() {
memset(_characterAnimationsTable, 0, sizeof(_characterAnimationsTable));
memset(_characterStateTable, 0, sizeof(_characterStateTable));
_backgroundSprOffset = 0;
- _currentActionVerb = 0;
- _previousActionVerb = 0;
_mainSpritesBaseOffset = 0;
_currentSpriteAnimationLength = 0;
_currentSpriteAnimationFrame = 0;
@@ -831,7 +829,7 @@ void TuckerEngine::updateMouseState() {
void TuckerEngine::updateCharPositionHelper() {
setCursorState(kCursorStateDisabledHidden );
_charSpeechSoundCounter = kDefaultCharSpeechSoundCounter;
- _currentActionVerb = 0;
+ _currentActionVerb = kVerbWalk;
startSpeechSound(_speechSoundNum, _speechVolume);
int pos = getPositionForLine(_speechSoundNum, _characterSpeechDataPtr);
_characterSpeechDataPtr += pos;
@@ -855,7 +853,7 @@ void TuckerEngine::updateCharPosition() {
}
if (_currentActionObj1Num == 259) {
handleSpecialObjectSelectionSequence();
- _currentActionVerb = 0;
+ _currentActionVerb = kVerbWalk;
return;
}
_speechSoundNum = _currentActionObj1Num;
@@ -897,7 +895,7 @@ void TuckerEngine::updateCharPosition() {
return;
} else if (_currentActionObj1Num == 91) {
handleSpecialObjectSelectionSequence();
- _currentActionVerb = 0;
+ _currentActionVerb = kVerbWalk;
return;
}
break;
@@ -945,7 +943,7 @@ void TuckerEngine::updateCharPosition() {
}
if (!skip) {
playSpeechForAction(_currentActionVerb);
- _currentActionVerb = 0;
+ _currentActionVerb = kVerbWalk;
return;
}
assert(action);
@@ -969,7 +967,7 @@ void TuckerEngine::updateCharPosition() {
_characterSoundFxDelayCounter = action->_fxDelay;
_characterSoundFxNum = action->_fxNum;
_previousActionVerb = _currentActionVerb;
- _currentActionVerb = 0;
+ _currentActionVerb = kVerbWalk;
}
void TuckerEngine::updateFlagsForCharPosition() {
@@ -1143,7 +1141,7 @@ void TuckerEngine::updateCursor() {
} else {
_actionVerbLocked = false;
_actionRequiresTwoObjects = false;
- _currentActionVerb = 0;
+ _currentActionVerb = kVerbWalk;
setSelectedObjectKey();
}
}
@@ -3683,7 +3681,7 @@ void TuckerEngine::handleMouseClickOnInventoryObject() {
_actionCharacterNum = 99;
setCursorState(kCursorStateDisabledHidden);
_charSpeechSoundCounter = kDefaultCharSpeechSoundCounter;
- _currentActionVerb = 0;
+ _currentActionVerb = kVerbWalk;
_speechSoundNum = 2235;
startSpeechSound(_speechSoundNum, _speechVolume);
_characterSpeechDataPtr = _ptTextBuf + getPositionForLine(_speechSoundNum, _ptTextBuf);
More information about the Scummvm-git-logs
mailing list