mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-18 15:48:48 +00:00
HOPKINS: Refactor handleGoto and handleIf, some renaming
This commit is contained in:
parent
8c1f422bd6
commit
4ab60c43c0
@ -280,7 +280,7 @@ void ComputerManager::showComputer(ComputerEnum mode) {
|
||||
readText(9);
|
||||
if (v12 == 54) {
|
||||
readText(10);
|
||||
_vm->_globals.SAUVEGARDE->data[svField270] = 4;
|
||||
_vm->_globals._saveData->data[svField270] = 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -306,9 +306,9 @@ void ComputerManager::showComputer(ComputerEnum mode) {
|
||||
_vm->_eventsManager.mouseOff();
|
||||
}
|
||||
if (mode == 1)
|
||||
_vm->_globals.SORTIE = 13;
|
||||
_vm->_globals._exitId = 13;
|
||||
if ((uint16)(mode - 2) <= 1u)
|
||||
_vm->_globals.SORTIE = 14;
|
||||
_vm->_globals._exitId = 14;
|
||||
|
||||
_vm->_graphicsManager.RESET_SEGMENT_VESA();
|
||||
}
|
||||
|
@ -189,7 +189,7 @@ void DialogsManager::showOptionsDialog() {
|
||||
}
|
||||
|
||||
if (mousePos.x >= _vm->_graphicsManager.ofscroll + 175 && mousePos.y > 285 && mousePos.x <= _vm->_graphicsManager.ofscroll + 281 && mousePos.y <= 310) {
|
||||
_vm->_globals.SORTIE = 300;
|
||||
_vm->_globals._exitId = 300;
|
||||
doneFlag = true;
|
||||
}
|
||||
if (mousePos.x >= _vm->_graphicsManager.ofscroll + 355 && mousePos.y > 285 && mousePos.x <= _vm->_graphicsManager.ofscroll + 490 && mousePos.y <= 310)
|
||||
@ -406,22 +406,22 @@ LABEL_7:
|
||||
v20 = true;
|
||||
if (!v20) {
|
||||
_vm->_scriptManager.TRAVAILOBJET = true;
|
||||
_vm->_globals.SAUVEGARDE->data[svField3] = _vm->_globals._curObjectIndex;
|
||||
_vm->_globals.SAUVEGARDE->data[svField8] = _vm->_globals._inventory[v13];
|
||||
_vm->_globals.SAUVEGARDE->data[svField9] = _vm->_eventsManager._mouseCursorId;
|
||||
_vm->_globals._saveData->data[svField3] = _vm->_globals._curObjectIndex;
|
||||
_vm->_globals._saveData->data[svField8] = _vm->_globals._inventory[v13];
|
||||
_vm->_globals._saveData->data[svField9] = _vm->_eventsManager._mouseCursorId;
|
||||
_vm->_objectsManager.OPTI_OBJET();
|
||||
_vm->_scriptManager.TRAVAILOBJET = false;
|
||||
|
||||
if (_vm->_soundManager._voiceOffFl) {
|
||||
do
|
||||
_vm->_eventsManager.VBL();
|
||||
while (!_vm->_globals.SORTIE && _vm->_eventsManager.getMouseButton() != 1);
|
||||
while (!_vm->_globals._exitId && _vm->_eventsManager.getMouseButton() != 1);
|
||||
_vm->_fontManager.hideText(9);
|
||||
}
|
||||
if (_vm->_globals.SORTIE) {
|
||||
if (_vm->_globals.SORTIE == 2)
|
||||
if (_vm->_globals._exitId) {
|
||||
if (_vm->_globals._exitId == 2)
|
||||
v20 = true;
|
||||
_vm->_globals.SORTIE = 0;
|
||||
_vm->_globals._exitId = 0;
|
||||
if (!v20) {
|
||||
_inventBuf2 = _vm->_globals.freeMemory(_inventBuf2);
|
||||
_vm->_dialogsManager._inventWin1 = _vm->_globals.freeMemory(_vm->_dialogsManager._inventWin1);
|
||||
@ -437,13 +437,12 @@ LABEL_7:
|
||||
if (v20)
|
||||
break;
|
||||
_vm->_eventsManager.VBL();
|
||||
if ((uint16)(_vm->_globals.ECRAN - 35) <= 5u)
|
||||
if ((uint16)(_vm->_globals._screenId - 35) <= 5u)
|
||||
_vm->_objectsManager.SPECIAL_JEU();
|
||||
}
|
||||
_vm->_fontManager.hideText(9);
|
||||
if (_inventDisplayedFl) {
|
||||
_inventDisplayedFl = false;
|
||||
// v9 = 114;
|
||||
_vm->_graphicsManager.SCOPY(_vm->_graphicsManager._vesaScreen, v19, 114, v18, v17, _vm->_graphicsManager._vesaBuffer, v19, 114);
|
||||
_vm->_graphicsManager.Ajoute_Segment_Vesa(v19, 114, v19 + v18, v18 + 114);
|
||||
_vm->_objectsManager.BOBTOUS = true;
|
||||
@ -494,20 +493,20 @@ void DialogsManager::inventAnim() {
|
||||
_vm->_objectsManager.I_old_x = v0;
|
||||
}
|
||||
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField357] == 1) {
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField353] == 1)
|
||||
if (_vm->_globals._saveData->data[svField357] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField353] == 1)
|
||||
_vm->_graphicsManager.Affiche_Perfect(_vm->_graphicsManager._vesaBuffer, _vm->_globals.TETE, 832, 325, 0, 0, 0, 0);
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField355] == 1)
|
||||
if (_vm->_globals._saveData->data[svField355] == 1)
|
||||
_vm->_graphicsManager.Affiche_Perfect(_vm->_graphicsManager._vesaBuffer, _vm->_globals.TETE, 866, 325, 1, 0, 0, 0);
|
||||
_vm->_graphicsManager.Ajoute_Segment_Vesa(532, 25, 560, 60);
|
||||
_vm->_graphicsManager.Ajoute_Segment_Vesa(566, 25, 594, 60);
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField356] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField356] == 1) {
|
||||
_vm->_graphicsManager.Affiche_Perfect(_vm->_graphicsManager._vesaBuffer, _vm->_globals.TETE, 832, 325, 0, 0, 0, 0);
|
||||
_vm->_graphicsManager.Ajoute_Segment_Vesa(532, 25, 560, 60);
|
||||
}
|
||||
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField354] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField354] == 1) {
|
||||
_vm->_graphicsManager.Affiche_Perfect(_vm->_graphicsManager._vesaBuffer, _vm->_globals.TETE, 832, 325, 0, 0, 0, 0);
|
||||
_vm->_graphicsManager.Ajoute_Segment_Vesa(532, 25, 560, 60);
|
||||
}
|
||||
|
@ -144,12 +144,12 @@ Globals::Globals() {
|
||||
_catalogSize = 0;
|
||||
_newObjectFl = false;
|
||||
iRegul = 0;
|
||||
SORTIE = 0;
|
||||
_exitId = 0;
|
||||
PLANX = PLANY = 0;
|
||||
PLANI = 0;
|
||||
PERSO = 0;
|
||||
PASSWORD = false;
|
||||
ECRAN = 0;
|
||||
_screenId = 0;
|
||||
NOSPRECRAN = false;
|
||||
OLD_ECRAN = 0;
|
||||
Max_Propre_Gen = 0;
|
||||
@ -199,7 +199,7 @@ Globals::Globals() {
|
||||
CACHE_BANQUE[6] = NULL;
|
||||
texte_tmp = NULL;
|
||||
SPRITE_ECRAN = NULL;
|
||||
SAUVEGARDE = NULL;
|
||||
_saveData = NULL;
|
||||
BUFFERTAPE = NULL;
|
||||
essai0 = NULL;
|
||||
essai1 = NULL;
|
||||
@ -262,7 +262,7 @@ Globals::~Globals() {
|
||||
freeMemory(CACHE_BANQUE[6]);
|
||||
freeMemory(texte_tmp);
|
||||
freeMemory(SPRITE_ECRAN);
|
||||
freeMemory((byte *)SAUVEGARDE);
|
||||
freeMemory((byte *)_saveData);
|
||||
freeMemory(BUFFERTAPE);
|
||||
freeMemory(inventaire2);
|
||||
freeMemory(GESTE);
|
||||
@ -367,7 +367,7 @@ void Globals::clearAll() {
|
||||
_vm->_dialogsManager._inventBuf2 = g_PTRNUL;
|
||||
COUCOU = g_PTRNUL;
|
||||
SPRITE_ECRAN = g_PTRNUL;
|
||||
SAUVEGARDE = (Sauvegarde *)g_PTRNUL;
|
||||
_saveData = (Sauvegarde *)g_PTRNUL;
|
||||
_curObjectIndex = 0;
|
||||
|
||||
for (int idx = 0; idx < 105; ++idx) {
|
||||
@ -403,8 +403,8 @@ void Globals::clearAll() {
|
||||
texte_tmp = g_PTRNUL;
|
||||
BUFFERTAPE = allocMemory(85000);
|
||||
|
||||
SAUVEGARDE = (Sauvegarde *)malloc(sizeof(Sauvegarde));
|
||||
memset(SAUVEGARDE, 0, sizeof(Sauvegarde));
|
||||
_saveData = (Sauvegarde *)malloc(sizeof(Sauvegarde));
|
||||
memset(_saveData, 0, sizeof(Sauvegarde));
|
||||
|
||||
essai0 = (int16 *)BUFFERTAPE;
|
||||
essai1 = (int16 *)(BUFFERTAPE + 25000);
|
||||
|
@ -371,7 +371,7 @@ public:
|
||||
int texte_long;
|
||||
int TEXTE_FORMATE;
|
||||
byte *SPRITE_ECRAN;
|
||||
Sauvegarde *SAUVEGARDE;
|
||||
Sauvegarde *_saveData;
|
||||
byte *BUFFERTAPE;
|
||||
int16 *essai0;
|
||||
int16 *essai1;
|
||||
@ -401,12 +401,12 @@ public:
|
||||
uint32 _catalogSize;
|
||||
int iRegul;
|
||||
bool BPP_NOAFF;
|
||||
int SORTIE;
|
||||
int _exitId;
|
||||
int PLANX, PLANY;
|
||||
int PLANI;
|
||||
bool PASSWORD; // CHECKME: Useless variable?
|
||||
bool NOSPRECRAN;
|
||||
int ECRAN;
|
||||
int _screenId;
|
||||
int OLD_ECRAN;
|
||||
int fmusic;
|
||||
int Max_Propre;
|
||||
|
@ -1971,9 +1971,9 @@ void GraphicsManager::OPTI_INI(const Common::String &file, int mode) {
|
||||
return;
|
||||
|
||||
if (dataVal1 == 2)
|
||||
dataOffset = _vm->_scriptManager.Control_Goto((ptr + 20 * dataOffset));
|
||||
dataOffset = _vm->_scriptManager.handleGoto((ptr + 20 * dataOffset));
|
||||
if (dataVal1 == 3)
|
||||
dataOffset = _vm->_scriptManager.Control_If(ptr, dataOffset);
|
||||
dataOffset = _vm->_scriptManager.handleIf(ptr, dataOffset);
|
||||
if (dataOffset == -1)
|
||||
error("Error, defective IFF");
|
||||
if (dataVal1 == 1 || dataVal1 == 4)
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -61,12 +61,12 @@ int MenuManager::MENU() {
|
||||
_vm->_eventsManager._breakoutFl = false;
|
||||
_vm->_globals._disableInventFl = true;
|
||||
_vm->_globals.FLAG_VISIBLE = false;
|
||||
_vm->_globals.SORTIE = 0;
|
||||
_vm->_globals._exitId = 0;
|
||||
|
||||
for (int idx = 0; idx < 31; ++idx)
|
||||
_vm->_globals._inventory[idx] = 0;
|
||||
|
||||
memset(_vm->_globals.SAUVEGARDE, 0, 2000);
|
||||
memset(_vm->_globals._saveData, 0, 2000);
|
||||
_vm->_objectsManager.addObject(14);
|
||||
frame5Index = 0;
|
||||
frame4Index = 0;
|
||||
@ -191,14 +191,14 @@ int MenuManager::MENU() {
|
||||
_vm->_eventsManager.VBL();
|
||||
_vm->_eventsManager.delay(200);
|
||||
|
||||
_vm->_globals.SORTIE = -1;
|
||||
_vm->_globals._exitId = -1;
|
||||
_vm->_dialogsManager.showLoadGame();
|
||||
|
||||
if (_vm->_globals.SORTIE != -1) {
|
||||
result = _vm->_globals.SORTIE;
|
||||
if (_vm->_globals._exitId != -1) {
|
||||
result = _vm->_globals._exitId;
|
||||
break;
|
||||
}
|
||||
_vm->_globals.SORTIE = 0;
|
||||
_vm->_globals._exitId = 0;
|
||||
}
|
||||
|
||||
if (menuIndex != OPTIONS)
|
||||
|
@ -1735,7 +1735,7 @@ void ObjectsManager::GOHOME() {
|
||||
setSpriteIndex(0, _vm->_globals.g_old_sens + 59);
|
||||
_vm->_globals.ACTION_SENS = 0;
|
||||
if (_vm->_globals.GOACTION)
|
||||
v54 = _vm->_globals.SAUVEGARDE->data[svField2];
|
||||
v54 = _vm->_globals._saveData->data[svField2];
|
||||
else
|
||||
v54 = NUMZONE;
|
||||
_vm->_globals.chemin = (int16 *)g_PTRNUL;
|
||||
@ -2076,7 +2076,7 @@ LABEL_153:
|
||||
|
||||
if (nouveau_x == -1 && v48 == -1) {
|
||||
if (_vm->_globals.GOACTION)
|
||||
v49 = _vm->_globals.SAUVEGARDE->data[svField2];
|
||||
v49 = _vm->_globals._saveData->data[svField2];
|
||||
else
|
||||
v49 = NUMZONE;
|
||||
setSpriteIndex(0, _vm->_globals.g_old_sens + 59);
|
||||
@ -2449,7 +2449,7 @@ void ObjectsManager::PLAN_BETA() {
|
||||
_vm->_graphicsManager.NOFADE = false;
|
||||
_vm->_globals.NOMARCHE = false;
|
||||
_spritePtr = g_PTRNUL;
|
||||
_vm->_globals.SORTIE = 0;
|
||||
_vm->_globals._exitId = 0;
|
||||
_vm->_globals.AFFLI = false;
|
||||
_vm->_globals.AFFIVBL = false;
|
||||
_vm->_globals.NOT_VERIF = 1;
|
||||
@ -2502,15 +2502,15 @@ void ObjectsManager::PLAN_BETA() {
|
||||
do {
|
||||
v5 = _vm->_eventsManager.getMouseButton();
|
||||
if (v5) {
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField170] == 1 && !_vm->_globals.SAUVEGARDE->data[svField171]) {
|
||||
_vm->_globals.SAUVEGARDE->data[svField171] = 1;
|
||||
if (_vm->_globals._saveData->data[svField170] == 1 && !_vm->_globals._saveData->data[svField171]) {
|
||||
_vm->_globals._saveData->data[svField171] = 1;
|
||||
_vm->_globals.NOPARLE = true;
|
||||
_vm->_talkManager.PARLER_PERSO("APPEL1.pe2");
|
||||
_vm->_globals.NOPARLE = false;
|
||||
v5 = 0;
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField80] == 1 && !_vm->_globals.SAUVEGARDE->data[svField172]) {
|
||||
_vm->_globals.SAUVEGARDE->data[svField172] = 1;
|
||||
if (_vm->_globals._saveData->data[svField80] == 1 && !_vm->_globals._saveData->data[svField172]) {
|
||||
_vm->_globals._saveData->data[svField172] = 1;
|
||||
_vm->_globals.NOPARLE = true;
|
||||
_vm->_talkManager.PARLER_PERSO("APPEL2.pe2");
|
||||
_vm->_globals.NOPARLE = false;
|
||||
@ -2528,7 +2528,7 @@ void ObjectsManager::PLAN_BETA() {
|
||||
PARADISE();
|
||||
_vm->_eventsManager.VBL();
|
||||
|
||||
if (_vm->_globals.SORTIE)
|
||||
if (_vm->_globals._exitId)
|
||||
v1 = 1;
|
||||
} while (!_vm->shouldQuit() && v1 != 1);
|
||||
|
||||
@ -2580,35 +2580,35 @@ void ObjectsManager::handleLeftButton() {
|
||||
_vm->_dialogsManager.showInventory();
|
||||
_vm->_dialogsManager._inventFl = false;
|
||||
_vm->_eventsManager._gameKey = KEY_NONE;
|
||||
if (!_vm->_globals.SORTIE) {
|
||||
if (!_vm->_globals._exitId) {
|
||||
_vm->_dialogsManager._inventFl = false;
|
||||
_vm->_eventsManager._mouseCursorId = v1;
|
||||
}
|
||||
return;
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField354] == 1
|
||||
if (_vm->_globals._saveData->data[svField354] == 1
|
||||
&& !_vm->_globals.PLAN_FLAG
|
||||
&& (uint16)(destX - 533) <= 26
|
||||
&& (uint16)(destY - 26) <= 33) {
|
||||
changeCharacterHead(CHARACTER_HOPKINS_CLONE, CHARACTER_HOPKINS);
|
||||
return;
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField356] == 1
|
||||
if (_vm->_globals._saveData->data[svField356] == 1
|
||||
&& !_vm->_globals.PLAN_FLAG
|
||||
&& (uint16)(destX - 533) <= 26
|
||||
&& (uint16)(destY - 26) <= 22) {
|
||||
changeCharacterHead(CHARACTER_SAMANTHA, CHARACTER_HOPKINS);
|
||||
return;
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField357] == 1) {
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField353] == 1
|
||||
if (_vm->_globals._saveData->data[svField357] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField353] == 1
|
||||
&& !_vm->_globals.PLAN_FLAG
|
||||
&& (uint16)(destX - 533) <= 26
|
||||
&& (uint16)(destY - 26) <= 33) {
|
||||
changeCharacterHead(CHARACTER_HOPKINS, CHARACTER_HOPKINS_CLONE);
|
||||
return;
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField355] == 1
|
||||
if (_vm->_globals._saveData->data[svField355] == 1
|
||||
&& !_vm->_globals.PLAN_FLAG
|
||||
&& (uint16)(destX - 567) <= 26
|
||||
&& (uint16)(destY - 26) <= 33) {
|
||||
@ -2639,8 +2639,8 @@ void ObjectsManager::handleLeftButton() {
|
||||
if (_vm->_globals.GOACTION) {
|
||||
VERIFZONE();
|
||||
_vm->_globals.GOACTION = false;
|
||||
_vm->_globals.SAUVEGARDE->data[svField1] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField2] = 0;
|
||||
_vm->_globals._saveData->data[svField1] = 0;
|
||||
_vm->_globals._saveData->data[svField2] = 0;
|
||||
}
|
||||
LABEL_38:
|
||||
if (_vm->_globals.PLAN_FLAG == true && (_vm->_eventsManager._mouseCursorId != 4 || NUMZONE <= 0))
|
||||
@ -2715,12 +2715,12 @@ LABEL_65:
|
||||
}
|
||||
if ((uint16)(NUMZONE + 1) > 1u) {
|
||||
// TODO: Reformat the weird if statement generated by the decompiler
|
||||
if (_vm->_eventsManager._mouseCursorId == 23 || (_vm->_globals.SAUVEGARDE->data[svField1] = _vm->_eventsManager._mouseCursorId, _vm->_eventsManager._mouseCursorId == 23))
|
||||
_vm->_globals.SAUVEGARDE->data[svField1] = 5;
|
||||
if (_vm->_eventsManager._mouseCursorId == 23 || (_vm->_globals._saveData->data[svField1] = _vm->_eventsManager._mouseCursorId, _vm->_eventsManager._mouseCursorId == 23))
|
||||
_vm->_globals._saveData->data[svField1] = 5;
|
||||
if (_vm->_globals.PLAN_FLAG == true)
|
||||
_vm->_globals.SAUVEGARDE->data[svField1] = 6;
|
||||
_vm->_globals.SAUVEGARDE->data[svField2] = NUMZONE;
|
||||
_vm->_globals.SAUVEGARDE->data[svField3] = _vm->_globals._curObjectIndex;
|
||||
_vm->_globals._saveData->data[svField1] = 6;
|
||||
_vm->_globals._saveData->data[svField2] = NUMZONE;
|
||||
_vm->_globals._saveData->data[svField3] = _vm->_globals._curObjectIndex;
|
||||
_vm->_globals.GOACTION = true;
|
||||
}
|
||||
_vm->_fontManager.hideText(5);
|
||||
@ -2730,7 +2730,7 @@ LABEL_65:
|
||||
ARRET_PERSO_FLAG = 1;
|
||||
ARRET_PERSO_NUM = _vm->_globals.BOBZONE[NUMZONE];
|
||||
}
|
||||
if (_vm->_globals.ECRAN == 20 && _vm->_globals.SAUVEGARDE->data[svField132] == 1
|
||||
if (_vm->_globals._screenId == 20 && _vm->_globals._saveData->data[svField132] == 1
|
||||
&& _vm->_globals._curObjectIndex == 20 && NUMZONE == 12
|
||||
&& _vm->_eventsManager._mouseCursorId == 23) {
|
||||
// Special case for throwing darts at the switch in Purgatory - the player shouldn't move
|
||||
@ -2749,8 +2749,8 @@ void ObjectsManager::PARADISE() {
|
||||
v1 = 0;
|
||||
ARRET_PERSO_FLAG = 0;
|
||||
ARRET_PERSO_NUM = 0;
|
||||
result = _vm->_globals.SAUVEGARDE->data[svField1];
|
||||
if (result && _vm->_globals.SAUVEGARDE->data[svField2] && result != 4 && result > 3) {
|
||||
result = _vm->_globals._saveData->data[svField1];
|
||||
if (result && _vm->_globals._saveData->data[svField2] && result != 4 && result > 3) {
|
||||
_vm->_fontManager.hideText(5);
|
||||
if (!_vm->_globals.forest || ((uint16)(NUMZONE - 20) > 1u && (uint16)(NUMZONE - 22) > 1u)) {
|
||||
if (_vm->_graphicsManager.DOUBLE_ECRAN) {
|
||||
@ -2809,20 +2809,20 @@ LABEL_64:
|
||||
_vm->_eventsManager.VBL();
|
||||
_vm->_graphicsManager.no_scroll = 0;
|
||||
}
|
||||
_vm->_talkManager.REPONSE(_vm->_globals.SAUVEGARDE->data[svField2], _vm->_globals.SAUVEGARDE->data[svField1]);
|
||||
_vm->_talkManager.REPONSE(_vm->_globals._saveData->data[svField2], _vm->_globals._saveData->data[svField1]);
|
||||
} else {
|
||||
_vm->_talkManager.REPONSE2(_vm->_globals.SAUVEGARDE->data[svField2], _vm->_globals.SAUVEGARDE->data[svField1]);
|
||||
_vm->_talkManager.REPONSE2(_vm->_globals._saveData->data[svField2], _vm->_globals._saveData->data[svField1]);
|
||||
}
|
||||
_vm->_eventsManager.changeMouseCursor(4);
|
||||
if ((uint16)(NUMZONE + 1) > 1u && !_vm->_globals.ZONEP[NUMZONE].field16) {
|
||||
NUMZONE = -1;
|
||||
_forceZoneFl = true;
|
||||
}
|
||||
if (NUMZONE != _vm->_globals.SAUVEGARDE->data[svField2] || (uint16)(NUMZONE + 1) <= 1u) {
|
||||
if (NUMZONE != _vm->_globals._saveData->data[svField2] || (uint16)(NUMZONE + 1) <= 1u) {
|
||||
_vm->_eventsManager._mouseCursorId = 4;
|
||||
_changeVerbFl = false;
|
||||
} else {
|
||||
_vm->_eventsManager._mouseCursorId = _vm->_globals.SAUVEGARDE->data[svField1];
|
||||
_vm->_eventsManager._mouseCursorId = _vm->_globals._saveData->data[svField1];
|
||||
if (_changeVerbFl) {
|
||||
VERBEPLUS();
|
||||
_changeVerbFl = false;
|
||||
@ -2833,8 +2833,8 @@ LABEL_64:
|
||||
if (_vm->_eventsManager._mouseCursorId != 23)
|
||||
_vm->_eventsManager.changeMouseCursor(_vm->_eventsManager._mouseCursorId);
|
||||
NUMZONE = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField1] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField2] = 0;
|
||||
_vm->_globals._saveData->data[svField1] = 0;
|
||||
_vm->_globals._saveData->data[svField2] = 0;
|
||||
}
|
||||
if (_vm->_globals.PLAN_FLAG == true) {
|
||||
_vm->_eventsManager._mouseCursorId = 0;
|
||||
@ -2883,8 +2883,8 @@ void ObjectsManager::CLEAR_ECRAN() {
|
||||
_vm->_eventsManager._startPos.x = 0;
|
||||
_vm->_eventsManager._mouseSpriteId = 0;
|
||||
Vold_taille = 200;
|
||||
_vm->_globals.SAUVEGARDE->data[svField1] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField2] = 0;
|
||||
_vm->_globals._saveData->data[svField1] = 0;
|
||||
_vm->_globals._saveData->data[svField2] = 0;
|
||||
_vm->_globals.GOACTION = false;
|
||||
_forceZoneFl = true;
|
||||
_changeVerbFl = false;
|
||||
@ -2914,13 +2914,13 @@ void ObjectsManager::changeCharacterHead(PlayerCharacter oldCharacter, PlayerCha
|
||||
_vm->_globals.chemin = (int16 *)g_PTRNUL;
|
||||
|
||||
if (oldCharacter == CHARACTER_SAMANTHA && newCharacter == CHARACTER_HOPKINS
|
||||
&& _vm->_globals.SAUVEGARDE->_realHopkins._location == _vm->_globals.ECRAN) {
|
||||
&& _vm->_globals._saveData->_realHopkins._location == _vm->_globals._screenId) {
|
||||
CH_TETE = 0;
|
||||
loc = &_vm->_globals.SAUVEGARDE->_samantha;
|
||||
loc = &_vm->_globals._saveData->_samantha;
|
||||
loc->_pos.x = getSpriteX(0);
|
||||
loc->_pos.y = getSpriteY(0);
|
||||
loc->field2 = 64;
|
||||
loc->_location = _vm->_globals.ECRAN;
|
||||
loc->_location = _vm->_globals._screenId;
|
||||
loc->field4 = _sprite[0]._animationType;
|
||||
|
||||
removeSprite(1);
|
||||
@ -2928,12 +2928,12 @@ void ObjectsManager::changeCharacterHead(PlayerCharacter oldCharacter, PlayerCha
|
||||
SPRITE_ON(1);
|
||||
removeSprite(0);
|
||||
|
||||
_vm->_globals.SAUVEGARDE->data[svField354] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField356] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField357] = 1;
|
||||
_vm->_globals._saveData->data[svField354] = 0;
|
||||
_vm->_globals._saveData->data[svField356] = 0;
|
||||
_vm->_globals._saveData->data[svField357] = 1;
|
||||
T_RECTIF = 0;
|
||||
|
||||
loc = &_vm->_globals.SAUVEGARDE->_realHopkins;
|
||||
loc = &_vm->_globals._saveData->_realHopkins;
|
||||
_vm->_fileManager.constructFilename(_vm->_globals.HOPSYSTEM, "PERSO.SPR");
|
||||
_vm->_globals.PERSO = _vm->_fileManager.loadFile(_vm->_globals.NFICHIER);
|
||||
_vm->_globals.PERSO_TYPE = 0;
|
||||
@ -2941,13 +2941,13 @@ void ObjectsManager::changeCharacterHead(PlayerCharacter oldCharacter, PlayerCha
|
||||
SPRITE_ON(0);
|
||||
_vm->_globals.HOPKINS_DATA();
|
||||
} else if (oldCharacter == CHARACTER_HOPKINS && newCharacter == CHARACTER_SAMANTHA
|
||||
&& _vm->_globals.SAUVEGARDE->_samantha._location == _vm->_globals.ECRAN) {
|
||||
&& _vm->_globals._saveData->_samantha._location == _vm->_globals._screenId) {
|
||||
CH_TETE = 0;
|
||||
loc = &_vm->_globals.SAUVEGARDE->_realHopkins;
|
||||
loc = &_vm->_globals._saveData->_realHopkins;
|
||||
loc->_pos.x = getSpriteX(0);
|
||||
loc->_pos.y = getSpriteY(0);
|
||||
loc->field2 = 64;
|
||||
loc->_location = _vm->_globals.ECRAN;
|
||||
loc->_location = _vm->_globals._screenId;
|
||||
loc->field4 = _sprite[0].fieldC;
|
||||
|
||||
removeSprite(1);
|
||||
@ -2955,11 +2955,11 @@ void ObjectsManager::changeCharacterHead(PlayerCharacter oldCharacter, PlayerCha
|
||||
SPRITE_ON(1);
|
||||
removeSprite(0);
|
||||
|
||||
_vm->_globals.SAUVEGARDE->data[svField354] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField356] = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[svField357] = 0;
|
||||
_vm->_globals._saveData->data[svField354] = 0;
|
||||
_vm->_globals._saveData->data[svField356] = 1;
|
||||
_vm->_globals._saveData->data[svField357] = 0;
|
||||
|
||||
loc = &_vm->_globals.SAUVEGARDE->_samantha;
|
||||
loc = &_vm->_globals._saveData->_samantha;
|
||||
_vm->_fileManager.constructFilename(_vm->_globals.HOPSYSTEM, "PSAMAN.SPR");
|
||||
_vm->_globals.PERSO = _vm->_fileManager.loadFile(_vm->_globals.NFICHIER);
|
||||
_vm->_globals.PERSO_TYPE = 2;
|
||||
@ -2969,27 +2969,27 @@ void ObjectsManager::changeCharacterHead(PlayerCharacter oldCharacter, PlayerCha
|
||||
} else {
|
||||
switch (oldCharacter) {
|
||||
case CHARACTER_HOPKINS:
|
||||
loc = &_vm->_globals.SAUVEGARDE->_realHopkins;
|
||||
loc = &_vm->_globals._saveData->_realHopkins;
|
||||
loc->_pos.x = getSpriteX(0);
|
||||
loc->_pos.y = getSpriteY(0);
|
||||
loc->field2 = 64;
|
||||
loc->_location = _vm->_globals.ECRAN;
|
||||
loc->_location = _vm->_globals._screenId;
|
||||
loc->field4 = _sprite[0].fieldC;
|
||||
break;
|
||||
case CHARACTER_HOPKINS_CLONE:
|
||||
loc = &_vm->_globals.SAUVEGARDE->_cloneHopkins;
|
||||
loc = &_vm->_globals._saveData->_cloneHopkins;
|
||||
loc->_pos.x = getSpriteX(0);
|
||||
loc->_pos.y = getSpriteY(0);
|
||||
loc->field2 = 64;
|
||||
loc->_location = _vm->_globals.ECRAN;
|
||||
loc->_location = _vm->_globals._screenId;
|
||||
loc->field4 = _sprite[0].fieldC;
|
||||
break;
|
||||
case CHARACTER_SAMANTHA:
|
||||
loc = &_vm->_globals.SAUVEGARDE->_samantha;
|
||||
loc = &_vm->_globals._saveData->_samantha;
|
||||
loc->_pos.x = getSpriteX(0);
|
||||
loc->_pos.y = getSpriteY(0);
|
||||
loc->field2 = 64;
|
||||
loc->_location = _vm->_globals.ECRAN;
|
||||
loc->_location = _vm->_globals._screenId;
|
||||
loc->field4 = _sprite[0].fieldC;
|
||||
break;
|
||||
default:
|
||||
@ -2998,25 +2998,25 @@ void ObjectsManager::changeCharacterHead(PlayerCharacter oldCharacter, PlayerCha
|
||||
|
||||
switch (newCharacter) {
|
||||
case CHARACTER_HOPKINS:
|
||||
_vm->_globals.SAUVEGARDE->data[svField121] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField354] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField356] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField357] = 1;
|
||||
_vm->_globals.SORTIE = _vm->_globals.SAUVEGARDE->_realHopkins._location;
|
||||
_vm->_globals._saveData->data[svField121] = 0;
|
||||
_vm->_globals._saveData->data[svField354] = 0;
|
||||
_vm->_globals._saveData->data[svField356] = 0;
|
||||
_vm->_globals._saveData->data[svField357] = 1;
|
||||
_vm->_globals._exitId = _vm->_globals._saveData->_realHopkins._location;
|
||||
break;
|
||||
case CHARACTER_HOPKINS_CLONE:
|
||||
_vm->_globals.SAUVEGARDE->data[svField121] = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[svField354] = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[svField356] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField357] = 0;
|
||||
_vm->_globals.SORTIE = _vm->_globals.SAUVEGARDE->_cloneHopkins._location;
|
||||
_vm->_globals._saveData->data[svField121] = 1;
|
||||
_vm->_globals._saveData->data[svField354] = 1;
|
||||
_vm->_globals._saveData->data[svField356] = 0;
|
||||
_vm->_globals._saveData->data[svField357] = 0;
|
||||
_vm->_globals._exitId = _vm->_globals._saveData->_cloneHopkins._location;
|
||||
break;
|
||||
case CHARACTER_SAMANTHA:
|
||||
_vm->_globals.SAUVEGARDE->data[svField121] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField354] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField356] = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[svField357] = 0;
|
||||
_vm->_globals.SORTIE = _vm->_globals.SAUVEGARDE->_samantha._location;
|
||||
_vm->_globals._saveData->data[svField121] = 0;
|
||||
_vm->_globals._saveData->data[svField354] = 0;
|
||||
_vm->_globals._saveData->data[svField356] = 1;
|
||||
_vm->_globals._saveData->data[svField357] = 0;
|
||||
_vm->_globals._exitId = _vm->_globals._saveData->_samantha._location;
|
||||
break;
|
||||
}
|
||||
}
|
||||
@ -3972,9 +3972,9 @@ void ObjectsManager::OPTI_OBJET() {
|
||||
return;
|
||||
|
||||
if (v5 == 2)
|
||||
v0 = _vm->_scriptManager.Control_Goto(data + 20 * v0);
|
||||
v0 = _vm->_scriptManager.handleGoto(data + 20 * v0);
|
||||
if (v5 == 3)
|
||||
v0 = _vm->_scriptManager.Control_If(data, v0);
|
||||
v0 = _vm->_scriptManager.handleIf(data, v0);
|
||||
if (v0 == -1)
|
||||
error("defective IFF function");
|
||||
if (v5 == 1 || v5 == 4)
|
||||
@ -3991,40 +3991,40 @@ void ObjectsManager::SPECIAL_JEU() {
|
||||
byte *v2;
|
||||
byte *v3;
|
||||
|
||||
if ((uint16)(_vm->_globals.ECRAN - 35) <= 6u) {
|
||||
if (_vm->_globals.OLD_ECRAN == 16 && _vm->_globals.ECRAN == 35)
|
||||
if ((uint16)(_vm->_globals._screenId - 35) <= 6u) {
|
||||
if (_vm->_globals.OLD_ECRAN == 16 && _vm->_globals._screenId == 35)
|
||||
TEST_FORET(35, 500, 555, 100, 440, 1);
|
||||
if (_vm->_globals.OLD_ECRAN == 36 && _vm->_globals.ECRAN == 35)
|
||||
if (_vm->_globals.OLD_ECRAN == 36 && _vm->_globals._screenId == 35)
|
||||
TEST_FORET(35, 6, 84, 100, 440, 4);
|
||||
if (_vm->_globals.OLD_ECRAN == 35 && _vm->_globals.ECRAN == 36)
|
||||
if (_vm->_globals.OLD_ECRAN == 35 && _vm->_globals._screenId == 36)
|
||||
TEST_FORET(36, 551, 633, 100, 440, 2);
|
||||
if (_vm->_globals.OLD_ECRAN == 37 && _vm->_globals.ECRAN == 36)
|
||||
if (_vm->_globals.OLD_ECRAN == 37 && _vm->_globals._screenId == 36)
|
||||
TEST_FORET(36, 6, 84, 100, 440, 4);
|
||||
if (_vm->_globals.OLD_ECRAN == 36 && _vm->_globals.ECRAN == 37)
|
||||
if (_vm->_globals.OLD_ECRAN == 36 && _vm->_globals._screenId == 37)
|
||||
TEST_FORET(37, 551, 633, 100, 440, 1);
|
||||
if (_vm->_globals.OLD_ECRAN == 38 && _vm->_globals.ECRAN == 37)
|
||||
if (_vm->_globals.OLD_ECRAN == 38 && _vm->_globals._screenId == 37)
|
||||
TEST_FORET(37, 392, 529, 100, 440, 2);
|
||||
if (_vm->_globals.OLD_ECRAN == 37 && _vm->_globals.ECRAN == 38)
|
||||
if (_vm->_globals.OLD_ECRAN == 37 && _vm->_globals._screenId == 38)
|
||||
TEST_FORET(38, 133, 252, 100, 440, 4);
|
||||
if (_vm->_globals.OLD_ECRAN == 39 && _vm->_globals.ECRAN == 38)
|
||||
if (_vm->_globals.OLD_ECRAN == 39 && _vm->_globals._screenId == 38)
|
||||
TEST_FORET(38, 6, 84, 100, 440, 3);
|
||||
if (_vm->_globals.OLD_ECRAN == 38 && _vm->_globals.ECRAN == 39)
|
||||
if (_vm->_globals.OLD_ECRAN == 38 && _vm->_globals._screenId == 39)
|
||||
TEST_FORET(39, 551, 633, 100, 440, 2);
|
||||
if (_vm->_globals.OLD_ECRAN == 40 && _vm->_globals.ECRAN == 39)
|
||||
if (_vm->_globals.OLD_ECRAN == 40 && _vm->_globals._screenId == 39)
|
||||
TEST_FORET(39, 6, 84, 100, 440, 3);
|
||||
if (_vm->_globals.OLD_ECRAN == 39 && _vm->_globals.ECRAN == 40)
|
||||
if (_vm->_globals.OLD_ECRAN == 39 && _vm->_globals._screenId == 40)
|
||||
TEST_FORET(40, 133, 252, 100, 440, 4);
|
||||
if (_vm->_globals.OLD_ECRAN == 41 && _vm->_globals.ECRAN == 40)
|
||||
if (_vm->_globals.OLD_ECRAN == 41 && _vm->_globals._screenId == 40)
|
||||
TEST_FORET(40, 392, 529, 100, 440, 2);
|
||||
if (_vm->_globals.OLD_ECRAN == 40 && _vm->_globals.ECRAN == 41)
|
||||
if (_vm->_globals.OLD_ECRAN == 40 && _vm->_globals._screenId == 41)
|
||||
TEST_FORET(41, 551, 633, 100, 440, 1);
|
||||
if (_vm->_globals.OLD_ECRAN == 17 && _vm->_globals.ECRAN == 41)
|
||||
if (_vm->_globals.OLD_ECRAN == 17 && _vm->_globals._screenId == 41)
|
||||
TEST_FORET(41, 6, 84, 100, 440, 3);
|
||||
}
|
||||
if (_vm->_globals.ECRAN == 5) {
|
||||
if (_vm->_globals._screenId == 5) {
|
||||
if (getSpriteY(0) <= 399) {
|
||||
if (!_vm->_globals.SAUVEGARDE->data[svField173]) {
|
||||
_vm->_globals.SAUVEGARDE->data[svField173] = 1;
|
||||
if (!_vm->_globals._saveData->data[svField173]) {
|
||||
_vm->_globals._saveData->data[svField173] = 1;
|
||||
_vm->_globals.NOPARLE = true;
|
||||
_vm->_talkManager.PARLER_PERSO("flicspe1.pe2");
|
||||
_vm->_globals.NOPARLE = false;
|
||||
@ -4073,31 +4073,31 @@ void ObjectsManager::SPECIAL_JEU() {
|
||||
}
|
||||
}
|
||||
}
|
||||
if (_vm->_globals.ECRAN == 20)
|
||||
_vm->_globals.SAUVEGARDE->data[svField132] = getSpriteX(0) > 65
|
||||
if (_vm->_globals._screenId == 20)
|
||||
_vm->_globals._saveData->data[svField132] = getSpriteX(0) > 65
|
||||
&& getSpriteX(0) <= 124
|
||||
&& getSpriteY(0) > 372
|
||||
&& getSpriteY(0) <= 398;
|
||||
if (_vm->_globals.ECRAN == 57) {
|
||||
if (_vm->_globals._screenId == 57) {
|
||||
_vm->_globals._disableInventFl = true;
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField261] == 1 && BOBPOSI(5) == 37) {
|
||||
if (_vm->_globals._saveData->data[svField261] == 1 && BOBPOSI(5) == 37) {
|
||||
stopBobAnimation(5);
|
||||
SET_BOBPOSI(5, 0);
|
||||
setBobAnimation(6);
|
||||
_vm->_globals.SAUVEGARDE->data[svField261] = 2;
|
||||
_vm->_globals._saveData->data[svField261] = 2;
|
||||
ZONE_OFF(15);
|
||||
_vm->_soundManager.PLAY_SOUND("SOUND75.WAV");
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField261] == 2 && BOBPOSI(6) == 6) {
|
||||
if (_vm->_globals._saveData->data[svField261] == 2 && BOBPOSI(6) == 6) {
|
||||
stopBobAnimation(6);
|
||||
SET_BOBPOSI(6, 0);
|
||||
setBobAnimation(7);
|
||||
ZONE_ON(14);
|
||||
_vm->_globals.SAUVEGARDE->data[svField261] = 3;
|
||||
_vm->_globals._saveData->data[svField261] = 3;
|
||||
}
|
||||
_vm->_globals._disableInventFl = false;
|
||||
}
|
||||
if (_vm->_globals.ECRAN == 93 && !_vm->_globals.SAUVEGARDE->data[svField333]) {
|
||||
if (_vm->_globals._screenId == 93 && !_vm->_globals._saveData->data[svField333]) {
|
||||
_vm->_globals._disableInventFl = true;
|
||||
do
|
||||
_vm->_eventsManager.VBL();
|
||||
@ -4105,7 +4105,7 @@ void ObjectsManager::SPECIAL_JEU() {
|
||||
_vm->_globals.NOPARLE = true;
|
||||
_vm->_talkManager.PARLER_PERSO("GM3.PE2");
|
||||
stopBobAnimation(8);
|
||||
_vm->_globals.SAUVEGARDE->data[svField333] = 1;
|
||||
_vm->_globals._saveData->data[svField333] = 1;
|
||||
_vm->_globals._disableInventFl = false;
|
||||
}
|
||||
}
|
||||
@ -4630,11 +4630,11 @@ void ObjectsManager::INILINK(const Common::String &file) {
|
||||
}
|
||||
|
||||
void ObjectsManager::SPECIAL_INI(const Common::String &a1) {
|
||||
if (_vm->_globals.ECRAN == 73 && !_vm->_globals.SAUVEGARDE->data[svField318]) {
|
||||
if (_vm->_globals._screenId == 73 && !_vm->_globals._saveData->data[svField318]) {
|
||||
_vm->_globals.CACHE_SUB(0);
|
||||
_vm->_globals.CACHE_SUB(1);
|
||||
}
|
||||
if ((uint16)(_vm->_globals.ECRAN - 35) <= 6u) {
|
||||
if ((uint16)(_vm->_globals._screenId - 35) <= 6u) {
|
||||
_vm->_globals.BOBZONE[20] = 1;
|
||||
_vm->_globals.BOBZONE[21] = 2;
|
||||
_vm->_globals.BOBZONE[22] = 3;
|
||||
@ -4652,15 +4652,15 @@ void ObjectsManager::SPECIAL_INI(const Common::String &a1) {
|
||||
_vm->_globals.ZONEP[22].field12 = 30;
|
||||
_vm->_globals.ZONEP[23].field12 = 30;
|
||||
for (int v2 = 200; v2 <= 214; v2++) {
|
||||
if (_vm->_globals.SAUVEGARDE->data[v2] != 2)
|
||||
_vm->_globals.SAUVEGARDE->data[v2] = 0;
|
||||
if (_vm->_globals._saveData->data[v2] != 2)
|
||||
_vm->_globals._saveData->data[v2] = 0;
|
||||
}
|
||||
}
|
||||
if (_vm->_globals.ECRAN == 93) {
|
||||
if (!_vm->_globals.SAUVEGARDE->data[svField333])
|
||||
if (_vm->_globals._screenId == 93) {
|
||||
if (!_vm->_globals._saveData->data[svField333])
|
||||
setBobAnimation(8);
|
||||
}
|
||||
if (_vm->_globals.ECRAN == 18 && _vm->_globals.OLD_ECRAN == 17) {
|
||||
if (_vm->_globals._screenId == 18 && _vm->_globals.OLD_ECRAN == 17) {
|
||||
_vm->_eventsManager._mouseSpriteId = 4;
|
||||
_vm->_globals.BPP_NOAFF = true;
|
||||
for (int v3 = 0; v3 <= 4; v3++)
|
||||
@ -4675,7 +4675,7 @@ void ObjectsManager::SPECIAL_INI(const Common::String &a1) {
|
||||
_vm->_graphicsManager.NOFADE = true;
|
||||
_vm->_globals._disableInventFl = false;
|
||||
}
|
||||
if (_vm->_globals.ECRAN == 17 && _vm->_globals.OLD_ECRAN == 20) {
|
||||
if (_vm->_globals._screenId == 17 && _vm->_globals.OLD_ECRAN == 20) {
|
||||
_vm->_globals._disableInventFl = true;
|
||||
_vm->_graphicsManager.SETCOLOR3(252, 100, 100, 100);
|
||||
_vm->_graphicsManager.SETCOLOR3(253, 100, 100, 100);
|
||||
@ -4698,9 +4698,9 @@ void ObjectsManager::SPECIAL_INI(const Common::String &a1) {
|
||||
}
|
||||
if (!_vm->_soundManager._voiceOffFl)
|
||||
_vm->_soundManager.mixVoice(383, 4);
|
||||
_vm->_globals.SAUVEGARDE->data[svField270] = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[svField300] = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[svField320] = 1;
|
||||
_vm->_globals._saveData->data[svField270] = 1;
|
||||
_vm->_globals._saveData->data[svField300] = 1;
|
||||
_vm->_globals._saveData->data[svField320] = 1;
|
||||
if (_vm->_soundManager._voiceOffFl) {
|
||||
for (int v6 = 0; v6 <= 199; v6++)
|
||||
_vm->_eventsManager.VBL();
|
||||
@ -5128,75 +5128,75 @@ void ObjectsManager::TEST_FORET(int a1, int a2, int a3, int a4, int a5, int a6)
|
||||
char v7;
|
||||
|
||||
v6 = a1;
|
||||
if (_vm->_globals.ECRAN == a1) {
|
||||
if (_vm->_globals._screenId == a1) {
|
||||
if (a1 == 35) {
|
||||
if (a6 > 2 || (v6 = 200, a6 > 2))
|
||||
v6 = 201;
|
||||
}
|
||||
if (_vm->_globals.ECRAN == 36) {
|
||||
if (_vm->_globals._screenId == 36) {
|
||||
if (a6 > 2 || (v6 = 202, a6 > 2))
|
||||
v6 = 203;
|
||||
}
|
||||
if (_vm->_globals.ECRAN == 37) {
|
||||
if (_vm->_globals._screenId == 37) {
|
||||
if (a6 > 2 || (v6 = 204, a6 > 2))
|
||||
v6 = 205;
|
||||
}
|
||||
if (_vm->_globals.ECRAN == 38) {
|
||||
if (_vm->_globals._screenId == 38) {
|
||||
if (a6 > 2 || (v6 = 206, a6 > 2))
|
||||
v6 = 207;
|
||||
}
|
||||
if (_vm->_globals.ECRAN == 39) {
|
||||
if (_vm->_globals._screenId == 39) {
|
||||
if (a6 > 2 || (v6 = 208, a6 > 2))
|
||||
v6 = 209;
|
||||
}
|
||||
if (_vm->_globals.ECRAN == 40) {
|
||||
if (_vm->_globals._screenId == 40) {
|
||||
if (a6 > 2 || (v6 = 210, a6 > 2))
|
||||
v6 = 211;
|
||||
}
|
||||
if (_vm->_globals.ECRAN == 41) {
|
||||
if (_vm->_globals._screenId == 41) {
|
||||
if (a6 > 2 || (v6 = 212, a6 > 2))
|
||||
v6 = 213;
|
||||
}
|
||||
v7 = _vm->_globals.SAUVEGARDE->data[v6];
|
||||
v7 = _vm->_globals._saveData->data[v6];
|
||||
if (v7 != 2) {
|
||||
if (v7) {
|
||||
if (v7 == 1) {
|
||||
if (a6 == 1 && BOBPOSI(1) == 26) {
|
||||
_vm->_dialogsManager._removeInventFl = true;
|
||||
_vm->_soundManager.PLAY_SAMPLE2(1);
|
||||
_vm->_globals.SAUVEGARDE->data[v6] = 4;
|
||||
_vm->_globals._saveData->data[v6] = 4;
|
||||
}
|
||||
if (a6 == 2 && BOBPOSI(2) == 26) {
|
||||
_vm->_dialogsManager._removeInventFl = true;
|
||||
_vm->_soundManager.PLAY_SAMPLE2(1);
|
||||
_vm->_globals.SAUVEGARDE->data[v6] = 4;
|
||||
_vm->_globals._saveData->data[v6] = 4;
|
||||
}
|
||||
if (a6 == 3 && BOBPOSI(3) == 27) {
|
||||
_vm->_dialogsManager._removeInventFl = true;
|
||||
_vm->_soundManager.PLAY_SAMPLE2(1);
|
||||
_vm->_globals.SAUVEGARDE->data[v6] = 4;
|
||||
_vm->_globals._saveData->data[v6] = 4;
|
||||
}
|
||||
if (a6 == 4 && BOBPOSI(4) == 27) {
|
||||
_vm->_dialogsManager._removeInventFl = true;
|
||||
_vm->_soundManager.PLAY_SAMPLE2(1);
|
||||
_vm->_dialogsManager._removeInventFl = true;
|
||||
_vm->_globals.SAUVEGARDE->data[v6] = 4;
|
||||
_vm->_globals._saveData->data[v6] = 4;
|
||||
}
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[v6] == 4) {
|
||||
if (_vm->_globals._saveData->data[v6] == 4) {
|
||||
if (a6 == 1 && (signed int)BOBPOSI(1) > 30)
|
||||
_vm->_globals.SAUVEGARDE->data[v6] = 3;
|
||||
_vm->_globals._saveData->data[v6] = 3;
|
||||
if (a6 == 2 && (signed int)BOBPOSI(2) > 30)
|
||||
_vm->_globals.SAUVEGARDE->data[v6] = 3;
|
||||
_vm->_globals._saveData->data[v6] = 3;
|
||||
if (a6 == 3 && (signed int)BOBPOSI(3) > 30)
|
||||
_vm->_globals.SAUVEGARDE->data[v6] = 3;
|
||||
_vm->_globals._saveData->data[v6] = 3;
|
||||
if (a6 == 4 && (signed int)BOBPOSI(4) > 30)
|
||||
_vm->_globals.SAUVEGARDE->data[v6] = 3;
|
||||
_vm->_globals._saveData->data[v6] = 3;
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[v6] == 3) {
|
||||
if (_vm->_globals._saveData->data[v6] == 3) {
|
||||
_vm->_graphicsManager.FADE_LINUX = 2;
|
||||
_vm->_animationManager.playAnim("CREVE2.ANM", 100, 24, 500);
|
||||
_vm->_globals.SORTIE = 150;
|
||||
_vm->_globals._exitId = 150;
|
||||
_vm->_graphicsManager.NOFADE = true;
|
||||
BOB_OFF(1);
|
||||
BOB_OFF(2);
|
||||
@ -5215,7 +5215,7 @@ void ObjectsManager::TEST_FORET(int a1, int a2, int a3, int a4, int a5, int a6)
|
||||
setBobAnimation(3);
|
||||
if (a6 == 4)
|
||||
setBobAnimation(4);
|
||||
_vm->_globals.SAUVEGARDE->data[v6] = 1;
|
||||
_vm->_globals._saveData->data[v6] = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -5243,7 +5243,7 @@ void ObjectsManager::PERSONAGE(const Common::String &backgroundFile, const Commo
|
||||
_vm->_soundManager.WSOUND(v);
|
||||
_vm->_globals.chemin = (int16 *)g_PTRNUL;
|
||||
_vm->_globals.NOMARCHE = true;
|
||||
_vm->_globals.SORTIE = 0;
|
||||
_vm->_globals._exitId = 0;
|
||||
_vm->_globals.AFFLI = false;
|
||||
_vm->_globals.AFFIVBL = false;
|
||||
if (!backgroundFile.empty())
|
||||
@ -5260,7 +5260,7 @@ void ObjectsManager::PERSONAGE(const Common::String &backgroundFile, const Commo
|
||||
_vm->_graphicsManager.INI_ECRAN2(s4);
|
||||
}
|
||||
_vm->_eventsManager.mouseOn();
|
||||
if (_vm->_globals.ECRAN == 61) {
|
||||
if (_vm->_globals._screenId == 61) {
|
||||
SPRITE(_vm->_globals.PERSO, Common::Point(330, 418), 0, 60, 0, 0, 34, 190);
|
||||
SPRITE_ON(0);
|
||||
_vm->_globals.chemin = (int16 *)g_PTRNUL;
|
||||
@ -5276,7 +5276,7 @@ void ObjectsManager::PERSONAGE(const Common::String &backgroundFile, const Commo
|
||||
_vm->_eventsManager.VBL();
|
||||
_vm->_globals.BPP_NOAFF = false;
|
||||
_vm->_graphicsManager.FADE_INW();
|
||||
if (_vm->_globals.ECRAN == 61) {
|
||||
if (_vm->_globals._screenId == 61) {
|
||||
_vm->_animationManager.playSequence("OUVRE.SEQ", 10, 4, 10);
|
||||
stopBobAnimation(3);
|
||||
_vm->_globals.NOT_VERIF = 1;
|
||||
@ -5306,9 +5306,9 @@ void ObjectsManager::PERSONAGE(const Common::String &backgroundFile, const Commo
|
||||
VERIFZONE();
|
||||
if (_vm->_globals.GOACTION)
|
||||
PARADISE();
|
||||
if (!_vm->_globals.SORTIE) {
|
||||
if (!_vm->_globals._exitId) {
|
||||
_vm->_eventsManager.VBL();
|
||||
if (!_vm->_globals.SORTIE)
|
||||
if (!_vm->_globals._exitId)
|
||||
continue;
|
||||
}
|
||||
v5 = 1;
|
||||
@ -5319,7 +5319,7 @@ void ObjectsManager::PERSONAGE(const Common::String &backgroundFile, const Commo
|
||||
_vm->_graphicsManager.FADE_OUTW();
|
||||
if (!animFile.empty())
|
||||
_vm->_graphicsManager.FIN_VISU();
|
||||
if (_vm->_globals.ECRAN == 61)
|
||||
if (_vm->_globals._screenId == 61)
|
||||
removeSprite(0);
|
||||
CLEAR_ECRAN();
|
||||
_vm->_globals.iRegul = 0;
|
||||
@ -5340,7 +5340,7 @@ void ObjectsManager::PERSONAGE2(const Common::String &backgroundFile, const Comm
|
||||
_vm->_globals.PLAN_FLAG = false;
|
||||
_vm->_graphicsManager.NOFADE = false;
|
||||
_vm->_globals.NOMARCHE = false;
|
||||
_vm->_globals.SORTIE = 0;
|
||||
_vm->_globals._exitId = 0;
|
||||
_vm->_globals.AFFLI = false;
|
||||
_vm->_globals.AFFIVBL = false;
|
||||
_vm->_globals.NOT_VERIF = 1;
|
||||
@ -5368,20 +5368,20 @@ void ObjectsManager::PERSONAGE2(const Common::String &backgroundFile, const Comm
|
||||
_vm->_graphicsManager.SETCOLOR3(254, 0, 0, 0);
|
||||
if (!_vm->_globals.PERSO_TYPE)
|
||||
goto LABEL_70;
|
||||
if (!_vm->_globals.SAUVEGARDE->data[svField122] && !_vm->_globals.SAUVEGARDE->data[svField356]) {
|
||||
if (!_vm->_globals._saveData->data[svField122] && !_vm->_globals._saveData->data[svField356]) {
|
||||
_vm->_fileManager.constructFilename(_vm->_globals.HOPSYSTEM, "PERSO.SPR");
|
||||
_vm->_globals.PERSO = _vm->_fileManager.loadFile(_vm->_globals.NFICHIER);
|
||||
_vm->_globals.PERSO_TYPE = 0;
|
||||
}
|
||||
if (!_vm->_globals.PERSO_TYPE) {
|
||||
LABEL_70:
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField122] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField122] == 1) {
|
||||
_vm->_fileManager.constructFilename(_vm->_globals.HOPSYSTEM, "HOPFEM.SPR");
|
||||
_vm->_globals.PERSO = _vm->_fileManager.loadFile(_vm->_globals.NFICHIER);
|
||||
_vm->_globals.PERSO_TYPE = 1;
|
||||
}
|
||||
}
|
||||
if (_vm->_globals.PERSO_TYPE != 2 && _vm->_globals.SAUVEGARDE->data[svField356] == 1) {
|
||||
if (_vm->_globals.PERSO_TYPE != 2 && _vm->_globals._saveData->data[svField356] == 1) {
|
||||
_vm->_fileManager.constructFilename(_vm->_globals.HOPSYSTEM, "PSAMAN.SPR");
|
||||
_vm->_globals.PERSO = _vm->_fileManager.loadFile(_vm->_globals.NFICHIER);
|
||||
_vm->_globals.PERSO_TYPE = 2;
|
||||
@ -5436,7 +5436,7 @@ LABEL_70:
|
||||
if (yCheck == yp) {
|
||||
_vm->_globals.chemin = (int16 *)g_PTRNUL;
|
||||
PARADISE();
|
||||
if (_vm->_globals.SORTIE)
|
||||
if (_vm->_globals._exitId)
|
||||
breakFlag = true;
|
||||
}
|
||||
}
|
||||
@ -5448,7 +5448,7 @@ LABEL_70:
|
||||
handleRightButton();
|
||||
}
|
||||
}
|
||||
if (!_vm->_globals.SORTIE) {
|
||||
if (!_vm->_globals._exitId) {
|
||||
_vm->_dialogsManager.testDialogOpening();
|
||||
VERIFZONE();
|
||||
if (_vm->_globals.chemin == (int16 *)g_PTRNUL
|
||||
@ -5458,13 +5458,13 @@ LABEL_70:
|
||||
}
|
||||
SPECIAL_JEU();
|
||||
_vm->_eventsManager.VBL();
|
||||
if (!_vm->_globals.SORTIE)
|
||||
if (!_vm->_globals._exitId)
|
||||
continue;
|
||||
}
|
||||
breakFlag = true;
|
||||
}
|
||||
|
||||
if (_vm->_globals.SORTIE != 8 || _vm->_globals.ECRAN != 5 || _vm->_globals.HELICO != 1) {
|
||||
if (_vm->_globals._exitId != 8 || _vm->_globals._screenId != 5 || _vm->_globals.HELICO != 1) {
|
||||
if (!_vm->_graphicsManager.NOFADE)
|
||||
_vm->_graphicsManager.FADE_OUTW();
|
||||
_vm->_graphicsManager.NOFADE = false;
|
||||
|
@ -140,11 +140,11 @@ void SaveLoadManager::writeSavegameHeader(Common::OutSaveFile *out, hopkinsSaveg
|
||||
Common::Error SaveLoadManager::saveGame(int slot, const Common::String &saveName) {
|
||||
/* Pack any necessary data into the savegame data structure */
|
||||
// Set the selected slot number
|
||||
_vm->_globals.SAUVEGARDE->data[svField10] = slot;
|
||||
_vm->_globals._saveData->data[svField10] = slot;
|
||||
|
||||
// Set up the inventory
|
||||
for (int i = 0; i < 35; ++i)
|
||||
_vm->_globals.SAUVEGARDE->_inventory[i] = _vm->_globals._inventory[i];
|
||||
_vm->_globals._saveData->_inventory[i] = _vm->_globals._inventory[i];
|
||||
|
||||
/* Create the savegame */
|
||||
Common::OutSaveFile *saveFile = g_system->getSavefileManager()->openForSaving(
|
||||
@ -196,13 +196,13 @@ Common::Error SaveLoadManager::loadGame(int slot) {
|
||||
|
||||
// Unpack the inventory
|
||||
for (int i = 0; i < 35; ++i)
|
||||
_vm->_globals._inventory[i] = _vm->_globals.SAUVEGARDE->_inventory[i];
|
||||
_vm->_globals._inventory[i] = _vm->_globals._saveData->_inventory[i];
|
||||
|
||||
// Set variables from loaded data as necessary
|
||||
_vm->_globals.SAUVEGARDE->data[svField10] = slot;
|
||||
_vm->_globals.SORTIE = _vm->_globals.SAUVEGARDE->data[svField5];
|
||||
_vm->_globals.SAUVEGARDE->data[svField6] = 0;
|
||||
_vm->_globals.ECRAN = 0;
|
||||
_vm->_globals._saveData->data[svField10] = slot;
|
||||
_vm->_globals._exitId = _vm->_globals._saveData->data[svField5];
|
||||
_vm->_globals._saveData->data[svField6] = 0;
|
||||
_vm->_globals._screenId = 0;
|
||||
|
||||
return Common::kNoError;
|
||||
}
|
||||
@ -253,13 +253,13 @@ void SaveLoadManager::createThumbnail(Graphics::Surface *s) {
|
||||
}
|
||||
|
||||
void SaveLoadManager::syncSavegameData(Common::Serializer &s) {
|
||||
s.syncBytes(&_vm->_globals.SAUVEGARDE->data[0], 2050);
|
||||
syncCharacterLocation(s, _vm->_globals.SAUVEGARDE->_cloneHopkins);
|
||||
syncCharacterLocation(s, _vm->_globals.SAUVEGARDE->_realHopkins);
|
||||
syncCharacterLocation(s, _vm->_globals.SAUVEGARDE->_samantha);
|
||||
s.syncBytes(&_vm->_globals._saveData->data[0], 2050);
|
||||
syncCharacterLocation(s, _vm->_globals._saveData->_cloneHopkins);
|
||||
syncCharacterLocation(s, _vm->_globals._saveData->_realHopkins);
|
||||
syncCharacterLocation(s, _vm->_globals._saveData->_samantha);
|
||||
|
||||
for (int i = 0; i < 35; ++i)
|
||||
s.syncAsSint16LE(_vm->_globals.SAUVEGARDE->_inventory[i]);
|
||||
s.syncAsSint16LE(_vm->_globals._saveData->_inventory[i]);
|
||||
}
|
||||
|
||||
void SaveLoadManager::syncCharacterLocation(Common::Serializer &s, CharacterLocation &item) {
|
||||
|
@ -56,7 +56,7 @@ int ScriptManager::Traduction(byte *a1) {
|
||||
int mesgId = (int16)READ_LE_UINT16(a1 + 13);
|
||||
v1 = 1;
|
||||
if (!TRAVAILOBJET) {
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField356] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField356] == 1) {
|
||||
if (mesgId == 53)
|
||||
mesgId = 644;
|
||||
if (mesgId == 624)
|
||||
@ -140,7 +140,7 @@ int ScriptManager::Traduction(byte *a1) {
|
||||
_vm->_soundManager.mixVoice(mesgId, 4);
|
||||
}
|
||||
if (TRAVAILOBJET) {
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField356]) {
|
||||
if (_vm->_globals._saveData->data[svField356]) {
|
||||
_vm->_fontManager.initTextBuffers(9, 635, _vm->_globals.FICH_TEXTE, 55, 20, 20, 25, v69, 35, 253);
|
||||
if (!_vm->_soundManager._textOffFl)
|
||||
_vm->_fontManager.showText(9);
|
||||
@ -207,52 +207,52 @@ LABEL_1141:
|
||||
_vm->_objectsManager.PERY = v6;
|
||||
_vm->_objectsManager.PERI = v5;
|
||||
if (_vm->_objectsManager.CH_TETE == 1) {
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField354] == 1
|
||||
&& _vm->_globals.SAUVEGARDE->_cloneHopkins._pos.x && _vm->_globals.SAUVEGARDE->_cloneHopkins._pos.y
|
||||
&& _vm->_globals.SAUVEGARDE->_cloneHopkins.field2 && _vm->_globals.SAUVEGARDE->_cloneHopkins._location) {
|
||||
if (_vm->_globals._saveData->data[svField354] == 1
|
||||
&& _vm->_globals._saveData->_cloneHopkins._pos.x && _vm->_globals._saveData->_cloneHopkins._pos.y
|
||||
&& _vm->_globals._saveData->_cloneHopkins.field2 && _vm->_globals._saveData->_cloneHopkins._location) {
|
||||
|
||||
_vm->_objectsManager.PERX = _vm->_globals.SAUVEGARDE->_cloneHopkins._pos.x;
|
||||
_vm->_objectsManager.PERY = _vm->_globals.SAUVEGARDE->_cloneHopkins._pos.y;
|
||||
_vm->_objectsManager.PERI = _vm->_globals.SAUVEGARDE->_cloneHopkins.field2;
|
||||
_vm->_objectsManager.PERX = _vm->_globals._saveData->_cloneHopkins._pos.x;
|
||||
_vm->_objectsManager.PERY = _vm->_globals._saveData->_cloneHopkins._pos.y;
|
||||
_vm->_objectsManager.PERI = _vm->_globals._saveData->_cloneHopkins.field2;
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField356] == 1
|
||||
&& _vm->_globals.SAUVEGARDE->_samantha._pos.x && _vm->_globals.SAUVEGARDE->_samantha._pos.y
|
||||
&& _vm->_globals.SAUVEGARDE->_samantha.field2 && _vm->_globals.SAUVEGARDE->_samantha._location) {
|
||||
_vm->_objectsManager.PERX = _vm->_globals.SAUVEGARDE->_samantha._pos.x;
|
||||
_vm->_objectsManager.PERY = _vm->_globals.SAUVEGARDE->_samantha._pos.y;
|
||||
_vm->_objectsManager.PERI = _vm->_globals.SAUVEGARDE->_samantha.field2;
|
||||
if (_vm->_globals._saveData->data[svField356] == 1
|
||||
&& _vm->_globals._saveData->_samantha._pos.x && _vm->_globals._saveData->_samantha._pos.y
|
||||
&& _vm->_globals._saveData->_samantha.field2 && _vm->_globals._saveData->_samantha._location) {
|
||||
_vm->_objectsManager.PERX = _vm->_globals._saveData->_samantha._pos.x;
|
||||
_vm->_objectsManager.PERY = _vm->_globals._saveData->_samantha._pos.y;
|
||||
_vm->_objectsManager.PERI = _vm->_globals._saveData->_samantha.field2;
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField357] == 1
|
||||
&& _vm->_globals.SAUVEGARDE->_realHopkins._pos.x && _vm->_globals.SAUVEGARDE->_realHopkins._pos.y
|
||||
&& _vm->_globals.SAUVEGARDE->_realHopkins.field2 && _vm->_globals.SAUVEGARDE->_realHopkins._location) {
|
||||
_vm->_objectsManager.PERX = _vm->_globals.SAUVEGARDE->_realHopkins._pos.x;
|
||||
_vm->_objectsManager.PERY = _vm->_globals.SAUVEGARDE->_realHopkins._pos.y;
|
||||
_vm->_objectsManager.PERI = _vm->_globals.SAUVEGARDE->_realHopkins.field2;
|
||||
if (_vm->_globals._saveData->data[svField357] == 1
|
||||
&& _vm->_globals._saveData->_realHopkins._pos.x && _vm->_globals._saveData->_realHopkins._pos.y
|
||||
&& _vm->_globals._saveData->_realHopkins.field2 && _vm->_globals._saveData->_realHopkins._location) {
|
||||
_vm->_objectsManager.PERX = _vm->_globals._saveData->_realHopkins._pos.x;
|
||||
_vm->_objectsManager.PERY = _vm->_globals._saveData->_realHopkins._pos.y;
|
||||
_vm->_objectsManager.PERI = _vm->_globals._saveData->_realHopkins.field2;
|
||||
}
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField356] == 1
|
||||
&& _vm->_globals.SAUVEGARDE->_realHopkins._location == _vm->_globals.ECRAN) {
|
||||
if (_vm->_globals._saveData->data[svField356] == 1
|
||||
&& _vm->_globals._saveData->_realHopkins._location == _vm->_globals._screenId) {
|
||||
_vm->_objectsManager.SPRITE(
|
||||
_vm->_globals.TETE,
|
||||
_vm->_globals.SAUVEGARDE->_realHopkins._pos,
|
||||
_vm->_globals._saveData->_realHopkins._pos,
|
||||
1,
|
||||
2,
|
||||
_vm->_globals.SAUVEGARDE->_realHopkins.field4,
|
||||
_vm->_globals._saveData->_realHopkins.field4,
|
||||
0,
|
||||
34,
|
||||
190);
|
||||
_vm->_objectsManager.SPRITE_ON(1);
|
||||
_vm->_objectsManager.DEUXPERSO = true;
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField357] == 1
|
||||
&& _vm->_globals.SAUVEGARDE->data[svField355] == 1
|
||||
&& _vm->_globals.SAUVEGARDE->_samantha._location == _vm->_globals.ECRAN) {
|
||||
if (_vm->_globals._saveData->data[svField357] == 1
|
||||
&& _vm->_globals._saveData->data[svField355] == 1
|
||||
&& _vm->_globals._saveData->_samantha._location == _vm->_globals._screenId) {
|
||||
_vm->_objectsManager.SPRITE(
|
||||
_vm->_globals.TETE,
|
||||
_vm->_globals.SAUVEGARDE->_samantha._pos,
|
||||
_vm->_globals._saveData->_samantha._pos,
|
||||
1,
|
||||
3,
|
||||
_vm->_globals.SAUVEGARDE->_samantha.field4,
|
||||
_vm->_globals._saveData->_samantha.field4,
|
||||
0,
|
||||
20,
|
||||
127);
|
||||
@ -270,10 +270,10 @@ LABEL_1141:
|
||||
int v8 = *(a1 + 7);
|
||||
int v9 = *(a1 + 8);
|
||||
_vm->_objectsManager.RECALL = 0;
|
||||
_vm->_globals.OLD_ECRAN = _vm->_globals.ECRAN;
|
||||
_vm->_globals.SAUVEGARDE->data[svField6] = _vm->_globals.ECRAN;
|
||||
_vm->_globals.ECRAN = v7;
|
||||
_vm->_globals.SAUVEGARDE->data[svField5] = v7;
|
||||
_vm->_globals.OLD_ECRAN = _vm->_globals._screenId;
|
||||
_vm->_globals._saveData->data[svField6] = _vm->_globals._screenId;
|
||||
_vm->_globals._screenId = v7;
|
||||
_vm->_globals._saveData->data[svField5] = v7;
|
||||
_vm->_objectsManager.PTAILLE = v70;
|
||||
_vm->_objectsManager.PEROFX = v8;
|
||||
_vm->_objectsManager.PEROFY = v9;
|
||||
@ -288,7 +288,7 @@ LABEL_1141:
|
||||
}
|
||||
if (*(a1 + 2) == 'P' && *(a1 + 3) == 'E' && *(a1 + 4) == 'R') {
|
||||
int v73 = (int16)READ_LE_UINT16(a1 + 5);
|
||||
if (!_vm->_globals.SAUVEGARDE->data[svField122] && !_vm->_globals.SAUVEGARDE->data[svField356]) {
|
||||
if (!_vm->_globals._saveData->data[svField122] && !_vm->_globals._saveData->data[svField356]) {
|
||||
v70 = 0;
|
||||
if ((int16)READ_LE_UINT16(a1 + 5) == 14)
|
||||
v73 = 1;
|
||||
@ -508,7 +508,7 @@ LABEL_1141:
|
||||
if (*(a1 + 2) == 'E' && *(a1 + 3) == 'X' && *(a1 + 4) == 'I')
|
||||
v1 = 5;
|
||||
if (*(a1 + 2) == 'S' && *(a1 + 3) == 'O' && *(a1 + 4) == 'R') {
|
||||
_vm->_globals.SORTIE = (int16)READ_LE_UINT16(a1 + 5);
|
||||
_vm->_globals._exitId = (int16)READ_LE_UINT16(a1 + 5);
|
||||
v1 = 5;
|
||||
}
|
||||
if (*(a1 + 2) == 'B' && *(a1 + 3) == 'C' && *(a1 + 4) == 'A') {
|
||||
@ -582,7 +582,7 @@ LABEL_1141:
|
||||
_vm->_soundManager.SPECIAL_SOUND = 0;
|
||||
memset(_vm->_graphicsManager._vesaBuffer, 0, 614400);
|
||||
_vm->_graphicsManager.NOFADE = true;
|
||||
_vm->_globals.SORTIE = 151;
|
||||
_vm->_globals._exitId = 151;
|
||||
}
|
||||
if (v76 == 604) {
|
||||
_vm->_globals.NO_VISU = true;
|
||||
@ -597,7 +597,7 @@ LABEL_1141:
|
||||
_vm->_soundManager.SPECIAL_SOUND = 0;
|
||||
_vm->_graphicsManager.NOFADE = true;
|
||||
memset(_vm->_graphicsManager._vesaBuffer, 0, 614400);
|
||||
_vm->_globals.SORTIE = 151;
|
||||
_vm->_globals._exitId = 151;
|
||||
}
|
||||
if (v76 == 605) {
|
||||
_vm->_globals.NO_VISU = true;
|
||||
@ -614,7 +614,7 @@ LABEL_1141:
|
||||
_vm->_soundManager.SPECIAL_SOUND = 0;
|
||||
_vm->_graphicsManager.NOFADE = true;
|
||||
memset(_vm->_graphicsManager._vesaBuffer, 0, 614400);
|
||||
_vm->_globals.SORTIE = 151;
|
||||
_vm->_globals._exitId = 151;
|
||||
}
|
||||
if (v76 == 606) {
|
||||
_vm->_globals.NO_VISU = true;
|
||||
@ -628,7 +628,7 @@ LABEL_1141:
|
||||
_vm->_animationManager.playAnim("BOMBE3A.ANM", 50, 14, 500);
|
||||
memset(_vm->_graphicsManager._vesaBuffer, 0, 614400);
|
||||
}
|
||||
_vm->_globals.SORTIE = 6;
|
||||
_vm->_globals._exitId = 6;
|
||||
}
|
||||
if (v76 == 607) {
|
||||
if (!_vm->_globals._internetFl) {
|
||||
@ -761,19 +761,19 @@ LABEL_1141:
|
||||
_vm->_globals.HELICO = 1;
|
||||
}
|
||||
if (v76 == 36) {
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField270] == 2 && _vm->_globals.SAUVEGARDE->data[svField94] == 1 && _vm->_globals.SAUVEGARDE->data[svField95] == 1)
|
||||
_vm->_globals.SAUVEGARDE->data[svField270] = 3;
|
||||
if (!_vm->_globals.SAUVEGARDE->data[svField270])
|
||||
if (_vm->_globals._saveData->data[svField270] == 2 && _vm->_globals._saveData->data[svField94] == 1 && _vm->_globals._saveData->data[svField95] == 1)
|
||||
_vm->_globals._saveData->data[svField270] = 3;
|
||||
if (!_vm->_globals._saveData->data[svField270])
|
||||
_vm->_talkManager.PARLER_PERSO2("PATRON0.pe2");
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField270] == 1)
|
||||
if (_vm->_globals._saveData->data[svField270] == 1)
|
||||
_vm->_talkManager.PARLER_PERSO2("PATRON1.pe2");
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField270] == 2)
|
||||
if (_vm->_globals._saveData->data[svField270] == 2)
|
||||
_vm->_talkManager.PARLER_PERSO2("PATRON2.pe2");
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField270] == 3)
|
||||
if (_vm->_globals._saveData->data[svField270] == 3)
|
||||
_vm->_talkManager.PARLER_PERSO2("PATRON3.pe2");
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField270] > 3) {
|
||||
if (_vm->_globals._saveData->data[svField270] > 3) {
|
||||
_vm->_talkManager.PARLER_PERSO2("PATRON4.pe2");
|
||||
_vm->_globals.SAUVEGARDE->data[svField270] = 5;
|
||||
_vm->_globals._saveData->data[svField270] = 5;
|
||||
}
|
||||
}
|
||||
if (v76 == 37) {
|
||||
@ -949,7 +949,7 @@ LABEL_1141:
|
||||
_vm->_objectsManager.removeSprite(0);
|
||||
_vm->_objectsManager.OPTI_BOBON(9, 10, -1, 0, 0, 0, 0);
|
||||
int v19 = 12;
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField133] == 1)
|
||||
if (_vm->_globals._saveData->data[svField133] == 1)
|
||||
v19 = 41;
|
||||
int v20 = 0;
|
||||
do {
|
||||
@ -1132,7 +1132,7 @@ LABEL_1141:
|
||||
_vm->_objectsManager.OBSSEUL = 0;
|
||||
}
|
||||
if (v76 == 88) {
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField183] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField183] == 1) {
|
||||
_vm->_objectsManager.SET_BOBPOSI(1, 0);
|
||||
_vm->_objectsManager.SET_BOBPOSI(2, 0);
|
||||
_vm->_objectsManager.setBobAnimation(1);
|
||||
@ -1174,7 +1174,7 @@ LABEL_1141:
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 283, 160, 6);
|
||||
_vm->_soundManager.DEL_SAMPLE(1);
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField183] == 2) {
|
||||
if (_vm->_globals._saveData->data[svField183] == 2) {
|
||||
_vm->_objectsManager.SET_BOBPOSI(1, 0);
|
||||
_vm->_objectsManager.SET_BOBPOSI(3, 0);
|
||||
_vm->_objectsManager.setBobAnimation(1);
|
||||
@ -1219,11 +1219,11 @@ LABEL_1141:
|
||||
}
|
||||
if (v76 == 90) {
|
||||
_vm->_soundManager.PLAY_SOUND("SOUND52.WAV");
|
||||
if (!_vm->_globals.SAUVEGARDE->data[svField186]) {
|
||||
if (!_vm->_globals._saveData->data[svField186]) {
|
||||
_vm->_animationManager.playSequence("CIB5A.SEQ", 1, 12, 1);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 155, 29, 0);
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField186] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField186] == 1) {
|
||||
_vm->_animationManager.playSequence("CIB5C.SEQ", 1, 12, 1);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 155, 29, 0);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 329, 87, 2);
|
||||
@ -1231,11 +1231,11 @@ LABEL_1141:
|
||||
}
|
||||
if (v76 == 91) {
|
||||
_vm->_soundManager.PLAY_SOUND("SOUND52.WAV");
|
||||
if (!_vm->_globals.SAUVEGARDE->data[svField186]) {
|
||||
if (!_vm->_globals._saveData->data[svField186]) {
|
||||
_vm->_animationManager.playSequence("CIB5B.SEQ", 1, 12, 1);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 155, 29, 5);
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField186] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField186] == 1) {
|
||||
_vm->_animationManager.playSequence("CIB5D.SEQ", 1, 12, 1);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 155, 29, 5);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 283, 160, 6);
|
||||
@ -1243,11 +1243,11 @@ LABEL_1141:
|
||||
}
|
||||
if (v76 == 92) {
|
||||
_vm->_soundManager.PLAY_SOUND("SOUND52.WAV");
|
||||
if (!_vm->_globals.SAUVEGARDE->data[svField184]) {
|
||||
if (!_vm->_globals._saveData->data[svField184]) {
|
||||
_vm->_animationManager.playSequence("CIB6A.SEQ", 1, 12, 1);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 155, 29, 0);
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField184] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField184] == 1) {
|
||||
_vm->_animationManager.playSequence("CIB6C.SEQ", 1, 12, 1);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 155, 29, 0);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 293, 139, 3);
|
||||
@ -1255,11 +1255,11 @@ LABEL_1141:
|
||||
}
|
||||
if (v76 == 93) {
|
||||
_vm->_soundManager.PLAY_SOUND("SOUND52.WAV");
|
||||
if (!_vm->_globals.SAUVEGARDE->data[svField184]) {
|
||||
if (!_vm->_globals._saveData->data[svField184]) {
|
||||
_vm->_animationManager.playSequence("CIB6B.SEQ", 1, 12, 1);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 155, 29, 5);
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField184] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField184] == 1) {
|
||||
_vm->_animationManager.playSequence("CIB6D.SEQ", 1, 12, 1);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 155, 29, 5);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 283, 161, 8);
|
||||
@ -1275,17 +1275,17 @@ LABEL_1141:
|
||||
_vm->_globals.g_old_sens = -1;
|
||||
_vm->_globals.Compteur = 0;
|
||||
_vm->_globals.chemin = (int16 *)g_PTRNUL;
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField253] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField253] == 1) {
|
||||
int v27 = _vm->_objectsManager.getSpriteY(0);
|
||||
int v28 = _vm->_objectsManager.getSpriteX(0);
|
||||
_vm->_globals.chemin = _vm->_linesManager.PARCOURS2(v28, v27, 201, 294);
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField253] == 2) {
|
||||
if (_vm->_globals._saveData->data[svField253] == 2) {
|
||||
int v29 = _vm->_objectsManager.getSpriteY(0);
|
||||
int v30 = _vm->_objectsManager.getSpriteX(0);
|
||||
_vm->_globals.chemin = _vm->_linesManager.PARCOURS2(v30, v29, 158, 338);
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField253] > 2) {
|
||||
if (_vm->_globals._saveData->data[svField253] > 2) {
|
||||
int v31 = _vm->_objectsManager.getSpriteY(0);
|
||||
int v32 = _vm->_objectsManager.getSpriteX(0);
|
||||
_vm->_globals.chemin = _vm->_linesManager.PARCOURS2(v32, v31, 211, 393);
|
||||
@ -1301,7 +1301,7 @@ LABEL_1141:
|
||||
_vm->_objectsManager.removeSprite(0);
|
||||
_vm->_objectsManager.setSpriteIndex(0, 60);
|
||||
_vm->_soundManager.loadSample(1, "SOUND63.WAV");
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField253] > 2) {
|
||||
if (_vm->_globals._saveData->data[svField253] > 2) {
|
||||
_vm->_objectsManager.setBobAnimation(4);
|
||||
int v33 = 0;
|
||||
do {
|
||||
@ -1330,7 +1330,7 @@ LABEL_1141:
|
||||
} while (_vm->_objectsManager.BOBPOSI(4) != 72);
|
||||
_vm->_objectsManager.stopBobAnimation(4);
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField253] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField253] == 1) {
|
||||
_vm->_objectsManager.setBobAnimation(6);
|
||||
int v34 = 0;
|
||||
do {
|
||||
@ -1359,7 +1359,7 @@ LABEL_1141:
|
||||
} while (_vm->_objectsManager.BOBPOSI(6) != 72);
|
||||
_vm->_objectsManager.stopBobAnimation(6);
|
||||
}
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField253] == 2) {
|
||||
if (_vm->_globals._saveData->data[svField253] == 2) {
|
||||
_vm->_objectsManager.setBobAnimation(5);
|
||||
int v35 = 0;
|
||||
do {
|
||||
@ -1513,7 +1513,7 @@ LABEL_1141:
|
||||
_vm->_talkManager.OBJET_VIVANT("PANNEAU.PE2");
|
||||
if (v76 == 208) {
|
||||
_vm->_globals._disableInventFl = true;
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField6] != _vm->_globals.SAUVEGARDE->data[svField401]) {
|
||||
if (_vm->_globals._saveData->data[svField6] != _vm->_globals._saveData->data[svField401]) {
|
||||
_vm->_soundManager.SPECIAL_SOUND = 208;
|
||||
_vm->_eventsManager._disableEscKeyFl = true;
|
||||
_vm->_animationManager.playSequence("SORT.SEQ", 10, 4, 10);
|
||||
@ -1535,7 +1535,7 @@ LABEL_1141:
|
||||
_vm->_eventsManager.VBL();
|
||||
} while (_vm->_globals.chemin != (int16 *)g_PTRNUL);
|
||||
_vm->_objectsManager.setSpriteIndex(0, 64);
|
||||
_vm->_globals.SORTIE = _vm->_globals.SAUVEGARDE->data[svField401];
|
||||
_vm->_globals._exitId = _vm->_globals._saveData->data[svField401];
|
||||
_vm->_globals._disableInventFl = false;
|
||||
}
|
||||
if (v76 == 209) {
|
||||
@ -1793,7 +1793,7 @@ LABEL_1141:
|
||||
_vm->_graphicsManager.FADE_OUTW();
|
||||
_vm->_objectsManager.stopBobAnimation(13);
|
||||
_vm->_graphicsManager.NOFADE = true;
|
||||
_vm->_globals.SORTIE = 94;
|
||||
_vm->_globals._exitId = 94;
|
||||
}
|
||||
if (v76 == 52) {
|
||||
_vm->_globals.NOPARLE = true;
|
||||
@ -1807,7 +1807,7 @@ LABEL_1141:
|
||||
if (v76 == 40)
|
||||
_vm->_talkManager.PARLER_PERSO("MAGE.pe2");
|
||||
if (v76 == 236) {
|
||||
char v47 = _vm->_globals.SAUVEGARDE->data[svField341];
|
||||
char v47 = _vm->_globals._saveData->data[svField341];
|
||||
if (v47) {
|
||||
if (v47 == 2)
|
||||
v70 = 5;
|
||||
@ -1817,25 +1817,25 @@ LABEL_1141:
|
||||
v70 = 6;
|
||||
_vm->_soundManager.PLAY_SOUND("SOUND83.WAV");
|
||||
_vm->_objectsManager.OPTI_ONE(v70, 26, 50, 0);
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 1)
|
||||
if (_vm->_globals._saveData->data[svField341] == 1)
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 27, 117, 0);
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 2)
|
||||
if (_vm->_globals._saveData->data[svField341] == 2)
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 145, 166, 2);
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 3)
|
||||
if (_vm->_globals._saveData->data[svField341] == 3)
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 296, 212, 4);
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 1)
|
||||
_vm->_globals.SAUVEGARDE->data[svField338] = 0;
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 2)
|
||||
_vm->_globals.SAUVEGARDE->data[svField339] = 0;
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 3)
|
||||
_vm->_globals.SAUVEGARDE->data[svField340] = 0;
|
||||
if (_vm->_globals._saveData->data[svField341] == 1)
|
||||
_vm->_globals._saveData->data[svField338] = 0;
|
||||
if (_vm->_globals._saveData->data[svField341] == 2)
|
||||
_vm->_globals._saveData->data[svField339] = 0;
|
||||
if (_vm->_globals._saveData->data[svField341] == 3)
|
||||
_vm->_globals._saveData->data[svField340] = 0;
|
||||
}
|
||||
_vm->_soundManager.PLAY_SOUND("SOUND83.WAV");
|
||||
_vm->_objectsManager.OPTI_ONE(6, 0, 23, 0);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 27, 117, 1);
|
||||
}
|
||||
if (v76 == 237) {
|
||||
char v48 = _vm->_globals.SAUVEGARDE->data[svField341];
|
||||
char v48 = _vm->_globals._saveData->data[svField341];
|
||||
if (v48) {
|
||||
if (v48 == 2)
|
||||
v70 = 5;
|
||||
@ -1845,25 +1845,25 @@ LABEL_1141:
|
||||
v70 = 6;
|
||||
_vm->_soundManager.PLAY_SOUND("SOUND83.WAV");
|
||||
_vm->_objectsManager.OPTI_ONE(v70, 26, 50, 0);
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 1)
|
||||
if (_vm->_globals._saveData->data[svField341] == 1)
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 27, 117, 0);
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 2)
|
||||
if (_vm->_globals._saveData->data[svField341] == 2)
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 145, 166, 2);
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 3)
|
||||
if (_vm->_globals._saveData->data[svField341] == 3)
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 296, 212, 4);
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 1)
|
||||
_vm->_globals.SAUVEGARDE->data[svField338] = 0;
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 2)
|
||||
_vm->_globals.SAUVEGARDE->data[svField339] = 0;
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 3)
|
||||
_vm->_globals.SAUVEGARDE->data[svField340] = 0;
|
||||
if (_vm->_globals._saveData->data[svField341] == 1)
|
||||
_vm->_globals._saveData->data[svField338] = 0;
|
||||
if (_vm->_globals._saveData->data[svField341] == 2)
|
||||
_vm->_globals._saveData->data[svField339] = 0;
|
||||
if (_vm->_globals._saveData->data[svField341] == 3)
|
||||
_vm->_globals._saveData->data[svField340] = 0;
|
||||
}
|
||||
_vm->_soundManager.PLAY_SOUND("SOUND83.WAV");
|
||||
_vm->_objectsManager.OPTI_ONE(5, 0, 23, 0);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 145, 166, 3);
|
||||
}
|
||||
if (v76 == 238) {
|
||||
char v49 = _vm->_globals.SAUVEGARDE->data[svField341];
|
||||
char v49 = _vm->_globals._saveData->data[svField341];
|
||||
if (v49) {
|
||||
if (v49 == 2)
|
||||
v70 = 5;
|
||||
@ -1873,18 +1873,18 @@ LABEL_1141:
|
||||
v70 = 6;
|
||||
_vm->_soundManager.PLAY_SOUND("SOUND83.WAV");
|
||||
_vm->_objectsManager.OPTI_ONE(v70, 26, 50, 0);
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 1)
|
||||
if (_vm->_globals._saveData->data[svField341] == 1)
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 27, 117, 0);
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 2)
|
||||
if (_vm->_globals._saveData->data[svField341] == 2)
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 145, 166, 2);
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 3)
|
||||
if (_vm->_globals._saveData->data[svField341] == 3)
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 296, 212, 4);
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 1)
|
||||
_vm->_globals.SAUVEGARDE->data[svField338] = 0;
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 2)
|
||||
_vm->_globals.SAUVEGARDE->data[svField339] = 0;
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 3)
|
||||
_vm->_globals.SAUVEGARDE->data[svField340] = 0;
|
||||
if (_vm->_globals._saveData->data[svField341] == 1)
|
||||
_vm->_globals._saveData->data[svField338] = 0;
|
||||
if (_vm->_globals._saveData->data[svField341] == 2)
|
||||
_vm->_globals._saveData->data[svField339] = 0;
|
||||
if (_vm->_globals._saveData->data[svField341] == 3)
|
||||
_vm->_globals._saveData->data[svField340] = 0;
|
||||
}
|
||||
_vm->_soundManager.PLAY_SOUND("SOUND83.WAV");
|
||||
_vm->_objectsManager.OPTI_ONE(4, 0, 23, 0);
|
||||
@ -1931,21 +1931,21 @@ LABEL_1141:
|
||||
|
||||
_vm->_eventsManager.VBL();
|
||||
}
|
||||
CharacterLocation *v51 = &_vm->_globals.SAUVEGARDE->_realHopkins;
|
||||
CharacterLocation *v51 = &_vm->_globals._saveData->_realHopkins;
|
||||
v51->_pos.x = _vm->_objectsManager.getSpriteX(0);
|
||||
v51->_pos.y = _vm->_objectsManager.getSpriteY(0);
|
||||
v51->field2 = 57;
|
||||
v51->_location = 97;
|
||||
_vm->_globals.SAUVEGARDE->data[svField121] = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[svField352] = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[svField353] = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[svField354] = 1;
|
||||
_vm->_globals._saveData->data[svField121] = 1;
|
||||
_vm->_globals._saveData->data[svField352] = 1;
|
||||
_vm->_globals._saveData->data[svField353] = 1;
|
||||
_vm->_globals._saveData->data[svField354] = 1;
|
||||
}
|
||||
if (v76 == 56) {
|
||||
_vm->_fileManager.constructFilename(_vm->_globals.HOPSYSTEM, "HOPFEM.SPR");
|
||||
_vm->_globals.PERSO = _vm->_fileManager.loadFile(_vm->_globals.NFICHIER);
|
||||
_vm->_globals.PERSO_TYPE = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[svField122] = 1;
|
||||
_vm->_globals._saveData->data[svField122] = 1;
|
||||
_vm->_globals.HOPKINS_DATA();
|
||||
_vm->_objectsManager._sprite[0].field12 = 28;
|
||||
_vm->_objectsManager._sprite[0].field14 = 155;
|
||||
@ -1955,7 +1955,7 @@ LABEL_1141:
|
||||
_vm->_fileManager.constructFilename(_vm->_globals.HOPSYSTEM, "PERSO.SPR");
|
||||
_vm->_globals.PERSO = _vm->_fileManager.loadFile(_vm->_globals.NFICHIER);
|
||||
_vm->_globals.PERSO_TYPE = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField122] = 0;
|
||||
_vm->_globals._saveData->data[svField122] = 0;
|
||||
_vm->_globals.HOPKINS_DATA();
|
||||
_vm->_objectsManager._sprite[0].field12 = 34;
|
||||
_vm->_objectsManager._sprite[0].field14 = 190;
|
||||
@ -1966,13 +1966,13 @@ LABEL_1141:
|
||||
if (v76 == 26)
|
||||
_vm->_talkManager.PARLER_PERSO("AGENT2.pe2");
|
||||
if (v76 == 87) {
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField188])
|
||||
if (_vm->_globals._saveData->data[svField188])
|
||||
_vm->_talkManager.PARLER_PERSO("stand2.pe2");
|
||||
else
|
||||
_vm->_talkManager.PARLER_PERSO("stand1.pe2");
|
||||
}
|
||||
if (v76 == 86) {
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField231] == 1) {
|
||||
if (_vm->_globals._saveData->data[svField231] == 1) {
|
||||
_vm->_talkManager.PARLER_PERSO("chotess1.pe2");
|
||||
} else {
|
||||
_vm->_globals.NOPARLE = true;
|
||||
@ -2007,7 +2007,7 @@ LABEL_1141:
|
||||
_vm->_objectsManager.stopBobAnimation(2);
|
||||
_vm->_graphicsManager.FADE_OUTW();
|
||||
_vm->_graphicsManager.NOFADE = true;
|
||||
_vm->_globals.SORTIE = 20;
|
||||
_vm->_globals._exitId = 20;
|
||||
}
|
||||
if (v76 == 41)
|
||||
_vm->_talkManager.PARLER_PERSO("MORT3.pe2");
|
||||
@ -2026,13 +2026,13 @@ LABEL_1141:
|
||||
if (v76 == 21)
|
||||
_vm->_talkManager.PARLER_PERSO("MEDLEG.pe2");
|
||||
if (v76 == 94) {
|
||||
if (!_vm->_globals.SAUVEGARDE->data[svField228])
|
||||
if (!_vm->_globals._saveData->data[svField228])
|
||||
_vm->_talkManager.PARLER_PERSO("flicn.pe2");
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField228] == 1)
|
||||
if (_vm->_globals._saveData->data[svField228] == 1)
|
||||
_vm->_talkManager.PARLER_PERSO("flicn1.pe2");
|
||||
}
|
||||
if (v76 == 27) {
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField94] != 1 || _vm->_globals.SAUVEGARDE->data[svField95] != 1)
|
||||
if (_vm->_globals._saveData->data[svField94] != 1 || _vm->_globals._saveData->data[svField95] != 1)
|
||||
_vm->_talkManager.PARLER_PERSO("STANDAR.pe2");
|
||||
else
|
||||
_vm->_talkManager.PARLER_PERSO("STANDAR1.pe2");
|
||||
@ -2040,8 +2040,8 @@ LABEL_1141:
|
||||
if (v76 == 58) {
|
||||
_vm->_globals.NOPARLE = true;
|
||||
_vm->_talkManager.PARLER_PERSO("Gm1.PE2");
|
||||
_vm->_globals.SAUVEGARDE->data[svField176] = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[svField270] = 2;
|
||||
_vm->_globals._saveData->data[svField176] = 1;
|
||||
_vm->_globals._saveData->data[svField270] = 2;
|
||||
_vm->_globals.NOPARLE = false;
|
||||
}
|
||||
if (v76 == 200) {
|
||||
@ -2146,7 +2146,7 @@ LABEL_1141:
|
||||
_vm->_talkManager.PARLER_PERSO("tahi1.pe2");
|
||||
if (v76 == 243) {
|
||||
_vm->_soundManager.PLAY_SOUND("SOUND88.WAV");
|
||||
if (_vm->_globals.SAUVEGARDE->data[svField341] == 2) {
|
||||
if (_vm->_globals._saveData->data[svField341] == 2) {
|
||||
_vm->_animationManager.NO_SEQ = true;
|
||||
_vm->_animationManager.playSequence("RESU.SEQ", 2, 24, 2);
|
||||
_vm->_animationManager.NO_SEQ = false;
|
||||
@ -2159,21 +2159,21 @@ LABEL_1141:
|
||||
_vm->_animationManager.NO_SEQ = true;
|
||||
_vm->_animationManager.playSequence("RESUF.SEQ", 1, 24, 1);
|
||||
_vm->_animationManager.NO_SEQ = false;
|
||||
CharacterLocation *v53 = &_vm->_globals.SAUVEGARDE->_samantha;
|
||||
CharacterLocation *v53 = &_vm->_globals._saveData->_samantha;
|
||||
v53->_pos.x = 404;
|
||||
v53->_pos.y = 395;
|
||||
v53->field2 = 64;
|
||||
v53->_location = _vm->_globals.ECRAN;
|
||||
v53->_location = _vm->_globals._screenId;
|
||||
|
||||
int v54 = _vm->_globals.STAILLE[790 / 2];
|
||||
if (_vm->_globals.STAILLE[790 / 2] < 0)
|
||||
v54 = -_vm->_globals.STAILLE[790 / 2];
|
||||
v76 = -(100 * (67 - (100 - v54)) / 67);
|
||||
v53->field4 = v76;
|
||||
_vm->_globals.SAUVEGARDE->data[svField357] = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[svField354] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField356] = 0;
|
||||
_vm->_globals.SAUVEGARDE->data[svField355] = 1;
|
||||
_vm->_globals._saveData->data[svField357] = 1;
|
||||
_vm->_globals._saveData->data[svField354] = 0;
|
||||
_vm->_globals._saveData->data[svField356] = 0;
|
||||
_vm->_globals._saveData->data[svField355] = 1;
|
||||
_vm->_objectsManager.DEUXPERSO = true;
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 373, 191, 3);
|
||||
_vm->_objectsManager.SPRITE(_vm->_globals.TETE, v53->_pos, 1, 3, v53->field4, 0, 20, 127);
|
||||
@ -2185,7 +2185,7 @@ LABEL_1141:
|
||||
_vm->_globals.ZONEP[4]._destX = 276;
|
||||
_vm->_objectsManager.VERBE_ON(4, 19);
|
||||
_vm->_graphicsManager.AFFICHE_SPEED(_vm->_globals.SPRITE_ECRAN, 285, 379, 0);
|
||||
_vm->_globals.SAUVEGARDE->data[svField399] = 1;
|
||||
_vm->_globals._saveData->data[svField399] = 1;
|
||||
}
|
||||
if (v76 == 246) {
|
||||
_vm->_objectsManager.removeSprite(0);
|
||||
@ -2198,7 +2198,7 @@ LABEL_1141:
|
||||
_vm->_graphicsManager.NOFADE = true;
|
||||
_vm->_graphicsManager.FADE_OUTW();
|
||||
_vm->_objectsManager.PERSO_ON = false;
|
||||
_vm->_globals.SORTIE = 100;
|
||||
_vm->_globals._exitId = 100;
|
||||
}
|
||||
if (v76 == 55) {
|
||||
_vm->_objectsManager.stopBobAnimation(1);
|
||||
@ -2232,7 +2232,7 @@ LABEL_1141:
|
||||
_vm->_objectsManager.GOHOME();
|
||||
_vm->_eventsManager.VBL();
|
||||
} while (_vm->_globals.chemin != (int16 *)g_PTRNUL);
|
||||
_vm->_globals.SORTIE = 59;
|
||||
_vm->_globals._exitId = 59;
|
||||
}
|
||||
if (v76 == 173) {
|
||||
_vm->_globals.NOPARLE = true;
|
||||
@ -2256,7 +2256,7 @@ LABEL_1141:
|
||||
_vm->_objectsManager.GOHOME();
|
||||
_vm->_eventsManager.VBL();
|
||||
} while (_vm->_globals.chemin != (int16 *)g_PTRNUL);
|
||||
_vm->_globals.SORTIE = 59;
|
||||
_vm->_globals._exitId = 59;
|
||||
}
|
||||
if (v76 == 174)
|
||||
_vm->_talkManager.PARLER_PERSO("Profbl.pe2");
|
||||
@ -2271,11 +2271,11 @@ LABEL_1141:
|
||||
v1 = 4;
|
||||
if (*(a1 + 2) == 'V' && *(a1 + 3) == 'A' && *(a1 + 4) == 'L') {
|
||||
v1 = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[(int16)READ_LE_UINT16(a1 + 5)] = (int16)READ_LE_UINT16(a1 + 7);
|
||||
_vm->_globals._saveData->data[(int16)READ_LE_UINT16(a1 + 5)] = (int16)READ_LE_UINT16(a1 + 7);
|
||||
}
|
||||
if (*(a1 + 2) == 'A' && *(a1 + 3) == 'D' && *(a1 + 4) == 'D') {
|
||||
v1 = 1;
|
||||
_vm->_globals.SAUVEGARDE->data[(int16)READ_LE_UINT16(a1 + 5)] += *(a1 + 7);
|
||||
_vm->_globals._saveData->data[(int16)READ_LE_UINT16(a1 + 5)] += *(a1 + 7);
|
||||
}
|
||||
if (*(a1 + 2) == 'B' && *(a1 + 3) == 'O' && *(a1 + 4) == 'S') {
|
||||
v1 = 1;
|
||||
@ -2314,28 +2314,16 @@ LABEL_1141:
|
||||
}
|
||||
|
||||
|
||||
int ScriptManager::Control_Goto(const byte *dataP) {
|
||||
int ScriptManager::handleGoto(const byte *dataP) {
|
||||
return (int16)READ_LE_UINT16(dataP + 5);
|
||||
}
|
||||
|
||||
int ScriptManager::Control_If(const byte *dataP, int a2) {
|
||||
int ScriptManager::handleIf(const byte *dataP, int a2) {
|
||||
int v2;
|
||||
int v3;
|
||||
int v4;
|
||||
int v5;
|
||||
int v6;
|
||||
int v7;
|
||||
const byte *v8;
|
||||
int v9;
|
||||
int v10;
|
||||
int v11;
|
||||
int v12;
|
||||
int v14;
|
||||
int v15;
|
||||
int v16;
|
||||
int v17;
|
||||
int v18;
|
||||
int v19;
|
||||
bool v7;
|
||||
int v20;
|
||||
|
||||
v2 = a2;
|
||||
@ -2347,99 +2335,71 @@ LABEL_2:
|
||||
|
||||
++v3;
|
||||
v4 = Traduction2(dataP + 20 * v3);
|
||||
if (v3 > 400) {
|
||||
v5 = v4;
|
||||
if (v3 > 400)
|
||||
error("Control if failed");
|
||||
v4 = v5;
|
||||
}
|
||||
} while (v4 != 4);
|
||||
v20 = v3;
|
||||
v6 = v2;
|
||||
v7 = 0;
|
||||
v7 = false;
|
||||
do {
|
||||
if (_vm->shouldQuit())
|
||||
return 0; // Exiting game
|
||||
|
||||
++v6;
|
||||
if (Traduction2(dataP + 20 * v6) == 3)
|
||||
v7 = 1;
|
||||
v7 = true;
|
||||
if (v6 > 400)
|
||||
error("Control if failed ");
|
||||
if (v7 == 1) {
|
||||
if (v7) {
|
||||
v2 = v20;
|
||||
goto LABEL_2;
|
||||
}
|
||||
} while (v20 != v6);
|
||||
v8 = dataP + 20 * a2;
|
||||
v9 = *(v8 + 13);
|
||||
v17 = *(v8 + 14);
|
||||
v16 = *(v8 + 15);
|
||||
v10 = (int16)READ_LE_UINT16(v8 + 5);
|
||||
v11 = (int16)READ_LE_UINT16(v8 + 7);
|
||||
v19 = (int16)READ_LE_UINT16(v8 + 9);
|
||||
v18 = (int16)READ_LE_UINT16(v8 + 11);
|
||||
v14 = 0;
|
||||
v15 = 0;
|
||||
if (v9 == 1 && _vm->_globals.SAUVEGARDE->data[v10] == v11)
|
||||
v14 = 1;
|
||||
if (v9 == 2 && _vm->_globals.SAUVEGARDE->data[v10] != v11)
|
||||
v14 = 1;
|
||||
if (v9 == 3 && _vm->_globals.SAUVEGARDE->data[v10] <= v11)
|
||||
v14 = 1;
|
||||
if (v9 == 4 && _vm->_globals.SAUVEGARDE->data[v10] >= v11)
|
||||
v14 = 1;
|
||||
if (v9 == 5 && _vm->_globals.SAUVEGARDE->data[v10] > v11)
|
||||
v14 = 1;
|
||||
if (v9 == 6 && _vm->_globals.SAUVEGARDE->data[v10] < v11)
|
||||
v14 = 1;
|
||||
if (v16 == 3)
|
||||
goto LABEL_68;
|
||||
if (v17 == 1 && v18 == _vm->_globals.SAUVEGARDE->data[v19])
|
||||
v15 = 1;
|
||||
if (v17 == 2 && v18 != _vm->_globals.SAUVEGARDE->data[v19])
|
||||
v15 = 1;
|
||||
if (v17 == 3 && v18 >= _vm->_globals.SAUVEGARDE->data[v19])
|
||||
v15 = 1;
|
||||
if (v17 == 4 && v18 <= _vm->_globals.SAUVEGARDE->data[v19])
|
||||
v15 = 1;
|
||||
if (v17 == 5 && v18 < _vm->_globals.SAUVEGARDE->data[v19])
|
||||
v15 = 1;
|
||||
if (v17 == 6 && v18 > _vm->_globals.SAUVEGARDE->data[v19])
|
||||
v15 = 1;
|
||||
if (v16 == 3) {
|
||||
LABEL_68:
|
||||
if (v14 == 1) {
|
||||
v12 = a2;
|
||||
return (v12 + 1);
|
||||
}
|
||||
if (!v14) {
|
||||
LABEL_63:
|
||||
v12 = v20;
|
||||
return (v12 + 1);
|
||||
}
|
||||
|
||||
const byte *buf = dataP + 20 * a2;
|
||||
byte oper = buf[13];
|
||||
byte oper2 = buf[14];
|
||||
byte operType = buf[15];
|
||||
int saveDataIdx1 = (int16)READ_LE_UINT16(buf + 5);
|
||||
int compVal1 = (int16)READ_LE_UINT16(buf + 7);
|
||||
bool check1Fl = false;
|
||||
if ((oper == 1 && _vm->_globals._saveData->data[saveDataIdx1] == compVal1) ||
|
||||
(oper == 2 && _vm->_globals._saveData->data[saveDataIdx1] != compVal1) ||
|
||||
(oper == 3 && _vm->_globals._saveData->data[saveDataIdx1] <= compVal1) ||
|
||||
(oper == 4 && _vm->_globals._saveData->data[saveDataIdx1] >= compVal1) ||
|
||||
(oper == 5 && _vm->_globals._saveData->data[saveDataIdx1] > compVal1) ||
|
||||
(oper == 6 && _vm->_globals._saveData->data[saveDataIdx1] < compVal1))
|
||||
check1Fl = true;
|
||||
|
||||
bool check2Fl = false;
|
||||
if (operType != 3) {
|
||||
int saveDataIdx2 = (int16)READ_LE_UINT16(buf + 9);
|
||||
int compVal2 = (int16)READ_LE_UINT16(buf + 11);
|
||||
if ((oper2 == 1 && compVal2 == _vm->_globals._saveData->data[saveDataIdx2]) ||
|
||||
(oper2 == 2 && compVal2 != _vm->_globals._saveData->data[saveDataIdx2]) ||
|
||||
(oper2 == 3 && compVal2 >= _vm->_globals._saveData->data[saveDataIdx2]) ||
|
||||
(oper2 == 4 && compVal2 <= _vm->_globals._saveData->data[saveDataIdx2]) ||
|
||||
(oper2 == 5 && compVal2 < _vm->_globals._saveData->data[saveDataIdx2]) ||
|
||||
(oper2 == 6 && compVal2 > _vm->_globals._saveData->data[saveDataIdx2]))
|
||||
check2Fl = true;
|
||||
}
|
||||
if (v16 == 1) {
|
||||
if (v14 == 1 && v15 == 1) {
|
||||
v12 = a2;
|
||||
return (v12 + 1);
|
||||
}
|
||||
goto LABEL_63;
|
||||
|
||||
if ((operType == 3) && check1Fl) {
|
||||
return (a2 + 1);
|
||||
} else if ((operType == 1) && check1Fl && check2Fl) {
|
||||
return (a2 + 1);
|
||||
} else if ((operType == 2) && (check1Fl || check2Fl)) {
|
||||
return (a2 + 1);
|
||||
}
|
||||
if (v16 == 2) {
|
||||
if (v14 == 1 || v15 == 1) {
|
||||
v12 = a2;
|
||||
return (v12 + 1);
|
||||
}
|
||||
goto LABEL_63;
|
||||
}
|
||||
return -1;
|
||||
|
||||
return (v20 + 1);
|
||||
}
|
||||
|
||||
int ScriptManager::Traduction2(const byte *dataP) {
|
||||
int16 result;
|
||||
|
||||
result = 0;
|
||||
if (*dataP != 'F' || *(dataP + 1) != 'C') {
|
||||
if (dataP[0] != 'F' || dataP[1] != 'C') {
|
||||
result = 0;
|
||||
} else {
|
||||
if (*(dataP + 'T') == 84 && *(dataP + 3) == 'X' && *(dataP + 4) == 'T')
|
||||
|
@ -41,8 +41,8 @@ public:
|
||||
|
||||
int Traduction(byte *a1);
|
||||
int Traduction2(const byte *dataP);
|
||||
int Control_Goto(const byte *dataP);
|
||||
int Control_If(const byte *dataP, int a2);
|
||||
int handleGoto(const byte *dataP);
|
||||
int handleIf(const byte *dataP, int a2);
|
||||
};
|
||||
|
||||
} // End of namespace Hopkins
|
||||
|
@ -76,7 +76,7 @@ void TalkManager::PARLER_PERSO(const Common::String &filename) {
|
||||
_characterBuffer = _vm->_fileManager.loadFile(_vm->_globals.NFICHIER);
|
||||
_characterSize = _vm->_fileManager.fileSize(_vm->_globals.NFICHIER);
|
||||
}
|
||||
_vm->_globals.SAUVEGARDE->data[svField4] = 0;
|
||||
_vm->_globals._saveData->data[svField4] = 0;
|
||||
RENVOIE_FICHIER(40, v16, (const char *)_characterBuffer);
|
||||
RENVOIE_FICHIER(0, _questionsFilename, (const char *)_characterBuffer);
|
||||
RENVOIE_FICHIER(20, _answersFilename, (const char *)_characterBuffer);
|
||||
@ -189,7 +189,7 @@ void TalkManager::PARLER_PERSO2(const Common::String &filename) {
|
||||
_characterSize = _vm->_fileManager.fileSize(_vm->_globals.NFICHIER);
|
||||
}
|
||||
|
||||
_vm->_globals.SAUVEGARDE->data[svField4] = 0;
|
||||
_vm->_globals._saveData->data[svField4] = 0;
|
||||
RENVOIE_FICHIER(0, _questionsFilename, (const char *)_characterBuffer);
|
||||
RENVOIE_FICHIER(20, _answersFilename, (const char *)_characterBuffer);
|
||||
|
||||
@ -427,7 +427,7 @@ int TalkManager::DIALOGUE_REP(int idx) {
|
||||
v7 = (int16)READ_LE_UINT16((uint16 *)v3 + 9);
|
||||
|
||||
if (v7)
|
||||
_vm->_globals.SAUVEGARDE->data[svField4] = v7;
|
||||
_vm->_globals._saveData->data[svField4] = v7;
|
||||
|
||||
if (!v6)
|
||||
v6 = 10;
|
||||
@ -1009,9 +1009,9 @@ LABEL_2:
|
||||
return;
|
||||
|
||||
if (v10 == 2)
|
||||
v13 = _vm->_scriptManager.Control_Goto(ptr + 20 * v13);
|
||||
v13 = _vm->_scriptManager.handleGoto(ptr + 20 * v13);
|
||||
else if (v10 == 3)
|
||||
v13 = _vm->_scriptManager.Control_If(ptr, v13);
|
||||
v13 = _vm->_scriptManager.handleIf(ptr, v13);
|
||||
|
||||
if (v13 == -1)
|
||||
error("Invalid IFF function");
|
||||
@ -1028,7 +1028,7 @@ LABEL_2:
|
||||
}
|
||||
} while (!loopCond);
|
||||
_vm->_globals.freeMemory(ptr);
|
||||
_vm->_globals.SAUVEGARDE->data[svField2] = 0;
|
||||
_vm->_globals._saveData->data[svField2] = 0;
|
||||
return;
|
||||
}
|
||||
}
|
||||
@ -1037,7 +1037,7 @@ LABEL_2:
|
||||
|
||||
void TalkManager::REPONSE2(int a1, int a2) {
|
||||
int indx = 0;
|
||||
if (a2 == 5 && _vm->_globals.SAUVEGARDE->data[svField3] == 4) {
|
||||
if (a2 == 5 && _vm->_globals._saveData->data[svField3] == 4) {
|
||||
if (a1 == 22 || a1 == 23) {
|
||||
_vm->_objectsManager.setFlipSprite(0, false);
|
||||
_vm->_objectsManager.setSpriteIndex(0, 62);
|
||||
@ -1060,7 +1060,7 @@ void TalkManager::REPONSE2(int a1, int a2) {
|
||||
_vm->_objectsManager.stopBobAnimation(6);
|
||||
_vm->_objectsManager.setBobAnimation(8);
|
||||
|
||||
switch (_vm->_globals.ECRAN) {
|
||||
switch (_vm->_globals._screenId) {
|
||||
case 35:
|
||||
indx = 201;
|
||||
break;
|
||||
@ -1083,7 +1083,7 @@ void TalkManager::REPONSE2(int a1, int a2) {
|
||||
indx = 213;
|
||||
break;
|
||||
}
|
||||
_vm->_globals.SAUVEGARDE->data[indx] = 2;
|
||||
_vm->_globals._saveData->data[indx] = 2;
|
||||
_vm->_objectsManager.ZONE_OFF(22);
|
||||
_vm->_objectsManager.ZONE_OFF(23);
|
||||
} else if (a1 == 20 || a1 == 21) {
|
||||
@ -1107,7 +1107,7 @@ void TalkManager::REPONSE2(int a1, int a2) {
|
||||
while (_vm->_objectsManager.BOBPOSI(5) < 12);
|
||||
_vm->_objectsManager.stopBobAnimation(5);
|
||||
_vm->_objectsManager.setBobAnimation(7);
|
||||
switch (_vm->_globals.ECRAN) {
|
||||
switch (_vm->_globals._screenId) {
|
||||
case 35:
|
||||
indx = 200;
|
||||
break;
|
||||
@ -1130,7 +1130,7 @@ void TalkManager::REPONSE2(int a1, int a2) {
|
||||
indx = 212;
|
||||
break;
|
||||
}
|
||||
_vm->_globals.SAUVEGARDE->data[indx] = 2;
|
||||
_vm->_globals._saveData->data[indx] = 2;
|
||||
_vm->_objectsManager.ZONE_OFF(21);
|
||||
_vm->_objectsManager.ZONE_OFF(20);
|
||||
}
|
||||
@ -1177,7 +1177,7 @@ void TalkManager::OBJET_VIVANT(const Common::String &a2) {
|
||||
v5 = 5;
|
||||
|
||||
if (v20 == "NULL")
|
||||
v20 = Common::String::format("IM%d", _vm->_globals.ECRAN);
|
||||
v20 = Common::String::format("IM%d", _vm->_globals._screenId);
|
||||
|
||||
_characterSprite = _vm->_fileManager.searchCat(v23, 7);
|
||||
if (_characterSprite)
|
||||
@ -1228,7 +1228,7 @@ void TalkManager::OBJET_VIVANT(const Common::String &a2) {
|
||||
if (_vm->_globals.GOACTION)
|
||||
_vm->_objectsManager.PARADISE();
|
||||
_vm->_eventsManager.VBL();
|
||||
} while (!_vm->_globals.SORTIE);
|
||||
} while (!_vm->_globals._exitId);
|
||||
FIN_VISU_PARLE();
|
||||
FIN_VISU_WAIT();
|
||||
clearCharacterAnim();
|
||||
@ -1252,8 +1252,8 @@ void TalkManager::OBJET_VIVANT(const Common::String &a2) {
|
||||
_vm->_graphicsManager.INI_ECRAN2(v20);
|
||||
_vm->_objectsManager.DESACTIVE = false;
|
||||
_vm->_globals.NOMARCHE = false;
|
||||
if (_vm->_globals.SORTIE == 101)
|
||||
_vm->_globals.SORTIE = 0;
|
||||
if (_vm->_globals._exitId == 101)
|
||||
_vm->_globals._exitId = 0;
|
||||
|
||||
_vm->_saveLoadManager.load("TEMP.SCR", _vm->_graphicsManager._vesaScreen);
|
||||
g_system->getSavefileManager()->removeSavefile("TEMP.SCR");
|
||||
|
Loading…
Reference in New Issue
Block a user