Skip to content

Commit

Permalink
TITANIC: Fix Succubus greeting message when there's mail
Browse files Browse the repository at this point in the history
  • Loading branch information
dreammaster committed Dec 2, 2016
1 parent 475289f commit 3c35ae3
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions engines/titanic/core/game_object.cpp
Expand Up @@ -1426,11 +1426,11 @@ void CGameObject::setState1C(bool flag) {
getGameManager()->_gameState._field1C = flag;
}

void CGameObject::addMail(int mailId) {
void CGameObject::addMail(uint destRoomFlags) {
CMailMan *mailMan = getMailMan();
if (mailMan) {
makeDirty();
mailMan->addMail(this, mailId);
mailMan->addMail(this, destRoomFlags);
}
}

Expand Down
2 changes: 1 addition & 1 deletion engines/titanic/core/game_object.h
Expand Up @@ -794,7 +794,7 @@ class CGameObject : public CNamedItem {
/**
* Adds an object to the mail list
*/
void addMail(int mailId);
void addMail(uint destRoomFlags);

/**
* Remove an object from the mail list
Expand Down
3 changes: 2 additions & 1 deletion engines/titanic/npcs/succubus.cpp
Expand Up @@ -526,7 +526,7 @@ bool CSuccUBus::MovieEndMsg(CMovieEndMsg *msg) {
if (msg->_endFrame == _endFrame9) {
bool flag = false;

if (pet && mailExists(petRoomFlags)) {
if (pet && !mailExists(petRoomFlags)) {
CGameObject *mailObject = _v3 && compareRoomNameTo("Titania") ?
findMailByFlags(3, petRoomFlags) :
findMailByFlags(_field140, petRoomFlags);
Expand Down Expand Up @@ -666,6 +666,7 @@ bool CSuccUBus::TurnOn(CTurnOn *msg) {

uint petRoomFlags = pet->getRoomFlags();
if (mailExists(petRoomFlags) && _endFrame1 >= 0)
// Mail canister present
playMovie(_endFrame1, _endFrame1, 0);

_enabled = true;
Expand Down
3 changes: 1 addition & 2 deletions engines/titanic/true_talk/succubus_script.cpp
Expand Up @@ -178,8 +178,7 @@ ScriptChangedResult SuccUBusScript::scriptChanged(const TTroomScript *roomScript
if (id >= 230000 && id <= 230245) {
addResponse(getDialogueId(id));
applyResponse();
}
else if (id >= 70000 && id <= 70243) {
} else if (id >= 70000 && id <= 70243) {
addResponse(id);
applyResponse();
}
Expand Down

0 comments on commit 3c35ae3

Please sign in to comment.