Skip to content

Commit

Permalink
XEEN: Fix clearing Please Wait window after changing maps
Browse files Browse the repository at this point in the history
  • Loading branch information
dreammaster committed Jan 25, 2015
1 parent 3135d1e commit 7b387db
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
13 changes: 11 additions & 2 deletions engines/xeen/scripts.cpp
Expand Up @@ -101,15 +101,17 @@ Scripts::Scripts(XeenEngine *vm) : _vm(vm) {
_animCounter = 0;
_eventSkipped = false;
_mirrorId = -1;
_refreshIcons = false;
}

void Scripts::checkEvents() {
Combat &combat = *_vm->_combat;
// Interface &intf = *_vm->_interface;
Interface &intf = *_vm->_interface;
Map &map = *_vm->_map;
Party &party = *_vm->_party;
Screen &screen = *_vm->_screen;

// int var18 = 0;
_refreshIcons = false;
_itemType = 0;
_var4F = 0;
bool var50 = false;
Expand Down Expand Up @@ -163,6 +165,12 @@ void Scripts::checkEvents() {
}
} while (!_vm->shouldQuit() && _lineNum != -1);

intf._face1State = intf._face2State = 2;
if (_refreshIcons) {
screen.closeWindows();
intf.charIconsPrint(true);
}

// TODO
}

Expand Down Expand Up @@ -669,6 +677,7 @@ void Scripts::cmdReturn(Common::Array<byte> &params) {
void Scripts::cmdSetVar(Common::Array<byte> &params) {
Party &party = *_vm->_party;
uint val;
_refreshIcons = true;

switch (params[0]) {
case 25:
Expand Down
1 change: 1 addition & 0 deletions engines/xeen/scripts.h
Expand Up @@ -147,6 +147,7 @@ class Scripts {
int _lineNum;
int _charIndex;
int _mirrorId;
int _refreshIcons;

int _v2;
int _var4F;
Expand Down

0 comments on commit 7b387db

Please sign in to comment.