Skip to content

Commit

Permalink
HOPKINS: Some renaming in TalkManager
Browse files Browse the repository at this point in the history
  • Loading branch information
Strangerke committed Apr 1, 2013
1 parent dc2d879 commit 7036047
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 16 deletions.
4 changes: 2 additions & 2 deletions engines/hopkins/objects.cpp
Expand Up @@ -2075,9 +2075,9 @@ void ObjectsManager::PARADISE() {
_vm->_eventsManager->refreshScreenAndEvents();
_vm->_graphicsManager->_scrollStatus = 0;
}
_vm->_talkManager->REPONSE(_vm->_globals->_saveData->_data[svLastZoneNum], _vm->_globals->_saveData->_data[svLastMouseCursor]);
_vm->_talkManager->handleAnswer(_vm->_globals->_saveData->_data[svLastZoneNum], _vm->_globals->_saveData->_data[svLastMouseCursor]);
} else {
_vm->_talkManager->REPONSE2(_vm->_globals->_saveData->_data[svLastZoneNum], _vm->_globals->_saveData->_data[svLastMouseCursor]);
_vm->_talkManager->handleForestAnswser(_vm->_globals->_saveData->_data[svLastZoneNum], _vm->_globals->_saveData->_data[svLastMouseCursor]);
}
_vm->_eventsManager->changeMouseCursor(4);
if (_zoneNum != -1 && _zoneNum != 0 && !_vm->_linesManager->_zone[_zoneNum]._enabledFl) {
Expand Down
16 changes: 8 additions & 8 deletions engines/hopkins/talk.cpp
Expand Up @@ -368,7 +368,7 @@ int TalkManager::dialogAnswer(int idx, bool animatedFl) {
if (curVal)
_vm->_objectsManager->stopBobAnimation(curVal);
} else {
VISU_PARLE();
dialogAnim();
}

bool displayedTxtFl = false;
Expand Down Expand Up @@ -467,7 +467,7 @@ void TalkManager::searchCharacterPalette(int startIdx, bool dark) {
void TalkManager::dialogWait() {
for (int idx = 26; idx <= 30; ++idx) {
if (_vm->_animationManager->_animBqe[idx]._enabledFl)
BOB_VISU_PARLE(idx);
displayBobDialogAnim(idx);
}
}

Expand Down Expand Up @@ -586,14 +586,14 @@ int TalkManager::countBoxLines(int idx, const Common::String &file) {
return lineCount;
}

void TalkManager::VISU_PARLE() {
void TalkManager::dialogAnim() {
for (int idx = 21; idx <= 25; ++idx) {
if (_vm->_animationManager->_animBqe[idx]._enabledFl)
BOB_VISU_PARLE(idx);
displayBobDialogAnim(idx);
}
}

void TalkManager::BOB_VISU_PARLE(int idx) {
void TalkManager::displayBobDialogAnim(int idx) {
_vm->_objectsManager->_priorityFl = true;
if (!_vm->_objectsManager->_bob[idx]._bobMode) {
_vm->_objectsManager->resetBob(idx);
Expand Down Expand Up @@ -754,7 +754,7 @@ bool TalkManager::searchCharacterAnim(int idx, const byte *bufPerso, int animId,
return result;
}

void TalkManager::REPONSE(int zone, int verb) {
void TalkManager::handleAnswer(int zone, int verb) {
byte zoneObj = zone;
byte verbObj = verb;

Expand Down Expand Up @@ -853,7 +853,7 @@ void TalkManager::REPONSE(int zone, int verb) {
return;
}

void TalkManager::REPONSE2(int zone, int verb) {
void TalkManager::handleForestAnswser(int zone, int verb) {
int indx = 0;
if (verb != 5 || _vm->_globals->_saveData->_data[svLastObjectIndex] != 4)
return;
Expand Down Expand Up @@ -1011,7 +1011,7 @@ void TalkManager::animateObject(const Common::String &filename) {
_vm->_globals->_actionMoveTo = false;
_vm->_objectsManager->_zoneNum = -1;
initCharacterAnim();
VISU_PARLE();
dialogAnim();
dialogWait();
_vm->_graphicsManager->initScreen(screenFilename, 2, true);
_vm->_globals->_freezeCharacterFl = true;
Expand Down
10 changes: 4 additions & 6 deletions engines/hopkins/talk.h
Expand Up @@ -57,9 +57,8 @@ class TalkManager {
void clearCharacterAnim();
bool searchCharacterAnim(int idx, const byte *bufPerso, int animId, int bufferSize);
int countBoxLines(int idx, const Common::String &file);

void VISU_PARLE();
void BOB_VISU_PARLE(int idx);
void dialogAnim();
void displayBobDialogAnim(int idx);

public:
byte *_characterAnim;
Expand All @@ -70,9 +69,8 @@ class TalkManager {
void startStaticCharacterDialogue(const Common::String &filename);
void startAnimatedCharacterDialogue(const Common::String &filename);
void animateObject(const Common::String &filename);

void REPONSE(int zone, int verb);
void REPONSE2(int zone, int verb);
void handleAnswer(int zone, int verb);
void handleForestAnswser(int zone, int verb);
};

} // End of namespace Hopkins
Expand Down

0 comments on commit 7036047

Please sign in to comment.