diff options
author | Sven Hesse | 2006-11-21 13:28:45 +0000 |
---|---|---|
committer | Sven Hesse | 2006-11-21 13:28:45 +0000 |
commit | 2768fa24fc809168784d3cde79fcb4ac6ad513c0 (patch) | |
tree | 5448797e78304046d294c06fab37cbdafc0e36aa /engines/gob/inter_v2.cpp | |
parent | fada662a1f01a18dc020b5af02798d47650f7a4a (diff) | |
download | scummvm-rg350-2768fa24fc809168784d3cde79fcb4ac6ad513c0.tar.gz scummvm-rg350-2768fa24fc809168784d3cde79fcb4ac6ad513c0.tar.bz2 scummvm-rg350-2768fa24fc809168784d3cde79fcb4ac6ad513c0.zip |
- Fixed the crashes in Gob1 EGA and Gob2 Demo
- Fixed the compile error in GobEngine::saveGame on some systems
svn-id: r24756
Diffstat (limited to 'engines/gob/inter_v2.cpp')
-rw-r--r-- | engines/gob/inter_v2.cpp | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/engines/gob/inter_v2.cpp b/engines/gob/inter_v2.cpp index 963dcaa27a..0d05f659dd 100644 --- a/engines/gob/inter_v2.cpp +++ b/engines/gob/inter_v2.cpp @@ -1948,6 +1948,7 @@ void Inter_v2::o2_initMult(void) { else delete _vm->_anim->_animSurf; _vm->_draw->_spritesArray[22] = 0; + _vm->_anim->_animSurf = 0; } _vm->_draw->adjustCoords(0, &_vm->_anim->_areaWidth, &_vm->_anim->_areaHeight); @@ -1962,17 +1963,20 @@ void Inter_v2::o2_initMult(void) { _vm->_anim->_animSurf->vidPtr += 0x0C000; _vm->_draw->_spritesArray[22] = _vm->_anim->_animSurf; } else { - if (_vm->_global->_videoMode == 20) { + if ((_vm->_global->_videoMode == 0x13) && _vm->_video->_extraMode) { if (((_vm->_draw->_backSurface->width * _vm->_draw->_backSurface->height) / 2 + (_vm->_anim->_areaWidth * _vm->_anim->_areaHeight) / 4) < 65536) { - _vm->_anim->_animSurf = new Video::SurfaceDesc; + warning("GOB2 Stub! Inter_v2::o2_initMult(), wide frontSurface, using the extra space as animSurf"); +/* _vm->_anim->_animSurf = new Video::SurfaceDesc; memcpy(_vm->_anim->_animSurf, _vm->_draw->_frontSurface, sizeof(Video::SurfaceDesc)); _vm->_anim->_animSurf->width = (_vm->_anim->_areaLeft + _vm->_anim->_areaWidth - 1) | 7; _vm->_anim->_animSurf->width -= (_vm->_anim->_areaLeft & 0x0FF8) - 1; _vm->_anim->_animSurf->height = _vm->_anim->_areaHeight; _vm->_anim->_animSurf->vidPtr = _vm->_draw->_backSurface->vidPtr + _vm->_draw->_backSurface->width * _vm->_draw->_backSurface->height / 4; - _vm->_draw->_spritesArray[22] = _vm->_anim->_animSurf; + _vm->_draw->_spritesArray[22] = _vm->_anim->_animSurf;*/ + _vm->_draw->initBigSprite(22, _vm->_anim->_areaWidth, _vm->_anim->_areaHeight, 0); + _vm->_anim->_animSurf = _vm->_draw->_spritesArray[22]; } else _vm->_draw->initBigSprite(22, _vm->_anim->_areaWidth, _vm->_anim->_areaHeight, 0); _vm->_anim->_animSurf = _vm->_draw->_spritesArray[22]; |