[Scummvm-cvs-logs] scummvm master -> ee14ef5348a38dd578e1f17f22c897f8ed9607a0
Strangerke
Strangerke at scummvm.org
Wed Jun 27 22:14:38 CEST 2012
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
ee14ef5348 CGE: Add ending message to tell the user he finished the game. Fix bug #3538396
Commit: ee14ef5348a38dd578e1f17f22c897f8ed9607a0
https://github.com/scummvm/scummvm/commit/ee14ef5348a38dd578e1f17f22c897f8ed9607a0
Author: Strangerke (strangerke at scummvm.org)
Date: 2012-06-27T13:12:37-07:00
Commit Message:
CGE: Add ending message to tell the user he finished the game. Fix bug #3538396
Changed paths:
engines/cge/cge.cpp
engines/cge/cge.h
diff --git a/engines/cge/cge.cpp b/engines/cge/cge.cpp
index 8ddb9be..09fce63 100644
--- a/engines/cge/cge.cpp
+++ b/engines/cge/cge.cpp
@@ -30,6 +30,8 @@
#include "common/fs.h"
#include "engines/advancedDetector.h"
#include "engines/util.h"
+#include "gui/message.h"
+
#include "cge/cge.h"
#include "cge/vga13h.h"
#include "cge/cge_main.h"
@@ -195,6 +197,16 @@ Common::Error CGEEngine::run() {
// Run the game
cge_main();
+ // If game is finished, display ending message
+ if (_flag[3]) {
+ Common::String msg = Common::String(_text->getText(kSayTheEnd));
+ if (msg.size() != 0) {
+ g_system->delayMillis(10);
+ GUI::MessageDialog dialog(msg, "OK");
+ dialog.runModal();
+ }
+ }
+
// Remove game objects
deinit();
diff --git a/engines/cge/cge.h b/engines/cge/cge.h
index 4ebc836..a5c6a62 100644
--- a/engines/cge/cge.h
+++ b/engines/cge/cge.h
@@ -78,6 +78,8 @@ class Talk;
#define kMapZCnt 20
#define kMapTop 80
+#define kSayTheEnd 41
+
// our engine debug channels
enum {
kCGEDebugBitmap = 1 << 0,
More information about the Scummvm-git-logs
mailing list