aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSven Hesse2012-06-30 16:30:02 +0200
committerSven Hesse2012-07-30 01:44:43 +0200
commitbccfdb559fccdf3eff86cea22495a50260b3ad90 (patch)
treeb288145d386b96c85c2089dfa60e26c404672415
parent92bd9c864ab5238aa51ad6a327cfb7249bcc934f (diff)
downloadscummvm-rg350-bccfdb559fccdf3eff86cea22495a50260b3ad90.tar.gz
scummvm-rg350-bccfdb559fccdf3eff86cea22495a50260b3ad90.tar.bz2
scummvm-rg350-bccfdb559fccdf3eff86cea22495a50260b3ad90.zip
GOB: Move the intro parts into OnceUpon::showIntro()
-rw-r--r--engines/gob/pregob/onceupon/abracadabra.cpp24
-rw-r--r--engines/gob/pregob/onceupon/babayaga.cpp24
-rw-r--r--engines/gob/pregob/onceupon/onceupon.cpp27
-rw-r--r--engines/gob/pregob/onceupon/onceupon.h15
4 files changed, 42 insertions, 48 deletions
diff --git a/engines/gob/pregob/onceupon/abracadabra.cpp b/engines/gob/pregob/onceupon/abracadabra.cpp
index 5c1bd0149b..9db018c4aa 100644
--- a/engines/gob/pregob/onceupon/abracadabra.cpp
+++ b/engines/gob/pregob/onceupon/abracadabra.cpp
@@ -62,28 +62,8 @@ void Abracadabra::run() {
if (_vm->shouldQuit() || !correctCP)
return;
- // "Loading"
- showWait();
- if (_vm->shouldQuit())
- return;
-
- // Quote about fairy tales
- showQuote();
- if (_vm->shouldQuit())
- return;
-
- // Once Upon A Time title
- showTitle();
- if (_vm->shouldQuit())
- return;
-
- // Game title screen
- showChapter(0);
- if (_vm->shouldQuit())
- return;
-
- // "Loading"
- showWait();
+ // Show the intro
+ showIntro();
}
} // End of namespace OnceUpon
diff --git a/engines/gob/pregob/onceupon/babayaga.cpp b/engines/gob/pregob/onceupon/babayaga.cpp
index 608d85e977..8b80a38084 100644
--- a/engines/gob/pregob/onceupon/babayaga.cpp
+++ b/engines/gob/pregob/onceupon/babayaga.cpp
@@ -62,28 +62,8 @@ void BabaYaga::run() {
if (_vm->shouldQuit() || !correctCP)
return;
- // "Loading"
- showWait();
- if (_vm->shouldQuit())
- return;
-
- // Quote about fairy tales
- showQuote();
- if (_vm->shouldQuit())
- return;
-
- // Once Upon A Time title
- showTitle();
- if (_vm->shouldQuit())
- return;
-
- // Game title screen
- showChapter(0);
- if (_vm->shouldQuit())
- return;
-
- // "Loading"
- showWait();
+ // Show the intro
+ showIntro();
}
} // End of namespace OnceUpon
diff --git a/engines/gob/pregob/onceupon/onceupon.cpp b/engines/gob/pregob/onceupon/onceupon.cpp
index 6d185d007d..f2708b380b 100644
--- a/engines/gob/pregob/onceupon/onceupon.cpp
+++ b/engines/gob/pregob/onceupon/onceupon.cpp
@@ -506,6 +506,33 @@ void OnceUpon::showWait() {
fadeIn();
}
+void OnceUpon::showIntro() {
+ // Show all intro parts
+
+ // "Loading"
+ showWait();
+ if (_vm->shouldQuit())
+ return;
+
+ // Quote about fairy tales
+ showQuote();
+ if (_vm->shouldQuit())
+ return;
+
+ // Once Upon A Time title
+ showTitle();
+ if (_vm->shouldQuit())
+ return;
+
+ // Game title screen
+ showChapter(0);
+ if (_vm->shouldQuit())
+ return;
+
+ // "Loading"
+ showWait();
+}
+
void OnceUpon::showQuote() {
// Show the quote about fairytales
diff --git a/engines/gob/pregob/onceupon/onceupon.h b/engines/gob/pregob/onceupon/onceupon.h
index 96f88cbb5f..968c70ef48 100644
--- a/engines/gob/pregob/onceupon/onceupon.h
+++ b/engines/gob/pregob/onceupon/onceupon.h
@@ -49,12 +49,13 @@ protected:
bool doCopyProtection(const uint8 colors[7], const uint8 shapes[7 * 20], const uint8 obfuscate[4]);
- void showWait();
- void showQuote();
- void showTitle();
- void showChapter(int chapter);
+ void showWait(); ///< Show the wait / loading screen.
+ void showIntro(); ///< Show the whole intro.
+ void showChapter(int chapter); ///< Show a chapter intro text.
+
+ // Fonts
Font *_jeudak;
Font *_lettre;
Font *_plettre;
@@ -70,12 +71,18 @@ private:
int8 cpFindShape(int16 x, int16 y) const;
void cpWrong();
+ // Intro parts
+ void showQuote();
+ void showTitle();
+
+ // Title music
void playTitleMusic();
void playTitleMusicDOS();
void playTitleMusicAmiga();
void playTitleMusicAtariST();
void stopTitleMusic();
+
bool _openedArchives;
};