mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-18 15:48:48 +00:00
HOPKINS: Some more function renaming
This commit is contained in:
parent
663bf3139f
commit
269a6f9cae
@ -790,8 +790,8 @@ int AnimationManager::loadSpriteBank(int idx, const Common::String &filename) {
|
||||
int height;
|
||||
do {
|
||||
ptr = v4;
|
||||
width = _vm->_objectsManager.Get_Largeur(v4, v8);
|
||||
height = _vm->_objectsManager.Get_Hauteur(ptr, v8);
|
||||
width = _vm->_objectsManager.getWidth(v4, v8);
|
||||
height = _vm->_objectsManager.getHeight(ptr, v8);
|
||||
v4 = ptr;
|
||||
if (!width && !height)
|
||||
loopCond = true;
|
||||
|
@ -37,10 +37,10 @@ namespace Hopkins {
|
||||
|
||||
DialogsManager::DialogsManager() {
|
||||
INVENTFLAG = false;
|
||||
AFFINVEN = false;
|
||||
_inventDisplayedFl = false;
|
||||
VIRE_INVENT = false;
|
||||
inventairex = inventairey = 0;
|
||||
inventairel = inventaireh = 0;
|
||||
_inventX = _inventY = 0;
|
||||
_inventWidth = _inventHeight = 0;
|
||||
Winventaire = NULL;
|
||||
inventaire2 = g_PTRNUL;
|
||||
}
|
||||
@ -302,7 +302,7 @@ void DialogsManager::showOptionsDialog() {
|
||||
}
|
||||
|
||||
void DialogsManager::showInventory() {
|
||||
if (!VIRE_INVENT && !AFFINVEN && !_vm->_globals.DESACTIVE_INVENT) {
|
||||
if (!VIRE_INVENT && !_inventDisplayedFl && !_vm->_globals.DESACTIVE_INVENT) {
|
||||
_vm->_graphicsManager.no_scroll = 1;
|
||||
_vm->_objectsManager.FLAG_VISIBLE_EFFACE = 4;
|
||||
_vm->_objectsManager.FLAG_VISIBLE = false;
|
||||
@ -343,13 +343,12 @@ LABEL_7:
|
||||
|
||||
_vm->_fileManager.constructFilename(_vm->_globals.HOPSYSTEM, "INVENT2.SPR");
|
||||
inventaire2 = _vm->_fileManager.loadFile(_vm->_globals.NFICHIER);
|
||||
int v19 = _vm->_graphicsManager.ofscroll + 152;
|
||||
int v18 = _vm->_objectsManager.Get_Largeur(_vm->_dialogsManager.Winventaire, 0);
|
||||
int v17 = _vm->_objectsManager.Get_Hauteur(_vm->_dialogsManager.Winventaire, 0);
|
||||
inventairex = v19;
|
||||
inventairey = 114;
|
||||
inventairel = v18;
|
||||
inventaireh = v17;
|
||||
|
||||
int v19 = _inventX = _vm->_graphicsManager.ofscroll + 152;
|
||||
_inventY = 114;
|
||||
int v18 = _inventWidth = _vm->_objectsManager.getWidth(_vm->_dialogsManager.Winventaire, 0);
|
||||
int v17 = _inventHeight = _vm->_objectsManager.getHeight(_vm->_dialogsManager.Winventaire, 0);
|
||||
|
||||
_vm->_graphicsManager.Affiche_Perfect(_vm->_graphicsManager.VESA_BUFFER, _vm->_dialogsManager.Winventaire,
|
||||
v19 + 300, 414, 0, 0, 0, 0);
|
||||
int v15 = 0;
|
||||
@ -369,7 +368,7 @@ LABEL_7:
|
||||
};
|
||||
v15 += 38;
|
||||
}
|
||||
_vm->_graphicsManager.Capture_Mem(_vm->_graphicsManager.VESA_BUFFER, _vm->_dialogsManager.Winventaire, inventairex, inventairey, inventairel, inventaireh);
|
||||
_vm->_graphicsManager.Capture_Mem(_vm->_graphicsManager.VESA_BUFFER, _vm->_dialogsManager.Winventaire, _inventX, _inventY, _inventWidth, _inventHeight);
|
||||
_vm->_eventsManager.souris_bb = 0;
|
||||
bool v20 = false;
|
||||
int v13 = 0;
|
||||
@ -377,7 +376,7 @@ LABEL_7:
|
||||
// Main loop to select an inventory item
|
||||
while (!_vm->shouldQuit()) {
|
||||
// Turn on drawing the inventory dialog in the event manager
|
||||
AFFINVEN = true;
|
||||
_inventDisplayedFl = true;
|
||||
|
||||
int v8 = _vm->_eventsManager.XMOUSE();
|
||||
int v9 = _vm->_eventsManager.YMOUSE();
|
||||
@ -430,7 +429,7 @@ LABEL_7:
|
||||
goto LABEL_7;
|
||||
}
|
||||
} else if (!v20) {
|
||||
AFFINVEN = true;
|
||||
_inventDisplayedFl = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -443,8 +442,8 @@ LABEL_7:
|
||||
_vm->_objectsManager.SPECIAL_JEU();
|
||||
}
|
||||
_vm->_fontManager.TEXTE_OFF(9);
|
||||
if (AFFINVEN) {
|
||||
AFFINVEN = false;
|
||||
if (_inventDisplayedFl) {
|
||||
_inventDisplayedFl = false;
|
||||
// v9 = 114;
|
||||
_vm->_graphicsManager.SCOPY(_vm->_graphicsManager.VESA_SCREEN, v19, 114, v18, v17, _vm->_graphicsManager.VESA_BUFFER, v19, 114);
|
||||
_vm->_graphicsManager.Ajoute_Segment_Vesa(v19, 114, v19 + v18, v18 + 114);
|
||||
@ -456,10 +455,10 @@ LABEL_7:
|
||||
|
||||
if (_vm->_eventsManager.btsouris == 1)
|
||||
showOptionsDialog();
|
||||
if (_vm->_eventsManager.btsouris == 3)
|
||||
_vm->_dialogsManager.CHARGE_PARTIE();
|
||||
if (_vm->_eventsManager.btsouris == 2)
|
||||
_vm->_dialogsManager.SAUVE_PARTIE();
|
||||
else if (_vm->_eventsManager.btsouris == 3)
|
||||
_vm->_dialogsManager.showLoadGame();
|
||||
else if (_vm->_eventsManager.btsouris == 2)
|
||||
_vm->_dialogsManager.showSaveGame();
|
||||
|
||||
_vm->_eventsManager.btsouris = 4;
|
||||
_vm->_eventsManager.CHANGE_MOUSE(4);
|
||||
@ -515,7 +514,10 @@ void DialogsManager::INVENT_ANIM() {
|
||||
}
|
||||
}
|
||||
|
||||
void DialogsManager::TestForDialogOpening() {
|
||||
/**
|
||||
* Test dialog opening
|
||||
*/
|
||||
void DialogsManager::testDialogOpening() {
|
||||
if (_vm->_globals.PLAN_FLAG)
|
||||
_vm->_eventsManager.GAME_KEY = KEY_NONE;
|
||||
|
||||
@ -536,12 +538,12 @@ void DialogsManager::TestForDialogOpening() {
|
||||
break;
|
||||
case KEY_LOAD:
|
||||
_vm->_graphicsManager.no_scroll = 1;
|
||||
_vm->_dialogsManager.CHARGE_PARTIE();
|
||||
_vm->_dialogsManager.showLoadGame();
|
||||
_vm->_graphicsManager.no_scroll = 0;
|
||||
break;
|
||||
case KEY_SAVE:
|
||||
_vm->_graphicsManager.no_scroll = 1;
|
||||
_vm->_dialogsManager.SAUVE_PARTIE();
|
||||
_vm->_dialogsManager.showSaveGame();
|
||||
_vm->_graphicsManager.no_scroll = 0;
|
||||
break;
|
||||
default:
|
||||
@ -554,15 +556,17 @@ void DialogsManager::TestForDialogOpening() {
|
||||
}
|
||||
}
|
||||
|
||||
// Load Game
|
||||
void DialogsManager::CHARGE_PARTIE() {
|
||||
/**
|
||||
* Load Game dialog
|
||||
*/
|
||||
void DialogsManager::showLoadGame() {
|
||||
int slotNumber;
|
||||
|
||||
_vm->_eventsManager.VBL();
|
||||
LOAD_SAUVE(2);
|
||||
showSaveLoad(2);
|
||||
do {
|
||||
do {
|
||||
slotNumber = CHERCHE_PARTIE();
|
||||
slotNumber = searchSavegames();
|
||||
_vm->_eventsManager.VBL();
|
||||
} while (_vm->_eventsManager.BMOUSE() != 1);
|
||||
} while (!slotNumber);
|
||||
@ -582,17 +586,19 @@ void DialogsManager::CHARGE_PARTIE() {
|
||||
_vm->_objectsManager.CHANGE_OBJET(14);
|
||||
}
|
||||
|
||||
// Save Game
|
||||
void DialogsManager::SAUVE_PARTIE() {
|
||||
/**
|
||||
* Save Game dialog
|
||||
*/
|
||||
void DialogsManager::showSaveGame() {
|
||||
int slotNumber;
|
||||
Common::String saveName;
|
||||
|
||||
_vm->_eventsManager.VBL();
|
||||
|
||||
LOAD_SAUVE(1);
|
||||
showSaveLoad(1);
|
||||
do {
|
||||
do {
|
||||
slotNumber = CHERCHE_PARTIE();
|
||||
slotNumber = searchSavegames();
|
||||
_vm->_eventsManager.VBL();
|
||||
} while (!_vm->shouldQuit() && _vm->_eventsManager.BMOUSE() != 1);
|
||||
} while (!_vm->shouldQuit() && !slotNumber);
|
||||
@ -615,9 +621,10 @@ void DialogsManager::SAUVE_PARTIE() {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Load Save
|
||||
void DialogsManager::LOAD_SAUVE(int a1) {
|
||||
/**
|
||||
* Load/Save dialog
|
||||
*/
|
||||
void DialogsManager::showSaveLoad(int a1) {
|
||||
int slotNumber;
|
||||
hopkinsSavegameHeader header;
|
||||
byte *thumb;
|
||||
@ -692,15 +699,13 @@ void DialogsManager::LOAD_SAUVE(int a1) {
|
||||
_vm->_objectsManager.SL_Y = 0;
|
||||
}
|
||||
|
||||
// Search Game
|
||||
int DialogsManager::CHERCHE_PARTIE() {
|
||||
int slotNumber;
|
||||
int xp;
|
||||
int yp;
|
||||
|
||||
slotNumber = 0;
|
||||
xp = _vm->_eventsManager.XMOUSE();
|
||||
yp = _vm->_eventsManager.YMOUSE();
|
||||
/**
|
||||
* Search savegames
|
||||
*/
|
||||
int DialogsManager::searchSavegames() {
|
||||
int slotNumber = 0;
|
||||
int xp = _vm->_eventsManager.XMOUSE();
|
||||
int yp = _vm->_eventsManager.YMOUSE();
|
||||
|
||||
_vm->_graphicsManager.ofscroll = _vm->_eventsManager.start_x;
|
||||
if ((uint16)(yp - 112) <= 0x56u) {
|
||||
|
@ -38,27 +38,27 @@ class DialogsManager {
|
||||
private:
|
||||
HopkinsEngine *_vm;
|
||||
public:
|
||||
int _inventX, _inventY;
|
||||
int _inventWidth, _inventHeight;
|
||||
|
||||
bool INVENTFLAG;
|
||||
bool AFFINVEN;
|
||||
bool _inventDisplayedFl;
|
||||
bool VIRE_INVENT;
|
||||
int inventairex, inventairey;
|
||||
int inventairel, inventaireh;
|
||||
byte *Winventaire;
|
||||
byte *inventaire2;
|
||||
public:
|
||||
DialogsManager();
|
||||
~DialogsManager();
|
||||
void setParent(HopkinsEngine *vm);
|
||||
|
||||
void showLoadGame();
|
||||
void showSaveGame();
|
||||
void showSaveLoad(int a1);
|
||||
void showOptionsDialog();
|
||||
void showInventory();
|
||||
int searchSavegames();
|
||||
void testDialogOpening();
|
||||
|
||||
void INVENT_ANIM();
|
||||
void TestForDialogOpening();
|
||||
void CHARGE_PARTIE();
|
||||
void SAUVE_PARTIE();
|
||||
void LOAD_SAUVE(int a1);
|
||||
int CHERCHE_PARTIE();
|
||||
};
|
||||
|
||||
} // End of namespace Hopkins
|
||||
|
@ -254,7 +254,7 @@ void FontManager::BOITE(int idx, int messageId, const Common::String &filename,
|
||||
byte v16 = *(v60 + v15);
|
||||
if ((byte)v16 <= 0x1Fu)
|
||||
v16 = 32;
|
||||
_vm->_globals.largeur_boite += _vm->_objectsManager.Get_Largeur(_vm->_globals.police, (byte)v16 - 32);
|
||||
_vm->_globals.largeur_boite += _vm->_objectsManager.getWidth(_vm->_globals.police, (byte)v16 - 32);
|
||||
}
|
||||
}
|
||||
_vm->_globals.largeur_boite += 2;
|
||||
@ -327,7 +327,7 @@ LABEL_57:
|
||||
byte v24 = (v23 >= (int)line.size()) ? '\0' : line.c_str()[v23];
|
||||
if ((byte)v24 <= 0x1Fu)
|
||||
v24 = 32;
|
||||
ptrc += _vm->_objectsManager.Get_Largeur(_vm->_globals.police, (byte)v24 - 32);
|
||||
ptrc += _vm->_objectsManager.getWidth(_vm->_globals.police, (byte)v24 - 32);
|
||||
}
|
||||
}
|
||||
TRIER_TEXT[i] = ptrc;
|
||||
@ -450,7 +450,7 @@ void FontManager::TEXT_NOW(int xp, int yp, const Common::String &message, int co
|
||||
charIndex = currChar - 32;
|
||||
_vm->_graphicsManager.Affiche_Fonte(_vm->_graphicsManager.VESA_BUFFER, _vm->_globals.police,
|
||||
currentX, yp, currChar - 32, col);
|
||||
currentX += _vm->_objectsManager.Get_Largeur(_vm->_globals.police, charIndex);
|
||||
currentX += _vm->_objectsManager.getWidth(_vm->_globals.police, charIndex);
|
||||
}
|
||||
}
|
||||
|
||||
@ -466,7 +466,7 @@ void FontManager::TEXT_NOW1(int xp, int yp, const Common::String &message, int c
|
||||
int characterIndex = currentChar - 32;
|
||||
_vm->_graphicsManager.Affiche_Fonte(_vm->_graphicsManager.VESA_BUFFER, _vm->_globals.police,
|
||||
xp, yp, characterIndex, col);
|
||||
xp += _vm->_objectsManager.Get_Largeur(_vm->_globals.police, characterIndex);
|
||||
xp += _vm->_objectsManager.getWidth(_vm->_globals.police, characterIndex);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -497,8 +497,8 @@ void FontManager::TEXT_COMPUT(int xp, int yp, const Common::String &msg, int col
|
||||
if (v7 >= 32) {
|
||||
v5 = v7 - 32;
|
||||
_vm->_graphicsManager.Affiche_Fonte(_vm->_graphicsManager.VESA_BUFFER, _vm->_globals.police, v9, yp, v7 - 32, fontCol);
|
||||
v9 += _vm->_objectsManager.Get_Largeur(_vm->_globals.police, v5);
|
||||
v6 = _vm->_objectsManager.Get_Largeur(_vm->_globals.police, v5);
|
||||
v9 += _vm->_objectsManager.getWidth(_vm->_globals.police, v5);
|
||||
v6 = _vm->_objectsManager.getWidth(_vm->_globals.police, v5);
|
||||
_vm->_graphicsManager.Ajoute_Segment_Vesa(v9 - v6, yp, v9, yp + 12);
|
||||
if (_vm->_eventsManager.ESC_KEY) {
|
||||
_vm->_globals.iRegul = 1;
|
||||
|
@ -604,8 +604,8 @@ void Globals::CHARGE_CACHE(const Common::String &file) {
|
||||
if (spriteData == g_PTRNUL) {
|
||||
Cache[i].fieldA = 0;
|
||||
} else {
|
||||
int v8 = _vm->_objectsManager.Get_Largeur(spriteData, v11);
|
||||
int v9 = _vm->_objectsManager.Get_Hauteur(spriteData, v11);
|
||||
int v8 = _vm->_objectsManager.getWidth(spriteData, v11);
|
||||
int v9 = _vm->_objectsManager.getHeight(spriteData, v11);
|
||||
Cache[i].fieldC = spriteData;
|
||||
Cache[i].field6 = v8;
|
||||
Cache[i].field8 = v9;
|
||||
|
@ -1636,8 +1636,8 @@ void GraphicsManager::Affiche_Segment_Vesa() {
|
||||
void GraphicsManager::AFFICHE_SPEEDVGA(const byte *objectData, int xp, int yp, int idx) {
|
||||
int height, width;
|
||||
|
||||
width = _vm->_objectsManager.Get_Largeur(objectData, idx);
|
||||
height = _vm->_objectsManager.Get_Hauteur(objectData, idx);
|
||||
width = _vm->_objectsManager.getWidth(objectData, idx);
|
||||
height = _vm->_objectsManager.getHeight(objectData, idx);
|
||||
if (*objectData == 78) {
|
||||
Affiche_Perfect(VESA_SCREEN, objectData, xp + 300, yp + 300, idx, 0, 0, 0);
|
||||
Affiche_Perfect(VESA_BUFFER, objectData, xp + 300, yp + 300, idx, 0, 0, 0);
|
||||
@ -2161,8 +2161,8 @@ Aff_Zoom_Larg_Cont1:
|
||||
void GraphicsManager::AFFICHE_SPEED(const byte *spriteData, int xp, int yp, int spriteIndex) {
|
||||
int width, height;
|
||||
|
||||
width = _vm->_objectsManager.Get_Largeur(spriteData, spriteIndex);
|
||||
height = _vm->_objectsManager.Get_Hauteur(spriteData, spriteIndex);
|
||||
width = _vm->_objectsManager.getWidth(spriteData, spriteIndex);
|
||||
height = _vm->_objectsManager.getHeight(spriteData, spriteIndex);
|
||||
if (*spriteData == 78) {
|
||||
Affiche_Perfect(VESA_SCREEN, spriteData, xp + 300, yp + 300, spriteIndex, 0, 0, 0);
|
||||
Affiche_Perfect(VESA_BUFFER, spriteData, xp + 300, yp + 300, spriteIndex, 0, 0, 0);
|
||||
|
@ -3603,7 +3603,7 @@ void HopkinsEngine::CREDIT_AFFICHE(int startPosY, byte *buffer, char colour) {
|
||||
if (!curChar)
|
||||
break;
|
||||
if (curChar > 31)
|
||||
strWidth += _objectsManager.Get_Largeur(_globals.police, curChar - 32);
|
||||
strWidth += _objectsManager.getWidth(_globals.police, curChar - 32);
|
||||
}
|
||||
int startPosX = 320 - strWidth / 2;
|
||||
int endPosX = strWidth + startPosX;
|
||||
@ -3630,7 +3630,7 @@ void HopkinsEngine::CREDIT_AFFICHE(int startPosY, byte *buffer, char colour) {
|
||||
break;
|
||||
if (curChar > 31) {
|
||||
_graphicsManager.Affiche_Fonte(_graphicsManager.VESA_BUFFER, _globals.police, startPosX, startPosY, curChar - 32, colour);
|
||||
startPosX += _objectsManager.Get_Largeur(_globals.police, curChar - 32);
|
||||
startPosX += _objectsManager.getWidth(_globals.police, curChar - 32);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -192,7 +192,7 @@ int MenuManager::MENU() {
|
||||
_vm->_eventsManager.delay(200);
|
||||
|
||||
_vm->_globals.SORTIE = -1;
|
||||
_vm->_dialogsManager.CHARGE_PARTIE();
|
||||
_vm->_dialogsManager.showLoadGame();
|
||||
|
||||
if (_vm->_globals.SORTIE != -1) {
|
||||
result = _vm->_globals.SORTIE;
|
||||
|
@ -126,8 +126,8 @@ byte *ObjectsManager::CAPTURE_OBJET(int objIndex, int mode) {
|
||||
_vm->_globals.NUM_FICHIER_OBJ = val1;
|
||||
}
|
||||
|
||||
int width = ObjectsManager::Get_Largeur(_vm->_globals.ADR_FICHIER_OBJ, val2);
|
||||
int height = ObjectsManager::Get_Hauteur(_vm->_globals.ADR_FICHIER_OBJ, val2);
|
||||
int width = ObjectsManager::getWidth(_vm->_globals.ADR_FICHIER_OBJ, val2);
|
||||
int height = ObjectsManager::getHeight(_vm->_globals.ADR_FICHIER_OBJ, val2);
|
||||
_vm->_globals.OBJL = width;
|
||||
_vm->_globals.OBJH = height;
|
||||
|
||||
@ -224,8 +224,10 @@ int ObjectsManager::get_offsety(const byte *spriteData, int spriteIndex, bool is
|
||||
return result;
|
||||
}
|
||||
|
||||
// Get Width
|
||||
int ObjectsManager::Get_Largeur(const byte *objectData, int idx) {
|
||||
/**
|
||||
* Get Width
|
||||
*/
|
||||
int ObjectsManager::getWidth(const byte *objectData, int idx) {
|
||||
const byte *rectP = objectData + 3;
|
||||
for (int i = idx; i; --i)
|
||||
rectP += READ_LE_UINT32(rectP) + 16;
|
||||
@ -233,8 +235,10 @@ int ObjectsManager::Get_Largeur(const byte *objectData, int idx) {
|
||||
return (int16)READ_LE_UINT16(rectP + 4);
|
||||
}
|
||||
|
||||
// Get height
|
||||
int ObjectsManager::Get_Hauteur(const byte *objectData, int idx) {
|
||||
/**
|
||||
* Get height
|
||||
*/
|
||||
int ObjectsManager::getHeight(const byte *objectData, int idx) {
|
||||
const byte *rectP = objectData + 3;
|
||||
for (int i = idx; i; --i)
|
||||
rectP += READ_LE_UINT32(rectP) + 16;
|
||||
@ -477,13 +481,13 @@ void ObjectsManager::AFF_SPRITES() {
|
||||
}
|
||||
|
||||
_vm->_globals.NBTRI = 0;
|
||||
if (_vm->_dialogsManager.AFFINVEN) {
|
||||
_vm->_graphicsManager.Restore_Mem(_vm->_graphicsManager.VESA_BUFFER, _vm->_dialogsManager.Winventaire, _vm->_dialogsManager.inventairex, _vm->_dialogsManager.inventairey, _vm->_dialogsManager.inventairel, _vm->_dialogsManager.inventaireh);
|
||||
if (_vm->_dialogsManager._inventDisplayedFl) {
|
||||
_vm->_graphicsManager.Restore_Mem(_vm->_graphicsManager.VESA_BUFFER, _vm->_dialogsManager.Winventaire, _vm->_dialogsManager._inventX, _vm->_dialogsManager._inventY, _vm->_dialogsManager._inventWidth, _vm->_dialogsManager._inventHeight);
|
||||
if (old_cadx && old_cady)
|
||||
_vm->_graphicsManager.Sprite_Vesa(_vm->_graphicsManager.VESA_BUFFER, _vm->_dialogsManager.inventaire2, old_cadx + 300, old_cady + 300, old_cadi + 1);
|
||||
if (cadx && cady)
|
||||
_vm->_graphicsManager.Sprite_Vesa(_vm->_graphicsManager.VESA_BUFFER, _vm->_dialogsManager.inventaire2, cadx + 300, cady + 300, cadi);
|
||||
_vm->_graphicsManager.Ajoute_Segment_Vesa(_vm->_dialogsManager.inventairex, _vm->_dialogsManager.inventairey, _vm->_dialogsManager.inventairex + _vm->_dialogsManager.inventairel, _vm->_dialogsManager.inventairey + _vm->_dialogsManager.inventaireh);
|
||||
_vm->_graphicsManager.Ajoute_Segment_Vesa(_vm->_dialogsManager._inventX, _vm->_dialogsManager._inventY, _vm->_dialogsManager._inventX + _vm->_dialogsManager._inventWidth, _vm->_dialogsManager._inventY + _vm->_dialogsManager._inventHeight);
|
||||
}
|
||||
|
||||
if (SL_FLAG == true) {
|
||||
@ -842,8 +846,8 @@ void ObjectsManager::CALCUL_BOB(int idx) {
|
||||
_vm->_globals.Liste2[idx].xp = v13;
|
||||
_vm->_globals.Liste2[idx].yp = v14;
|
||||
|
||||
int width = Get_Largeur(_vm->_globals.Bob[idx].spriteData, _vm->_globals.Bob[idx].frameIndex);
|
||||
int height = Get_Hauteur(_vm->_globals.Bob[idx].spriteData, _vm->_globals.Bob[idx].frameIndex);
|
||||
int width = getWidth(_vm->_globals.Bob[idx].spriteData, _vm->_globals.Bob[idx].frameIndex);
|
||||
int height = getHeight(_vm->_globals.Bob[idx].spriteData, _vm->_globals.Bob[idx].frameIndex);
|
||||
|
||||
if (v21) {
|
||||
width = _vm->_graphicsManager.Reel_Zoom(width, v21);
|
||||
@ -1122,8 +1126,8 @@ void ObjectsManager::CALCUL_SPRITE(int idx) {
|
||||
_vm->_globals.Liste[v17].field0 = 1;
|
||||
_vm->_globals.Liste[v17].field2 = v15;
|
||||
_vm->_globals.Liste[v17].field4 = v16;
|
||||
width = Get_Largeur(Sprite[idx].spriteData, Sprite[idx].spriteIndex);
|
||||
height = Get_Hauteur(Sprite[idx].spriteData, Sprite[idx].spriteIndex);
|
||||
width = getWidth(Sprite[idx].spriteData, Sprite[idx].spriteIndex);
|
||||
height = getHeight(Sprite[idx].spriteData, Sprite[idx].spriteIndex);
|
||||
|
||||
if (zoomPercent) {
|
||||
width = _vm->_graphicsManager.Reel_Zoom(width, zoomPercent);
|
||||
@ -1354,8 +1358,8 @@ void ObjectsManager::AFF_VBOB() {
|
||||
int idx = 0;
|
||||
do {
|
||||
if (_vm->_globals.VBob[idx].field4 == 4) {
|
||||
width = Get_Largeur(_vm->_globals.VBob[idx].spriteData, _vm->_globals.VBob[idx].frameIndex);
|
||||
height = Get_Hauteur(_vm->_globals.VBob[idx].spriteData, _vm->_globals.VBob[idx].frameIndex);
|
||||
width = getWidth(_vm->_globals.VBob[idx].spriteData, _vm->_globals.VBob[idx].frameIndex);
|
||||
height = getHeight(_vm->_globals.VBob[idx].spriteData, _vm->_globals.VBob[idx].frameIndex);
|
||||
|
||||
_vm->_graphicsManager.Restore_Mem(_vm->_graphicsManager.VESA_SCREEN,
|
||||
_vm->_globals.VBob[idx].surface, _vm->_globals.VBob[idx].xp,
|
||||
@ -1386,8 +1390,8 @@ void ObjectsManager::AFF_VBOB() {
|
||||
}
|
||||
|
||||
if (_vm->_globals.VBob[idx].field4 == 3) {
|
||||
width = Get_Largeur(_vm->_globals.VBob[idx].oldSpriteData, _vm->_globals.VBob[idx].oldFrameIndex);
|
||||
height = Get_Hauteur(_vm->_globals.VBob[idx].oldSpriteData, _vm->_globals.VBob[idx].oldFrameIndex);
|
||||
width = getWidth(_vm->_globals.VBob[idx].oldSpriteData, _vm->_globals.VBob[idx].oldFrameIndex);
|
||||
height = getHeight(_vm->_globals.VBob[idx].oldSpriteData, _vm->_globals.VBob[idx].oldFrameIndex);
|
||||
|
||||
_vm->_graphicsManager.Restore_Mem(_vm->_graphicsManager.VESA_SCREEN,
|
||||
_vm->_globals.VBob[idx].surface, _vm->_globals.VBob[idx].oldX,
|
||||
@ -1415,8 +1419,8 @@ void ObjectsManager::AFF_VBOB() {
|
||||
}
|
||||
|
||||
if (_vm->_globals.VBob[idx].field4 == 1) {
|
||||
width = Get_Largeur(_vm->_globals.VBob[idx].spriteData, _vm->_globals.VBob[idx].frameIndex);
|
||||
height = Get_Hauteur(_vm->_globals.VBob[idx].spriteData, _vm->_globals.VBob[idx].frameIndex);
|
||||
width = getWidth(_vm->_globals.VBob[idx].spriteData, _vm->_globals.VBob[idx].frameIndex);
|
||||
height = getHeight(_vm->_globals.VBob[idx].spriteData, _vm->_globals.VBob[idx].frameIndex);
|
||||
|
||||
if (_vm->_globals.VBob[idx].surface != g_PTRNUL)
|
||||
_vm->_globals.dos_free2(_vm->_globals.VBob[idx].surface);
|
||||
@ -1564,13 +1568,13 @@ void ObjectsManager::SPRITE_GEL(int idx) {
|
||||
int ObjectsManager::SXSPR(int idx) {
|
||||
if (idx > 5)
|
||||
error("request of the size of a sprite x > MAX_SPRITE.");
|
||||
return Get_Largeur(Sprite[idx].spriteData, Sprite[idx].spriteIndex);
|
||||
return getWidth(Sprite[idx].spriteData, Sprite[idx].spriteIndex);
|
||||
}
|
||||
|
||||
int ObjectsManager::SYSPR(int idx) {
|
||||
if (idx > 5)
|
||||
error("request of the size of a sprite y > MAX_SPRITE.");
|
||||
return Get_Hauteur(Sprite[idx].spriteData, Sprite[idx].spriteIndex);
|
||||
return getHeight(Sprite[idx].spriteData, Sprite[idx].spriteIndex);
|
||||
}
|
||||
|
||||
int ObjectsManager::POSISPR(int idx) {
|
||||
@ -4706,8 +4710,8 @@ void ObjectsManager::INILINK(const Common::String &file) {
|
||||
} else {
|
||||
v12 = v8;
|
||||
v13 = _vm->_globals.CACHE_BANQUE[1];
|
||||
v14 = Get_Largeur(v13, v8);
|
||||
v15 = Get_Hauteur(v13, v12);
|
||||
v14 = getWidth(v13, v8);
|
||||
v15 = getHeight(v13, v12);
|
||||
_vm->_globals.Cache[v40].fieldC = v13;
|
||||
_vm->_globals.Cache[v40].field6 = v14;
|
||||
_vm->_globals.Cache[v40].field8 = v15;
|
||||
@ -5571,7 +5575,7 @@ void ObjectsManager::PERSONAGE(const Common::String &backgroundFile, const Commo
|
||||
}
|
||||
if (v9 == 2)
|
||||
BTDROITE();
|
||||
_vm->_dialogsManager.TestForDialogOpening();
|
||||
_vm->_dialogsManager.testDialogOpening();
|
||||
VERIFZONE();
|
||||
if (_vm->_globals.GOACTION == 1)
|
||||
PARADISE();
|
||||
@ -5718,7 +5722,7 @@ LABEL_70:
|
||||
}
|
||||
}
|
||||
if (!_vm->_globals.SORTIE) {
|
||||
_vm->_dialogsManager.TestForDialogOpening();
|
||||
_vm->_dialogsManager.testDialogOpening();
|
||||
VERIFZONE();
|
||||
if (_vm->_globals.chemin == (int16 *)g_PTRNUL
|
||||
|| (GOHOME(), _vm->_globals.chemin == (int16 *)g_PTRNUL)) {
|
||||
|
@ -125,8 +125,8 @@ public:
|
||||
byte *CAPTURE_OBJET(int objIndex, int mode);
|
||||
void DELETE_OBJET(int objIndex);
|
||||
|
||||
int Get_Largeur(const byte *objectData, int idx);
|
||||
int Get_Hauteur(const byte *objectData, int idx);
|
||||
int getWidth(const byte *objectData, int idx);
|
||||
int getHeight(const byte *objectData, int idx);
|
||||
int sprite_alone(const byte *objectData, byte *sprite, int objIndex);
|
||||
byte *DEL_FICHIER_OBJ();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user