diff options
author | Matthew Hoops | 2011-05-11 00:30:02 -0400 |
---|---|---|
committer | Matthew Hoops | 2011-05-11 00:30:28 -0400 |
commit | a1d41da096c0bcf502a85919cb1cb1ee471719c5 (patch) | |
tree | 8c51419daa486f1d4833757db4715dadab6c3497 /engines/agos | |
parent | accb0c2a5d0c9e7b353cda4b74f511a498ed8073 (diff) | |
parent | 33c3e19cea2a08fbf26ecbe940763e8ee1c37d28 (diff) | |
download | scummvm-rg350-a1d41da096c0bcf502a85919cb1cb1ee471719c5.tar.gz scummvm-rg350-a1d41da096c0bcf502a85919cb1cb1ee471719c5.tar.bz2 scummvm-rg350-a1d41da096c0bcf502a85919cb1cb1ee471719c5.zip |
Merge remote branch 'upstream/master' into t7g-ios
Conflicts:
audio/decoders/qdm2.h
common/util.cpp
engines/groovie/music.cpp
engines/groovie/resource.h
video/qt_decoder.cpp
video/qt_decoder.h
Diffstat (limited to 'engines/agos')
35 files changed, 56 insertions, 25 deletions
diff --git a/engines/agos/agos.cpp b/engines/agos/agos.cpp index 498c7e4961..56501b5294 100644 --- a/engines/agos/agos.cpp +++ b/engines/agos/agos.cpp @@ -25,9 +25,9 @@ #include "common/config-manager.h" #include "common/EventRecorder.h" -#include "common/events.h" #include "common/file.h" #include "common/fs.h" +#include "common/textconsole.h" #include "common/system.h" #include "engines/util.h" @@ -35,14 +35,12 @@ #include "agos/debugger.h" #include "agos/intern.h" #include "agos/agos.h" -#include "agos/vga.h" #include "backends/audiocd/audiocd.h" #include "graphics/surface.h" #include "audio/mididrv.h" -#include "audio/mods/protracker.h" namespace AGOS { @@ -568,33 +566,33 @@ Common::Error AGOSEngine::init() { // allocate buffers _backGroundBuf = new Graphics::Surface(); - _backGroundBuf->create(_screenWidth, _screenHeight, 1); + _backGroundBuf->create(_screenWidth, _screenHeight, Graphics::PixelFormat::createFormatCLUT8()); if (getGameType() == GType_FF || getGameType() == GType_PP) { _backBuf = new Graphics::Surface(); - _backBuf->create(_screenWidth, _screenHeight, 1); + _backBuf->create(_screenWidth, _screenHeight, Graphics::PixelFormat::createFormatCLUT8()); _scaleBuf = new Graphics::Surface(); - _scaleBuf->create(_screenWidth, _screenHeight, 1); + _scaleBuf->create(_screenWidth, _screenHeight, Graphics::PixelFormat::createFormatCLUT8()); } if (getGameType() == GType_SIMON2) { _window4BackScn = new Graphics::Surface(); - _window4BackScn->create(_screenWidth, _screenHeight, 1); + _window4BackScn->create(_screenWidth, _screenHeight, Graphics::PixelFormat::createFormatCLUT8()); } else if (getGameType() == GType_SIMON1) { _window4BackScn = new Graphics::Surface(); - _window4BackScn->create(_screenWidth, 134, 1); + _window4BackScn->create(_screenWidth, 134, Graphics::PixelFormat::createFormatCLUT8()); } else if (getGameType() == GType_WW || getGameType() == GType_ELVIRA2) { _window4BackScn = new Graphics::Surface(); - _window4BackScn->create(224, 127, 1); + _window4BackScn->create(224, 127, Graphics::PixelFormat::createFormatCLUT8()); } else if (getGameType() == GType_ELVIRA1) { _window4BackScn = new Graphics::Surface(); if (getPlatform() == Common::kPlatformAmiga && (getFeatures() & GF_DEMO)) { - _window4BackScn->create(224, 196, 1); + _window4BackScn->create(224, 196, Graphics::PixelFormat::createFormatCLUT8()); } else { - _window4BackScn->create(224, 144, 1); + _window4BackScn->create(224, 144, Graphics::PixelFormat::createFormatCLUT8()); } _window6BackScn = new Graphics::Surface(); - _window6BackScn->create(48, 80, 1); + _window6BackScn->create(48, 80, Graphics::PixelFormat::createFormatCLUT8()); } setupGame(); diff --git a/engines/agos/agos.h b/engines/agos/agos.h index bf51b31c43..aecf2437a7 100644 --- a/engines/agos/agos.h +++ b/engines/agos/agos.h @@ -29,6 +29,7 @@ #include "engines/engine.h" #include "common/array.h" +#include "common/error.h" #include "common/keyboard.h" #include "common/random.h" #include "common/rect.h" @@ -186,7 +187,7 @@ class AGOSEngine : public Engine { virtual Common::Error run() { Common::Error err; err = init(); - if (err != Common::kNoError) + if (err.getCode() != Common::kNoError) return err; return go(); } @@ -1140,7 +1141,7 @@ protected: int getScale(int16 y, int16 x); void checkScrollX(int16 x, int16 xpos); void checkScrollY(int16 y, int16 ypos); - void centreScroll(); + void centerScroll(); virtual void clearVideoWindow(uint16 windowNum, uint16 color); void clearVideoBackGround(uint16 windowNum, uint16 color); @@ -1921,7 +1922,7 @@ public: void off_mouseOff(); void off_loadVideo(); void off_playVideo(); - void off_centreScroll(); + void off_centerScroll(); void off_resetPVCount(); void off_setPathValues(); void off_stopClock(); diff --git a/engines/agos/animation.cpp b/engines/agos/animation.cpp index acdc0084c4..ee47f62a58 100644 --- a/engines/agos/animation.cpp +++ b/engines/agos/animation.cpp @@ -31,8 +31,10 @@ #include "common/events.h" #include "common/file.h" #include "common/system.h" +#include "common/textconsole.h" #include "graphics/cursorman.h" +#include "graphics/palette.h" #include "graphics/surface.h" #include "agos/animation.h" diff --git a/engines/agos/charset-fontdata.cpp b/engines/agos/charset-fontdata.cpp index a477b3dedc..a131bb841b 100644 --- a/engines/agos/charset-fontdata.cpp +++ b/engines/agos/charset-fontdata.cpp @@ -26,6 +26,7 @@ #include "common/system.h" +#include "common/textconsole.h" #include "agos/agos.h" #include "agos/intern.h" diff --git a/engines/agos/debug.cpp b/engines/agos/debug.cpp index d0dc8cc42e..bb27557a6b 100644 --- a/engines/agos/debug.cpp +++ b/engines/agos/debug.cpp @@ -27,6 +27,7 @@ #include "common/file.h" +#include "common/textconsole.h" #include "agos/debug.h" #include "agos/agos.h" diff --git a/engines/agos/debug.h b/engines/agos/debug.h index 38674de765..5865065ac3 100644 --- a/engines/agos/debug.h +++ b/engines/agos/debug.h @@ -2058,7 +2058,7 @@ static const char *const feeblefiles_opcodeNameTable[256] = { "W|UNLOAD_ZONE", NULL, "|UNFREEZE_ZONES", - "|CENTRE_SCROLL", + "|CENTER_SCROLL", /* 188 */ "BSJ|STRING2_IS", "|CLEAR_MARKS", diff --git a/engines/agos/detection.cpp b/engines/agos/detection.cpp index 646e63dacf..c8c70c0ecc 100644 --- a/engines/agos/detection.cpp +++ b/engines/agos/detection.cpp @@ -29,6 +29,7 @@ #include "common/config-manager.h" #include "common/savefile.h" #include "common/system.h" +#include "common/textconsole.h" #include "agos/intern.h" #include "agos/agos.h" diff --git a/engines/agos/draw.cpp b/engines/agos/draw.cpp index 317c68d31a..6b9f65ee2b 100644 --- a/engines/agos/draw.cpp +++ b/engines/agos/draw.cpp @@ -28,6 +28,7 @@ #include "common/system.h" #include "graphics/surface.h" +#include "graphics/palette.h" #include "agos/agos.h" #include "agos/intern.h" diff --git a/engines/agos/event.cpp b/engines/agos/event.cpp index fc0b4f96cd..8799dbaa28 100644 --- a/engines/agos/event.cpp +++ b/engines/agos/event.cpp @@ -32,6 +32,7 @@ #include "common/events.h" #include "common/system.h" +#include "common/textconsole.h" #include "backends/audiocd/audiocd.h" diff --git a/engines/agos/gfx.cpp b/engines/agos/gfx.cpp index 710c9ddd7e..4c998dfa5f 100644 --- a/engines/agos/gfx.cpp +++ b/engines/agos/gfx.cpp @@ -26,6 +26,7 @@ #include "common/system.h" +#include "common/textconsole.h" #include "graphics/surface.h" diff --git a/engines/agos/icons.cpp b/engines/agos/icons.cpp index ca603db1fa..39a7705c54 100644 --- a/engines/agos/icons.cpp +++ b/engines/agos/icons.cpp @@ -25,9 +25,9 @@ -#include "common/system.h" - #include "common/file.h" +#include "common/system.h" +#include "common/textconsole.h" #include "graphics/surface.h" diff --git a/engines/agos/items.cpp b/engines/agos/items.cpp index 81da5264ba..5d1523bbd5 100644 --- a/engines/agos/items.cpp +++ b/engines/agos/items.cpp @@ -26,6 +26,7 @@ #include "common/file.h" +#include "common/textconsole.h" #include "agos/intern.h" #include "agos/agos.h" diff --git a/engines/agos/menus.cpp b/engines/agos/menus.cpp index 5629a1dca6..2b103a75cb 100644 --- a/engines/agos/menus.cpp +++ b/engines/agos/menus.cpp @@ -27,6 +27,7 @@ #include "common/file.h" #include "common/system.h" +#include "common/textconsole.h" #include "graphics/surface.h" diff --git a/engines/agos/midi.cpp b/engines/agos/midi.cpp index a37c96a787..26e2f2c736 100644 --- a/engines/agos/midi.cpp +++ b/engines/agos/midi.cpp @@ -28,6 +28,7 @@ #include "common/config-manager.h" #include "common/file.h" #include "common/system.h" +#include "common/textconsole.h" #include "agos/agos.h" diff --git a/engines/agos/midi.h b/engines/agos/midi.h index ad69a3ddde..40f54dbaf0 100644 --- a/engines/agos/midi.h +++ b/engines/agos/midi.h @@ -31,7 +31,7 @@ #include "common/mutex.h" namespace Common { - class File; +class File; } namespace AGOS { diff --git a/engines/agos/midiparser_s1d.cpp b/engines/agos/midiparser_s1d.cpp index 156dc6ecaa..f96518b5e9 100644 --- a/engines/agos/midiparser_s1d.cpp +++ b/engines/agos/midiparser_s1d.cpp @@ -25,6 +25,7 @@ #include "common/debug.h" #include "common/util.h" +#include "common/textconsole.h" #include "audio/mididrv.h" #include "audio/midiparser.h" diff --git a/engines/agos/res.cpp b/engines/agos/res.cpp index b8409669ee..0e818963e2 100644 --- a/engines/agos/res.cpp +++ b/engines/agos/res.cpp @@ -28,6 +28,7 @@ #include "common/file.h" #include "common/memstream.h" +#include "common/textconsole.h" #include "common/util.h" #include "agos/agos.h" diff --git a/engines/agos/res_snd.cpp b/engines/agos/res_snd.cpp index fe09e746ff..34deff37ab 100644 --- a/engines/agos/res_snd.cpp +++ b/engines/agos/res_snd.cpp @@ -26,6 +26,7 @@ #include "common/config-manager.h" #include "common/file.h" #include "common/memstream.h" +#include "common/textconsole.h" #include "agos/intern.h" #include "agos/agos.h" diff --git a/engines/agos/rooms.cpp b/engines/agos/rooms.cpp index a2eff06fcc..0993197594 100644 --- a/engines/agos/rooms.cpp +++ b/engines/agos/rooms.cpp @@ -26,6 +26,7 @@ #include "common/file.h" +#include "common/textconsole.h" #include "agos/agos.h" #include "agos/intern.h" diff --git a/engines/agos/saveload.cpp b/engines/agos/saveload.cpp index eefa2460ec..d6f25814bb 100644 --- a/engines/agos/saveload.cpp +++ b/engines/agos/saveload.cpp @@ -26,6 +26,7 @@ #include "common/file.h" #include "common/savefile.h" #include "common/system.h" +#include "common/textconsole.h" #include "common/translation.h" #include "gui/about.h" diff --git a/engines/agos/script.cpp b/engines/agos/script.cpp index 90992b52fe..94a3f371cc 100644 --- a/engines/agos/script.cpp +++ b/engines/agos/script.cpp @@ -28,6 +28,7 @@ #include "common/system.h" +#include "common/textconsole.h" #include "agos/animation.h" #include "agos/agos.h" diff --git a/engines/agos/script_dp.cpp b/engines/agos/script_dp.cpp index 57610017a1..6eb3ca4779 100644 --- a/engines/agos/script_dp.cpp +++ b/engines/agos/script_dp.cpp @@ -271,7 +271,7 @@ void AGOSEngine_DIMP::setupOpcodes() { OPCODE(os1_unloadZone), OPCODE(o_invalid), OPCODE(os1_unfreezeZones), - OPCODE(off_centreScroll), + OPCODE(off_centerScroll), /* 188 */ OPCODE(os2_isShortText), OPCODE(os2_clearMarks), diff --git a/engines/agos/script_ff.cpp b/engines/agos/script_ff.cpp index dbd89cebf5..8dfee7f7c7 100644 --- a/engines/agos/script_ff.cpp +++ b/engines/agos/script_ff.cpp @@ -272,7 +272,7 @@ void AGOSEngine_Feeble::setupOpcodes() { OPCODE(os1_unloadZone), OPCODE(o_invalid), OPCODE(os1_unfreezeZones), - OPCODE(off_centreScroll), + OPCODE(off_centerScroll), /* 188 */ OPCODE(os2_isShortText), OPCODE(os2_clearMarks), @@ -590,9 +590,9 @@ void AGOSEngine_Feeble::off_playVideo() { } } -void AGOSEngine_Feeble::off_centreScroll() { +void AGOSEngine_Feeble::off_centerScroll() { // 187 - centreScroll(); + centerScroll(); } void AGOSEngine_Feeble::off_resetPVCount() { diff --git a/engines/agos/script_pn.cpp b/engines/agos/script_pn.cpp index 909c051362..b8ba7fb015 100644 --- a/engines/agos/script_pn.cpp +++ b/engines/agos/script_pn.cpp @@ -26,6 +26,8 @@ #include "agos/agos.h" #include "agos/vga.h" +#include "common/textconsole.h" + namespace AGOS { enum { diff --git a/engines/agos/script_s1.cpp b/engines/agos/script_s1.cpp index 05a725cb50..dab0302631 100644 --- a/engines/agos/script_s1.cpp +++ b/engines/agos/script_s1.cpp @@ -26,6 +26,8 @@ #include "common/system.h" +#include "graphics/palette.h" + #include "agos/agos.h" #ifdef _WIN32_WCE diff --git a/engines/agos/script_s2.cpp b/engines/agos/script_s2.cpp index dd525163c7..a0b14525f2 100644 --- a/engines/agos/script_s2.cpp +++ b/engines/agos/script_s2.cpp @@ -27,6 +27,8 @@ #include "agos/agos.h" +#include "common/textconsole.h" + namespace AGOS { #define OPCODE(x) _OPCODE(AGOSEngine_Simon2, x) diff --git a/engines/agos/sound.cpp b/engines/agos/sound.cpp index 35301793bf..25d861acb5 100644 --- a/engines/agos/sound.cpp +++ b/engines/agos/sound.cpp @@ -25,6 +25,7 @@ #include "common/file.h" #include "common/memstream.h" +#include "common/textconsole.h" #include "common/util.h" #include "agos/agos.h" diff --git a/engines/agos/string.cpp b/engines/agos/string.cpp index bda605a84a..1152d6ed04 100644 --- a/engines/agos/string.cpp +++ b/engines/agos/string.cpp @@ -26,6 +26,7 @@ #include "common/file.h" +#include "common/textconsole.h" #include "gui/about.h" #include "gui/message.h" diff --git a/engines/agos/string_pn.cpp b/engines/agos/string_pn.cpp index a4e40d8306..92d85ab96c 100644 --- a/engines/agos/string_pn.cpp +++ b/engines/agos/string_pn.cpp @@ -26,6 +26,8 @@ #include "agos/agos.h" #include "agos/intern.h" +#include "common/textconsole.h" + namespace AGOS { uint32 AGOSEngine_PN::ftext(uint32 base, int n) { diff --git a/engines/agos/subroutine.cpp b/engines/agos/subroutine.cpp index 733d40e52d..bd07596a46 100644 --- a/engines/agos/subroutine.cpp +++ b/engines/agos/subroutine.cpp @@ -26,6 +26,7 @@ #include "common/file.h" +#include "common/textconsole.h" #include "agos/agos.h" #include "agos/intern.h" diff --git a/engines/agos/vga.cpp b/engines/agos/vga.cpp index 83ee05036c..6c07db13c1 100644 --- a/engines/agos/vga.cpp +++ b/engines/agos/vga.cpp @@ -31,6 +31,7 @@ #include "agos/vga.h" #include "common/system.h" +#include "common/textconsole.h" #include "graphics/surface.h" diff --git a/engines/agos/vga_e2.cpp b/engines/agos/vga_e2.cpp index b0431db801..9e163ba91f 100644 --- a/engines/agos/vga_e2.cpp +++ b/engines/agos/vga_e2.cpp @@ -32,6 +32,7 @@ #include "common/system.h" #include "graphics/surface.h" +#include "graphics/palette.h" namespace AGOS { diff --git a/engines/agos/vga_ff.cpp b/engines/agos/vga_ff.cpp index 38a3479292..14a1c60ae5 100644 --- a/engines/agos/vga_ff.cpp +++ b/engines/agos/vga_ff.cpp @@ -201,7 +201,7 @@ void AGOSEngine::vc78_computeXY() { if (getGameType() == GType_FF) { setBitFlag(85, false); if (getBitFlag(74)) { - centreScroll(); + centerScroll(); } } } @@ -348,7 +348,7 @@ void AGOSEngine::checkScrollY(int16 y, int16 ypos) { } } -void AGOSEngine::centreScroll() { +void AGOSEngine::centerScroll() { int16 x, y, tmp; if (_scrollXMax != 0) { diff --git a/engines/agos/vga_ww.cpp b/engines/agos/vga_ww.cpp index 8aecd3448a..08b2cee303 100644 --- a/engines/agos/vga_ww.cpp +++ b/engines/agos/vga_ww.cpp @@ -32,6 +32,7 @@ #include "common/system.h" #include "graphics/surface.h" +#include "graphics/palette.h" namespace AGOS { diff --git a/engines/agos/window.cpp b/engines/agos/window.cpp index a03c7e178a..08680c9e45 100644 --- a/engines/agos/window.cpp +++ b/engines/agos/window.cpp @@ -26,6 +26,7 @@ #include "common/system.h" +#include "common/textconsole.h" #include "graphics/surface.h" |