MOHAWK: Move running the card leave script to the RivenCard destructor
This commit is contained in:
parent
9b2c90c0b3
commit
aa0c89da03
5 changed files with 54 additions and 20 deletions
|
@ -387,9 +387,6 @@ void MohawkEngine_Riven::changeToCard(uint16 dest) {
|
|||
}
|
||||
}
|
||||
|
||||
if (_card)
|
||||
_card->runScript(kCardLeaveScript);
|
||||
|
||||
delete _card;
|
||||
_card = new RivenCard(this, dest);
|
||||
|
||||
|
@ -400,9 +397,6 @@ void MohawkEngine_Riven::refreshCard() {
|
|||
// Clear any timer still floating around
|
||||
removeTimer();
|
||||
|
||||
_gfx->clearWaterEffects();
|
||||
_video->stopVideos();
|
||||
|
||||
_card->open();
|
||||
|
||||
if (_showHotspots)
|
||||
|
@ -838,7 +832,7 @@ void MohawkEngine_Riven::addZipVisitedCard(uint16 cardId, uint16 cardNameId) {
|
|||
ZipMode zip;
|
||||
zip.name = cardName;
|
||||
zip.id = cardId;
|
||||
if (!(Common::find(_zipModeData.begin(), _zipModeData.end(), zip) != _zipModeData.end()))
|
||||
if (Common::find(_zipModeData.begin(), _zipModeData.end(), zip) == _zipModeData.end())
|
||||
_zipModeData.push_back(zip);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue