aboutsummaryrefslogtreecommitdiff
path: root/engines/avalanche/nim.cpp
diff options
context:
space:
mode:
authoruruk2013-12-20 08:46:47 +0100
committeruruk2013-12-20 08:46:47 +0100
commitf83de4fbfe655591186eb0c4e2df87b1695e9fe9 (patch)
treeb7994ec55f1b071a216fd04adda9043b1f3aff9f /engines/avalanche/nim.cpp
parentf9684f98f753e1360a00d22364a395f71ba1839c (diff)
downloadscummvm-rg350-f83de4fbfe655591186eb0c4e2df87b1695e9fe9.tar.gz
scummvm-rg350-f83de4fbfe655591186eb0c4e2df87b1695e9fe9.tar.bz2
scummvm-rg350-f83de4fbfe655591186eb0c4e2df87b1695e9fe9.zip
AVALANCHE: Implement Nim::endOfGame().
Diffstat (limited to 'engines/avalanche/nim.cpp')
-rw-r--r--engines/avalanche/nim.cpp20
1 files changed, 19 insertions, 1 deletions
diff --git a/engines/avalanche/nim.cpp b/engines/avalanche/nim.cpp
index 256c713edd..a7abfa391f 100644
--- a/engines/avalanche/nim.cpp
+++ b/engines/avalanche/nim.cpp
@@ -226,6 +226,7 @@ bool Nim::checkMouse() {
Common::Point cursorPos = _vm->getMousePos();
_vm->_graphics->refreshScreen();
Common::Event event;
+ // This loop needs "some" revision!!!
while (_vm->getEvent(event)) {
_vm->_graphics->refreshScreen();
if (event.type == Common::EVENT_LBUTTONUP) {
@@ -283,7 +284,24 @@ void Nim::takeSome() {
}
void Nim::endOfGame() {
- warning("STUB: Nim::endOfGame()");
+ CursorMan.showMouse(false);
+
+ chalk(595, 55 + _turns * 10, "Wins!");
+ _vm->_graphics->drawNormalText("- - - Press any key... - - -", _vm->_font, 8, 100, 190, kColorYellow);
+
+ Common::Event event;
+ bool escape = false;
+ while (!_vm->shouldQuit() && !escape) {
+ _vm->_graphics->refreshScreen();
+ while (_vm->getEvent(event)) {
+ if ((event.type == Common::EVENT_LBUTTONUP) || (event.type == Common::EVENT_KEYDOWN)) {
+ escape = true;
+ break;
+ }
+ }
+ }
+
+ CursorMan.showMouse(true);
}
bool Nim::find(byte x) {