mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-13 21:31:53 +00:00
HOPKINS: Replaced many occurrences of 640 with SCREEN_WIDTH
This commit is contained in:
parent
9f9bf34ffd
commit
fc33d2d762
@ -74,7 +74,7 @@ LABEL_2:
|
||||
_vm->_graphicsManager.Cls_Video();
|
||||
_vm->_graphicsManager.DD_Unlock();
|
||||
}
|
||||
if (_vm->_graphicsManager.WinScan / _vm->_graphicsManager.Winbpp > 640) {
|
||||
if (_vm->_graphicsManager.WinScan / _vm->_graphicsManager.Winbpp > SCREEN_WIDTH) {
|
||||
hasScreenCopy = true;
|
||||
screenCopy = _vm->_globals.dos_malloc2(0x4B000u);
|
||||
memcpy(screenCopy, v10, 0x4B000u);
|
||||
@ -88,15 +88,15 @@ LABEL_2:
|
||||
_vm->_graphicsManager.DD_Lock();
|
||||
if (_vm->_graphicsManager.Winbpp == 2) {
|
||||
if (hasScreenCopy)
|
||||
_vm->_graphicsManager.m_scroll16A(screenCopy, 0, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll16A(screenCopy, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
else
|
||||
_vm->_graphicsManager.m_scroll16(v10, 0, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll16(v10, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
}
|
||||
if (_vm->_graphicsManager.Winbpp == 1) {
|
||||
if (hasScreenCopy)
|
||||
_vm->_graphicsManager.m_scroll2A(screenCopy, 0, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll2A(screenCopy, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
else
|
||||
_vm->_graphicsManager.m_scroll2(v10, 0, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll2(v10, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
}
|
||||
_vm->_graphicsManager.DD_Unlock();
|
||||
_vm->_graphicsManager.DD_VBL();
|
||||
@ -151,9 +151,9 @@ LABEL_38:
|
||||
if (*v10 != kByteStop) {
|
||||
_vm->_graphicsManager.Copy_WinScan_Vbe3(v10, screenCopy);
|
||||
if (_vm->_graphicsManager.Winbpp == 2)
|
||||
_vm->_graphicsManager.m_scroll16A(screenCopy, 0, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll16A(screenCopy, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
else
|
||||
_vm->_graphicsManager.m_scroll2A(screenCopy, 0, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll2A(screenCopy, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
}
|
||||
} else if (*v10 != kByteStop) {
|
||||
if (_vm->_graphicsManager.Winbpp == 1)
|
||||
@ -190,7 +190,7 @@ LABEL_57:
|
||||
_vm->_globals.dos_free2(ptr);
|
||||
f.close();
|
||||
|
||||
if (1 /*hasScreenCopy <= 640 */)
|
||||
if (1 /*hasScreenCopy <= SCREEN_WIDTH */)
|
||||
goto LABEL_2;
|
||||
goto LABEL_55;
|
||||
}
|
||||
|
@ -441,8 +441,8 @@ LABEL_65:
|
||||
}
|
||||
if (_vm->_graphicsManager.SCROLL < 0)
|
||||
_vm->_graphicsManager.SCROLL = 0;
|
||||
if (_vm->_graphicsManager.SCROLL > 640)
|
||||
_vm->_graphicsManager.SCROLL = 640;
|
||||
if (_vm->_graphicsManager.SCROLL > SCREEN_WIDTH)
|
||||
_vm->_graphicsManager.SCROLL = SCREEN_WIDTH;
|
||||
if (_vm->_graphicsManager.SDL_ECHELLE)
|
||||
v4 = _vm->_graphicsManager.Magic_Number(_vm->_graphicsManager.SCROLL);
|
||||
else
|
||||
@ -455,10 +455,10 @@ LABEL_65:
|
||||
if (_vm->_graphicsManager.SDL_ECHELLE) {
|
||||
if (_vm->_graphicsManager.Winbpp == 2) {
|
||||
int v5 = _vm->_graphicsManager.Reel_Zoom(0x14u, _vm->_graphicsManager.SDL_ECHELLE);
|
||||
_vm->_graphicsManager.m_scroll16A(_vm->_graphicsManager.VESA_BUFFER, v4, 20, 640, 440, 0, v5);
|
||||
_vm->_graphicsManager.m_scroll16A(_vm->_graphicsManager.VESA_BUFFER, v4, 20, SCREEN_WIDTH, 440, 0, v5);
|
||||
} else {
|
||||
int v6 = _vm->_graphicsManager.Reel_Zoom(0x14u, _vm->_graphicsManager.SDL_ECHELLE);
|
||||
_vm->_graphicsManager.m_scroll2A(_vm->_graphicsManager.VESA_BUFFER, v4, 20, 640, 440, 0, v6);
|
||||
_vm->_graphicsManager.m_scroll2A(_vm->_graphicsManager.VESA_BUFFER, v4, 20, SCREEN_WIDTH, 440, 0, v6);
|
||||
}
|
||||
_vm->_graphicsManager.DD_Unlock();
|
||||
_vm->_graphicsManager.dstrect[0].left = _vm->_graphicsManager.Reel_Zoom(0, _vm->_graphicsManager.SDL_ECHELLE);
|
||||
@ -467,11 +467,11 @@ LABEL_65:
|
||||
_vm->_graphicsManager.dstrect[0].setHeight(_vm->_graphicsManager.Reel_Zoom(0x1B8u, _vm->_graphicsManager.SDL_ECHELLE));
|
||||
} else {
|
||||
if (_vm->_graphicsManager.Winbpp == 2)
|
||||
_vm->_graphicsManager.m_scroll16(_vm->_graphicsManager.VESA_BUFFER, v4, 20, 640, 440, 0, 20);
|
||||
_vm->_graphicsManager.m_scroll16(_vm->_graphicsManager.VESA_BUFFER, v4, 20, SCREEN_WIDTH, 440, 0, 20);
|
||||
else
|
||||
_vm->_graphicsManager.m_scroll2(_vm->_graphicsManager.VESA_BUFFER, v4, 20, 640, 440, 0, 20);
|
||||
_vm->_graphicsManager.m_scroll2(_vm->_graphicsManager.VESA_BUFFER, v4, 20, SCREEN_WIDTH, 440, 0, 20);
|
||||
_vm->_graphicsManager.DD_Unlock();
|
||||
_vm->_graphicsManager.dstrect[0] = Common::Rect(0, 20, 640, 460);
|
||||
_vm->_graphicsManager.dstrect[0] = Common::Rect(0, 20, SCREEN_WIDTH, 460);
|
||||
}
|
||||
|
||||
// CHECKME: Useless?
|
||||
|
@ -1207,7 +1207,7 @@ void GraphicsManager::Copy_Video_Vbe16(const byte *srcData) {
|
||||
}
|
||||
}
|
||||
|
||||
if (destOffset > 640 * 480) {
|
||||
if (destOffset > SCREEN_WIDTH * SCREEN_HEIGHT) {
|
||||
warning("HACK: Stopping anim, out of bounds - 0x%x %d", srcByte, destOffset);
|
||||
return;
|
||||
}
|
||||
|
@ -1349,7 +1349,7 @@ LABEL_243:
|
||||
_globals.PERSO = _fileManager.CHARGE_FICHIER(_globals.NFICHIER);
|
||||
_globals.PERSO_TYPE = 0;
|
||||
_globals.iRegul = 0;
|
||||
_graphicsManager.nbrligne = 640;
|
||||
_graphicsManager.nbrligne = SCREEN_WIDTH;
|
||||
break;
|
||||
}
|
||||
}
|
||||
@ -1402,7 +1402,7 @@ void HopkinsEngine::processIniParams(Common::StringMap &iniParams) {
|
||||
|
||||
void HopkinsEngine::INIT_SYSTEM() {
|
||||
// Set graphics mode
|
||||
_graphicsManager.SET_MODE(640, 480);
|
||||
_graphicsManager.SET_MODE(SCREEN_WIDTH, SCREEN_HEIGHT);
|
||||
|
||||
// Synchronise the sound settings from ScummVM
|
||||
_soundManager.syncSoundSettings();
|
||||
@ -1749,8 +1749,8 @@ void HopkinsEngine::ENDEMO() {
|
||||
}
|
||||
|
||||
void HopkinsEngine::BOOM() {
|
||||
_graphicsManager.nbrligne = 640;
|
||||
_graphicsManager.SCANLINE(640);
|
||||
_graphicsManager.nbrligne = SCREEN_WIDTH;
|
||||
_graphicsManager.SCANLINE(SCREEN_WIDTH);
|
||||
_graphicsManager.DD_Lock();
|
||||
_graphicsManager.Cls_Video();
|
||||
_graphicsManager.DD_Unlock();
|
||||
@ -1875,7 +1875,7 @@ void HopkinsEngine::INCENDIE() {
|
||||
|
||||
void HopkinsEngine::BASE() {
|
||||
_globals.iRegul = 1;
|
||||
_graphicsManager.nbrligne = 640;
|
||||
_graphicsManager.nbrligne = SCREEN_WIDTH;
|
||||
_graphicsManager.DD_Lock();
|
||||
_graphicsManager.Cls_Video();
|
||||
_graphicsManager.DD_Unlock();
|
||||
@ -2138,7 +2138,7 @@ void HopkinsEngine::JOUE_FIN() {
|
||||
void HopkinsEngine::AVION() {
|
||||
_soundManager.WSOUND(28);
|
||||
_globals.iRegul = 1;
|
||||
_globals.nbrligne = 640;
|
||||
_globals.nbrligne = SCREEN_WIDTH;
|
||||
_graphicsManager.DD_Lock();
|
||||
_graphicsManager.Cls_Video();
|
||||
_graphicsManager.DD_Unlock();
|
||||
|
@ -2929,8 +2929,8 @@ LABEL_64:
|
||||
_vm->_graphicsManager.SCROLL = 0;
|
||||
v1 = 1;
|
||||
}
|
||||
if (_vm->_graphicsManager.SCROLL > 640) {
|
||||
_vm->_graphicsManager.SCROLL = 640;
|
||||
if (_vm->_graphicsManager.SCROLL > SCREEN_WIDTH) {
|
||||
_vm->_graphicsManager.SCROLL = SCREEN_WIDTH;
|
||||
v1 = 1;
|
||||
}
|
||||
if (_vm->_eventsManager.XMOUSE() > _vm->_graphicsManager.SCROLL + 620) {
|
||||
@ -2948,8 +2948,8 @@ LABEL_64:
|
||||
_vm->_graphicsManager.SCROLL = 0;
|
||||
v1 = 1;
|
||||
}
|
||||
if (_vm->_graphicsManager.SCROLL > 640) {
|
||||
_vm->_graphicsManager.SCROLL = 640;
|
||||
if (_vm->_graphicsManager.SCROLL > SCREEN_WIDTH) {
|
||||
_vm->_graphicsManager.SCROLL = SCREEN_WIDTH;
|
||||
v1 = 1;
|
||||
}
|
||||
if (_vm->_eventsManager.XMOUSE() < _vm->_graphicsManager.SCROLL + 10) {
|
||||
@ -4263,15 +4263,15 @@ void ObjectsManager::SPECIAL_JEU() {
|
||||
_vm->_graphicsManager.DD_Lock();
|
||||
if (_vm->_graphicsManager.Winbpp == 2) {
|
||||
if (_vm->_graphicsManager.SDL_ECHELLE)
|
||||
_vm->_graphicsManager.m_scroll16A(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll16A(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
else
|
||||
_vm->_graphicsManager.m_scroll16(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll16(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
}
|
||||
if (_vm->_graphicsManager.Winbpp == 1) {
|
||||
if (_vm->_graphicsManager.SDL_ECHELLE)
|
||||
_vm->_graphicsManager.m_scroll2A(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll2A(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
else
|
||||
_vm->_graphicsManager.m_scroll2(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll2(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
}
|
||||
_vm->_graphicsManager.DD_Unlock();
|
||||
v2 = _vm->_graphicsManager.VESA_BUFFER;
|
||||
|
@ -165,15 +165,15 @@ void TalkManager::PARLER_PERSO(const Common::String &filename) {
|
||||
_vm->_graphicsManager.DD_LOCK();
|
||||
if (_vm->_graphicsManager.Winbpp == 2) {
|
||||
if (_vm->_graphicsManager.SDL_ECHELLE)
|
||||
_vm->_graphicsManager.m_scroll16A(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll16A(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
else
|
||||
_vm->_graphicsManager.m_scroll16(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll16(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
}
|
||||
if (_vm->_graphicsManager.Winbpp == 1) {
|
||||
if (_vm->_graphicsManager.SDL_ECHELLE)
|
||||
_vm->_graphicsManager.m_scroll2A(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll2A(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
else
|
||||
_vm->_graphicsManager.m_scroll2(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll2(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
}
|
||||
_vm->_graphicsManager.DD_UNLOCK();
|
||||
v8 = _vm->_graphicsManager.VESA_BUFFER;
|
||||
@ -1334,15 +1334,15 @@ void TalkManager::OBJET_VIVANT(const Common::String &a2) {
|
||||
_vm->_graphicsManager.DD_Lock();
|
||||
if (_vm->_graphicsManager.Winbpp == 2) {
|
||||
if (_vm->_graphicsManager.SDL_ECHELLE)
|
||||
_vm->_graphicsManager.m_scroll16A(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll16A(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
else
|
||||
_vm->_graphicsManager.m_scroll16(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll16(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
}
|
||||
if (_vm->_graphicsManager.Winbpp == 1) {
|
||||
if (_vm->_graphicsManager.SDL_ECHELLE)
|
||||
_vm->_graphicsManager.m_scroll2A(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll2A(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
else
|
||||
_vm->_graphicsManager.m_scroll2(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, 640, 480, 0, 0);
|
||||
_vm->_graphicsManager.m_scroll2(_vm->_graphicsManager.VESA_SCREEN, _vm->_eventsManager.start_x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
|
||||
}
|
||||
_vm->_graphicsManager.DD_Unlock();
|
||||
_vm->_graphicsManager.setpal_vga256(_vm->_graphicsManager.Palette);
|
||||
|
Loading…
Reference in New Issue
Block a user