From 28cc856572f1fa2041958062382a0e5e54d046fd Mon Sep 17 00:00:00 2001 From: Torbjörn Andersson Date: Tue, 7 Jun 2011 19:12:09 +0200 Subject: DREAMWEB: Unstub gettime(). --- engines/dreamweb/dreamweb.cpp | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'engines/dreamweb') diff --git a/engines/dreamweb/dreamweb.cpp b/engines/dreamweb/dreamweb.cpp index fbb16a83db..9fd8b66641 100644 --- a/engines/dreamweb/dreamweb.cpp +++ b/engines/dreamweb/dreamweb.cpp @@ -297,10 +297,15 @@ void setmouse(Context &context) { } void gettime(Context &context) { - warning("gettime: stub: 10:10:00"); - context.ch = 10; - context.cl = 10; - context.dh = 0; + TimeDate t; + g_system->getTimeAndDate(t); + debug(1, "\tgettime: %02d:%02d:%02d", t.tm_hour, t.tm_min, t.tm_sec); + context.ch = t.tm_hour; + context.cl = t.tm_min; + context.dh = t.tm_sec; + context.ds.byte(5) = context.dh; + context.ds.byte(6) = context.cl; + context.ds.byte(7) = context.ch; } void allocatemem(Context &context) { -- cgit v1.2.3