[Scummvm-git-logs] scummvm master -> ef71f37a9c63039aa239393c476b96cbfe2b7d20

eriktorbjorn eriktorbjorn at telia.com
Mon Sep 5 19:15:54 CEST 2016


This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
623e4e2fdc MACVENTURE: Clear the exits window before drawing the buttons
ef71f37a9c MACVENTURE: Implement opcode $cb (Get Current Day)


Commit: 623e4e2fdc4a122c85cefe16cfd6bb09ad1411da
    https://github.com/scummvm/scummvm/commit/623e4e2fdc4a122c85cefe16cfd6bb09ad1411da
Author: Torbjörn Andersson (eriktorbjorn at users.sourceforge.net)
Date: 2016-09-05T19:11:24+02:00

Commit Message:
MACVENTURE: Clear the exits window before drawing the buttons

This was a regression from adding background patterns.

Changed paths:
    engines/macventure/gui.cpp



diff --git a/engines/macventure/gui.cpp b/engines/macventure/gui.cpp
index 7cfc211..14c99f6 100644
--- a/engines/macventure/gui.cpp
+++ b/engines/macventure/gui.cpp
@@ -657,6 +657,7 @@ void Gui::drawInventories() {
 }
 
 void Gui::drawExitsWindow() {
+	_exitsWindow->setBackgroundPattern(kPatternLightGray);
 
 	Graphics::ManagedSurface *srf = _exitsWindow->getSurface();
 


Commit: ef71f37a9c63039aa239393c476b96cbfe2b7d20
    https://github.com/scummvm/scummvm/commit/ef71f37a9c63039aa239393c476b96cbfe2b7d20
Author: Torbjörn Andersson (eriktorbjorn at users.sourceforge.net)
Date: 2016-09-05T19:14:36+02:00

Commit Message:
MACVENTURE: Implement opcode $cb (Get Current Day)

In Deja Vu, Pete's All Nite Gun Palace is closed if you play the
game on a Sunday. I'm guessing that's the only place where this
opcode is used

Changed paths:
    engines/macventure/script.cpp



diff --git a/engines/macventure/script.cpp b/engines/macventure/script.cpp
index 2a1ffcf..77bbea1 100644
--- a/engines/macventure/script.cpp
+++ b/engines/macventure/script.cpp
@@ -1061,8 +1061,14 @@ void ScriptEngine::opcaTIME(EngineState *state, EngineFrame *frame) {
 }
 
 void ScriptEngine::opcbDAY(EngineState *state, EngineFrame *frame) {
-	// Probaby irrelevant, so we push Day [9]
-	state->push(9);
+	TimeDate t;
+	g_system->getTimeAndDate(t);
+
+	int weekday = 1 + t.tm_wday;
+	weekday = 1;
+	state->push(weekday);
+
+	debugC(2, kMVDebugScript, "Current day of week: %d", weekday);
 }
 
 void ScriptEngine::opccCHLD(EngineState *state, EngineFrame *frame) {





More information about the Scummvm-git-logs mailing list