[Scummvm-cvs-logs] scummvm master -> 773305498c672ce528eddc8bfd5fb5702d6abb5e

bluegr bluegr at gmail.com
Thu Jul 23 20:41:28 CEST 2015


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

Summary:
39ab507b86 ACCESS: MM - Change detection for the floppy version, add detection for the demo
7e62eb4261 ACCESS: MM - Load character table
6590898e6c ACCESS: MM - Fix character loading by using a dummy character to replace missing ones
c0a8a36083 ACCESS: MM - Implement some game logic
a33a9ae2e8 ACCESS: Split a bit more Player class, add some MM specific code
88cca7c97b ACCESS: MM - Fix Sprite Frame loading
053fe65b68 ACCESS: MM - Fix Sprite Frame loading
d192d0b60c ACCESS: MM - Load TEXPAL
f96dbd52c7 ACCESS: MM - Implement some more tex palette handling
3ac8a26cb9 ACCESS: MM - Start implementing intro
f6fb26ea66 ACCESS: MM - Remove unused intro functions, fix display in showCredits
e83e55e7be ACCESS: MM - Implement the display of notes at the beginning of chapters (WIP)
0f11287b74 ACCESS: MM - Fix the color of notes
c3e20acdf2 ACCESS: MM - Some renaming
ef1165e8b5 ACCESS: MM - More renaming
539497f009 ACCESS: MM - Implement setManPalette
900dc7ffc0 ACCESS: MM - Implement setIconPalette for MM
b2a4999f3c ACCESS: MM - Fix mouse cursor when y between 177 and 184, add a call to takePicture (not yet implemented)
f11032eb4e ACCESS: MM - Fix menu position
56754c2a9d ACCESS: MM - Make RMOUSE game-specific
022b81bbc3 ACCESS: MM - Fix charMenu
7e45ce9096 ACCESS: MM - Make cmdTexSpeak game-dependent
fa07048bc4 ACCESS: Improve the use of _establishTable as a boolean
76f681efdf ACCESS: Make opcodes dependant to game versions
0f9174fca7 ACCESS: MM - Split some more opcodes
e1ded539ea ACCESS: MM - Implement some game specific opcodes
64d8d49b88 ACCESS: MM - Format CURSOR data
cc75fb5fe0 ACCESS: MM - Fix TRAVEL array size
7323140847 ACCESS: MM - Fix cmdSaveRect, implement cmdCheckTravel
48ff7ca276 ACCESS: MM - Fix some variable initialization
10e3a4c0bb ACCESS: MM - Split Display Inventory in 2 versions
e4f7a899d3 ACCESS: MM - Implement mainAreaClick
dfffeef077 ACCESS: MM - Add Two arrays of strings
69952c5ff5 ACCESS: MM - Add Death arrays
8249de3d44 ACCESS: MM - Make Bubble Box variable, add MM bubble boxes
ec381ae364 ACCESS: MM - Start implementing MM dialog box, split cmdConverse in two (WIP)
eacc0e085a ACCESS: MM - Add resource _byte1EEB5[]
6a288bc476 ACCESS: MM - Work some more on doBox_v1
93e8b47e13 ACCESS: MM - Some more work on BubbleBox class
3a57f20816 ACCESS: MM - Implement displayBoxData
f1aa191f8c ACCESS: MM - Implement getList
0c14e42bd2 ACCESS: MM - Implement up and down arrows in BubbleBox
519ecbb7be ACCESS: MM - Initial string display in doBox_v1
6f2b648b08 ACCESS: MM - Implement drawSelectBox
82027ef325 ACCESS: MM - Finish the implementation of doBox_v1
27a9a04615 ACCESS: MM - Fix crash in cmdDoTravel, some renaming
c4e8460ba2 ACCESS: MM - Fix a bug related to the down arrow, some refactoring and renaming
b1477438bb ACCESS: MM - Implement displayInv
6ba81a9749 ACCESS: MM - Implement printBubble_v1
c810ee9a5a ACCESS: MM - Make CharEntry version-dependent
f60a4d3e71 ACCESS: MM - Fix the "android" watch dialog and animation
d7f37d213c ACCESS: MM - Implement printWatch and clearWatch
290ea5dfa2 ACCESS: MM - Implement loading of cells00 in intro, some renaming
eed5116fef ACCESS: MM - Fix the travel box
1d100589ab ACCESS: MM - Implement cmdDispAbout, initialize some variables
e4710aedfa ACCESS: MM - Fix the coordinates of the last menu icon
b6b5a520d4 ACCESS: MM - Add menu case 8
ca0bef9595 ACCESS: MM - Split cmdHelp for MM
587aad7d46 ACCESS: Fix moonwalking in MM
ed4a3565a1 ACCESS: MM - Rename cmdSpecial5, implement cmdSpecial3
e85788ffdc ACCESS: MM - Some work on bubble_box
817730c360 ACCESS: MM - Implement missing bits of CharEntry
4176601718 ACCESS: MM - Add MM specific code in doEstablish
49d06c1398 ACCESS: Silent a MSVC warning
576ad394f3 ACCESS: Remove a useless variable
38f7aba414 ACCESS: MM - Remove a couple of useless variables
5159a3851b ACCESS: Clarify calculation precedence for '+' and '?'
490eb341fa ACCESS: MM - Reduce the scope of a variable, some renaming
4cd155c9a8 ACCESS: MM - Implement cmdSpecial1
e0a9c92ccd ACCESS: Split setVideo into 2 functions to allow the loading of files out of a container
631277e486 ACCESS: MM - Implement cmdSpecial6
26d86017c7 ACCESS: MM - Implement dead function
798733c15a ACCESS: MM - Remove a useless function, rename showDeathText
4ab79fa060 ACCESS: MM - Hook cmdSpecial6
af664130da ACCESS: MM - Remove combine item feature and table
dd4028db05 ACCESS: MM - Hook displayInv
bb640a85a5 ACCESS: MM - Fix compilation
452c5e59c5 ACCESS: Tex2 - Start implementing takePicture()
852a6b3e81 ACCESS: MM - Hook scroll functions in takePicture
fb78a6f465 ACCESS: MM - Add an optional variable to scroll functions
a05e8625cc ACCESS: Remove an unused function
ef9c9b78a3 ACCESS: MM - Fix a crash
a81fbda3da ACCESS: MM - Start implementing PRINTCHR and SPRINTCHR
bdf3042174 ACCESS: MM - Implement cmdSpecial7
a54bb5e351 ACCESS: MM - Implement cmdSpecial0
232775c5b3 ACCESS: MM - Implement cmdPushLocation
2fe58fac48 ACCESS: MM - Fix a bug in doBox_v1, implement some TYPE_3 code
5ec05f6b64 ACCESS: MM - use PRINTSTR in several places, remove related TODOs
6ec9c81b57 Merge branch 'master' into mm
b4c15c674d ACCESS: Comment out unused variables
ad0fc5787f ACCESS: MM doesn't use Miles Audio
773305498c Merge pull request #602 from bluegr/mm


Commit: 39ab507b864d2637d65c1fb7fe3c01003036f78c
    https://github.com/scummvm/scummvm/commit/39ab507b864d2637d65c1fb7fe3c01003036f78c
Author: Strangerke (strangerke at scummvm.org)
Date: 2014-12-28T16:15:03+01:00

Commit Message:
ACCESS: MM - Change detection for the floppy version, add detection for the demo

Changed paths:
    engines/access/detection_tables.h



diff --git a/engines/access/detection_tables.h b/engines/access/detection_tables.h
index 88a6447..124f5fc 100644
--- a/engines/access/detection_tables.h
+++ b/engines/access/detection_tables.h
@@ -75,7 +75,22 @@ static const AccessGameDescription gameDescriptions[] = {
 		{
 			"martian",
 			nullptr,
-			AD_ENTRY1s("r00.ap", "af98db5ee7f9ef86c6b1f43187a3691b", 31),
+			AD_ENTRY1s("r01.ap", "c081daca9b0cfd710157cf946e343df6", 39352),
+			Common::EN_ANY,
+			Common::kPlatformDOS,
+			ADGF_NO_FLAGS,
+			GUIO1(GUIO_NONE)
+		},
+		GType_MartianMemorandum,
+		0
+	},
+
+	{
+		// Martian Memorandum
+		{
+			"martian",
+			"Demo",
+			AD_ENTRY1s("r01.rm", "c2facf9c43047211289044ee39a2322a", 2313),
 			Common::EN_ANY,
 			Common::kPlatformDOS,
 			ADGF_NO_FLAGS,


Commit: 7e62eb4261455cf908e2f26b0e41cbfbd2292d16
    https://github.com/scummvm/scummvm/commit/7e62eb4261455cf908e2f26b0e41cbfbd2292d16
Author: Strangerke (strangerke at scummvm.org)
Date: 2014-12-28T16:35:02+01:00

Commit Message:
ACCESS: MM - Load character table

Changed paths:
    engines/access/char.cpp
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h



diff --git a/engines/access/char.cpp b/engines/access/char.cpp
index 5bc6707..49b8c2b 100644
--- a/engines/access/char.cpp
+++ b/engines/access/char.cpp
@@ -79,6 +79,12 @@ CharManager::CharManager(AccessEngine *vm) : Manager(vm) {
 				_charTable.push_back(CharEntry(Amazon::CHARTBL[i]));
 		}
 		break;
+
+	case GType_MartianMemorandum:
+		for (int i = 0; i < 27; ++i)
+			_charTable.push_back(CharEntry(Martian::CHARTBL_MM[i]));
+		break;
+
 	default:
 		error("Unknown game");
 	}
diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index d2b5dfd..2e8a4c3 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -436,12 +436,12 @@ const char *const ROOM_DESCR[] = {
 
 const int ROOM_NUMB = 48;
 
-const byte CHAR_TABLE0[] = {
+const byte MMCHAR_0[] = {
 	0x02, 0x31, 0x00, 0x08, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff,
 	0xff, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff,
 	0x00, 0x00, 0x00, 0x00, 0xff, 0xff,
 };
-const byte CHAR_TABLE2[] = {
+const byte MMCHAR_2[] = {
 	0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
 	0xff, 0x00, 0x00, 0x00, 0x00, 0x32, 0x33, 0x00, 0x01, 0x00,
 	0xff, 0xff, 0xff, 0xff, 0xff, 0x33, 0x00, 0x00, 0x00, 0x33,
@@ -454,13 +454,13 @@ const byte CHAR_TABLE2[] = {
 	0x00, 0x12, 0x00, 0x33, 0x00, 0x0a, 0x00, 0x33, 0x00, 0x13,
 	0x00, 0xff, 0xff,
 };
-const byte CHAR_TABLE3[] = {
+const byte MMCHAR_3[] = {
 	0x02, 0x31, 0x00, 0x03, 0x00, 0x35, 0x00, 0x37, 0x00, 0x02,
 	0x00, 0x80, 0x00, 0xf7, 0x00, 0x4b, 0x37, 0x00, 0x01, 0x00,
 	0xff, 0x37, 0x00, 0x03, 0x00, 0x37, 0x00, 0x00, 0x00, 0xff,
 	0xff,
 };
-const byte CHAR_TABLE4[] = {
+const byte MMCHAR_4[] = {
 	0x01, 0x31, 0x00, 0x0a, 0x00, 0x36, 0x00, 0x35, 0x00, 0x02,
 	0x00, 0x80, 0x00, 0xf7, 0x00, 0x49, 0x35, 0x00, 0x01, 0x00,
 	0xff, 0xff, 0xff, 0xff, 0xff, 0x35, 0x00, 0x00, 0x00, 0x35,
@@ -473,7 +473,7 @@ const byte CHAR_TABLE4[] = {
 	0x00, 0x13, 0x00, 0x35, 0x00, 0x0b, 0x00, 0x35, 0x00, 0x14,
 	0x00, 0xff, 0xff,
 };
-const byte CHAR_TABLE5[] = {
+const byte MMCHAR_5[] = {
 	0x01, 0x31, 0x00, 0x08, 0x00, 0x37, 0x00, 0x34, 0x00, 0x02,
 	0x00, 0x80, 0x00, 0xf7, 0x00, 0x48, 0x34, 0x00, 0x01, 0x00,
 	0xff, 0xff, 0xff, 0xff, 0xff, 0x34, 0x00, 0x00, 0x00, 0x43,
@@ -490,31 +490,31 @@ const byte CHAR_TABLE5[] = {
 	0x00, 0x0f, 0x00, 0x43, 0x00, 0x0d, 0x00, 0x34, 0x00, 0x10,
 	0x00, 0xff, 0xff,
 };
-const byte CHAR_TABLE6[] = {
+const byte MMCHAR_6[] = {
 	0x02, 0x31, 0x00, 0x03, 0x00, 0x38, 0x00, 0x44, 0x00, 0x03,
 	0x00, 0x80, 0x00, 0xf7, 0x00, 0x4e, 0x44, 0x00, 0x01, 0x00,
 	0xff, 0x44, 0x00, 0x02, 0x00, 0x44, 0x00, 0x00, 0x00, 0xff,
 	0xff,
 };
-const byte CHAR_TABLE7[] = {
+const byte MMCHAR_7[] = {
 	0x02, 0x31, 0x00, 0x01, 0x00, 0x39, 0x00, 0x38, 0x00, 0x02,
 	0x00, 0x80, 0x00, 0xf7, 0x00, 0x4c, 0x38, 0x00, 0x01, 0x00,
 	0xff, 0x38, 0x00, 0x03, 0x00, 0x38, 0x00, 0x00, 0x00, 0xff,
 	0xff,
 };
-const byte CHAR_TABLE8[] = {
+const byte MMCHAR_8[] = {
 	0x03, 0xff, 0xff, 0xff, 0xff, 0x3a, 0x00, 0xff, 0xff, 0xff,
 	0xff, 0x00, 0x00, 0x00, 0x00, 0x4d, 0x3b, 0x00, 0x01, 0x00,
 	0xff, 0x3b, 0x00, 0x02, 0x00, 0x3b, 0x00, 0x00, 0x00, 0xff,
 	0xff,
 };
-const byte CHAR_TABLE9[] = {
+const byte MMCHAR_9[] = {
 	0x03, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
 	0xff, 0x00, 0x00, 0x00, 0x00, 0x59, 0x4a, 0x00, 0x01, 0x00,
 	0xff, 0x4a, 0x00, 0x02, 0x00, 0x4a, 0x00, 0x00, 0x00, 0xff,
 	0xff,
 };
-const byte CHAR_TABLE10[] = {
+const byte MMCHAR_10[] = {
 	0x01, 0x31, 0x00, 0x0a, 0x00, 0x3c, 0x00, 0x36, 0x00, 0x02,
 	0x00, 0x80, 0x00, 0xf7, 0x00, 0x4a, 0x36, 0x00, 0x01, 0x00,
 	0xff, 0xff, 0xff, 0xff, 0xff, 0x36, 0x00, 0x00, 0x00, 0x36,
@@ -532,19 +532,19 @@ const byte CHAR_TABLE10[] = {
 	0x00, 0x36, 0x00, 0x11, 0x00, 0x36, 0x00, 0x21, 0x00, 0x36,
 	0x00, 0x12, 0x00, 0x36, 0x00, 0x22, 0x00, 0xff, 0xff,
 };
-const byte CHAR_TABLE11[] = {
+const byte MMCHAR_11[] = {
 	0x03, 0xff, 0xff, 0xff, 0xff, 0x3d, 0x00, 0xff, 0xff, 0xff,
 	0xff, 0x00, 0x00, 0x00, 0x00, 0x55, 0x45, 0x00, 0x01, 0x00,
 	0xff, 0x45, 0x00, 0x02, 0x00, 0x45, 0x00, 0x00, 0x00, 0xff,
 	0xff,
 };
-const byte CHAR_TABLE12[] = {
+const byte MMCHAR_12[] = {
 	0x03, 0xff, 0xff, 0xff, 0xff, 0x3e, 0x00, 0xff, 0xff, 0xff,
 	0xff, 0x00, 0x00, 0x00, 0x00, 0x4f, 0x40, 0x00, 0x01, 0x00,
 	0xff, 0x40, 0x00, 0x02, 0x00, 0x40, 0x00, 0x00, 0x00, 0xff,
 	0xff,
 };
-const byte CHAR_TABLE13[] = {
+const byte MMCHAR_13[] = {
 	0x00, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x46, 0x00, 0x02,
 	0x00, 0x80, 0x00, 0xf7, 0x00, 0x56, 0x46, 0x00, 0x01, 0x00,
 	0xff, 0x46, 0x00, 0x03, 0x00, 0x46, 0x00, 0x00, 0x00, 0x46,
@@ -557,7 +557,7 @@ const byte CHAR_TABLE13[] = {
 	0x00, 0x14, 0x00, 0x46, 0x00, 0x0c, 0x00, 0x46, 0x00, 0x15,
 	0x00, 0xff, 0xff,
 };
-const byte CHAR_TABLE15[] = {
+const byte MMCHAR_15[] = {
 	0x00, 0xff, 0xff, 0xff, 0xff, 0x41, 0x00, 0xff, 0xff, 0xff,
 	0xff, 0x00, 0x00, 0x00, 0x00, 0x57, 0x47, 0x00, 0x01, 0x00,
 	0xff, 0xff, 0xff, 0xff, 0xff, 0x47, 0x00, 0x00, 0x00, 0x47,
@@ -565,43 +565,43 @@ const byte CHAR_TABLE15[] = {
 	0x00, 0x47, 0x00, 0x06, 0x00, 0x47, 0x00, 0x04, 0x00, 0x47,
 	0x00, 0x07, 0x00, 0xff, 0xff,
 };
-const byte CHAR_TABLE16[] = {
+const byte MMCHAR_16[] = {
 	0x03, 0xff, 0xff, 0xff, 0xff, 0x42, 0x00, 0xff, 0xff, 0xff,
 	0xff, 0x00, 0x00, 0x00, 0x00, 0x54, 0x41, 0x00, 0x01, 0x00,
 	0xff, 0x41, 0x00, 0x02, 0x00, 0x41, 0x00, 0x00, 0x00, 0xff,
 	0xff,
 };
-const byte CHAR_TABLE18[] = {
+const byte MMCHAR_18[] = {
 	0x02, 0x31, 0x00, 0x07, 0x00, 0x44, 0x00, 0x3c, 0x00, 0x03,
 	0x00, 0x80, 0x00, 0xf7, 0x00, 0x50, 0x3c, 0x00, 0x01, 0x00,
 	0xff, 0x3c, 0x00, 0x02, 0x00, 0x3c, 0x00, 0x00, 0x00, 0xff,
 	0xff,
 };
-const byte CHAR_TABLE19[] = {
+const byte MMCHAR_19[] = {
 	0x02, 0x31, 0x00, 0x07, 0x00, 0x45, 0x00, 0x3d, 0x00, 0x03,
 	0x00, 0x80, 0x00, 0xf7, 0x00, 0x51, 0x3d, 0x00, 0x01, 0x00,
 	0xff, 0x3d, 0x00, 0x02, 0x00, 0x3d, 0x00, 0x00, 0x00, 0xff,
 	0xff,
 };
-const byte CHAR_TABLE20[] = {
+const byte MMCHAR_20[] = {
 	0x02, 0x31, 0x00, 0x02, 0x00, 0x46, 0x00, 0x48, 0x00, 0x02,
 	0x00, 0x80, 0x00, 0xf7, 0x00, 0x58, 0x48, 0x00, 0x01, 0x00,
 	0xff, 0x48, 0x00, 0x03, 0x00, 0x48, 0x00, 0x00, 0x00, 0xff,
 	0xff,
 };
-const byte CHAR_TABLE21[] = {
+const byte MMCHAR_21[] = {
 	0x02, 0x31, 0x00, 0x07, 0x00, 0x47, 0x00, 0x3e, 0x00, 0x03,
 	0x00, 0x80, 0x00, 0xf7, 0x00, 0x52, 0x3e, 0x00, 0x01, 0x00,
 	0xff, 0x3e, 0x00, 0x02, 0x00, 0x3e, 0x00, 0x00, 0x00, 0xff,
 	0xff,
 };
-const byte CHAR_TABLE23[] = {
+const byte MMCHAR_23[] = {
 	0x02, 0x31, 0x00, 0x08, 0x00, 0x49, 0x00, 0x3f, 0x00, 0x03,
 	0x00, 0x80, 0x00, 0xf7, 0x00, 0x53, 0x3f, 0x00, 0x01, 0x00,
 	0xff, 0x3f, 0x00, 0x02, 0x00, 0x3f, 0x00, 0x00, 0x00, 0xff,
 	0xff,
 };
-const byte CHAR_TABLE24[] = {
+const byte MMCHAR_24[] = {
 	0x02, 0x32, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff,
 	0xff, 0x00, 0x00, 0x00, 0x00, 0x47, 0x32, 0x00, 0x02, 0x00,
 	0xff, 0xff, 0xff, 0xff, 0xff, 0x32, 0x00, 0x01, 0x00, 0x32,
@@ -612,13 +612,13 @@ const byte CHAR_TABLE24[] = {
 	0x00, 0x08, 0x00, 0x32, 0x00, 0x0f, 0x00, 0x32, 0x00, 0x09,
 	0x00, 0x32, 0x00, 0x10, 0x00, 0xff, 0xff
 };
-const byte CHAR_TABLE25[] = {
+const byte MMCHAR_25[] = {
 	0x02, 0x39, 0x00, 0x01, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
 	0xFF, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
 	0x39, 0x00, 0x00, 0x00, 0x39, 0x00, 0x02, 0x00, 0x00, 0x00,
 	0x00, 0x00, 0xFF, 0xFF
 };
-const byte CHAR_TABLE26[] = {
+const byte MMCHAR_26[] = {
 	0x01, 0x3a, 0x00, 0x01, 0x00, 0x0a, 0x00, 0xff, 0xff, 0xff,
 	0xff, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x3a, 0x00, 0x02, 0x00,
 	0xff, 0x3a, 0x00, 0x03, 0x00, 0x3a, 0x00, 0x00, 0x00, 0x42,
@@ -638,7 +638,7 @@ const byte CHAR_TABLE26[] = {
 	0x00, 0x3a, 0x00, 0x14, 0x00, 0x42, 0x00, 0x11, 0x00, 0x3a,
 	0x00, 0x15, 0x00, 0xff, 0xff
 };
-const byte CHAR_TABLE27[] = {
+const byte MMCHAR_27[] = {
 	0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
 	0xff, 0x00, 0x00, 0x00, 0x00, 0x58, 0x49, 0x00, 0x01, 0x00,
 	0xff, 0xff, 0xff, 0xff, 0xff, 0x49, 0x00, 0x00, 0x00, 0x49,
@@ -650,13 +650,13 @@ const byte CHAR_TABLE27[] = {
 	0x00, 0x49, 0x00, 0x10, 0x00, 0x49, 0x00, 0x09, 0x00, 0x49,
 	0x00, 0x11, 0x00, 0xff, 0xff,
 };
-const byte *const CHAR_TABLE[] = {
-	CHAR_TABLE0, nullptr, CHAR_TABLE2, CHAR_TABLE3, CHAR_TABLE4, CHAR_TABLE5,
-	CHAR_TABLE6, CHAR_TABLE7, CHAR_TABLE8, CHAR_TABLE9, CHAR_TABLE10,
-	CHAR_TABLE11, CHAR_TABLE12, CHAR_TABLE13, nullptr, CHAR_TABLE15,
-	CHAR_TABLE16, nullptr, CHAR_TABLE18, CHAR_TABLE19, CHAR_TABLE20,
-	CHAR_TABLE21, nullptr, CHAR_TABLE23, CHAR_TABLE24, CHAR_TABLE25,
-	CHAR_TABLE26, CHAR_TABLE27
+const byte *const CHARTBL_MM[] = {
+	MMCHAR_0, nullptr, MMCHAR_2, MMCHAR_3, MMCHAR_4, MMCHAR_5,
+	MMCHAR_6, MMCHAR_7, MMCHAR_8, MMCHAR_9, MMCHAR_10,
+	MMCHAR_11, MMCHAR_12, MMCHAR_13, nullptr, MMCHAR_15,
+	MMCHAR_16, nullptr, MMCHAR_18, MMCHAR_19, MMCHAR_20,
+	MMCHAR_21, nullptr, MMCHAR_23, MMCHAR_24, MMCHAR_25,
+	MMCHAR_26, MMCHAR_27
 };
 
 // TODO: Fix that array
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index a52967d..ce8b628 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -41,7 +41,7 @@ extern const byte *const ROOM_TABLE[];
 extern const char *const ROOM_DESCR[];
 extern const int ROOM_NUMB;
 
-extern const byte *const CHAR_TABLE[];
+extern const byte *const CHARTBL_MM[];
 
 extern const int COMBO_TABLE[54][4];
 


Commit: 6590898e6c1e46210e0c49a12874e02d1ad46d6f
    https://github.com/scummvm/scummvm/commit/6590898e6c1e46210e0c49a12874e02d1ad46d6f
Author: Strangerke (strangerke at scummvm.org)
Date: 2014-12-28T17:08:07+01:00

Commit Message:
ACCESS: MM - Fix character loading by using a dummy character to replace missing ones

Changed paths:
    engines/access/martian/martian_resources.cpp



diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index 2e8a4c3..9f98824 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -650,13 +650,15 @@ const byte MMCHAR_27[] = {
 	0x00, 0x49, 0x00, 0x10, 0x00, 0x49, 0x00, 0x09, 0x00, 0x49,
 	0x00, 0x11, 0x00, 0xff, 0xff,
 };
+
+// HACK: MMCHAR_0 has been used to replace the missing CHAR: 1, 14, 17 and 22
 const byte *const CHARTBL_MM[] = {
-	MMCHAR_0, nullptr, MMCHAR_2, MMCHAR_3, MMCHAR_4, MMCHAR_5,
-	MMCHAR_6, MMCHAR_7, MMCHAR_8, MMCHAR_9, MMCHAR_10,
-	MMCHAR_11, MMCHAR_12, MMCHAR_13, nullptr, MMCHAR_15,
-	MMCHAR_16, nullptr, MMCHAR_18, MMCHAR_19, MMCHAR_20,
-	MMCHAR_21, nullptr, MMCHAR_23, MMCHAR_24, MMCHAR_25,
-	MMCHAR_26, MMCHAR_27
+	MMCHAR_0,  MMCHAR_0,  MMCHAR_2,  MMCHAR_3,  MMCHAR_4,
+	MMCHAR_5,  MMCHAR_6,  MMCHAR_7,  MMCHAR_8,  MMCHAR_9,
+	MMCHAR_10, MMCHAR_11, MMCHAR_12, MMCHAR_13, MMCHAR_0,
+	MMCHAR_15, MMCHAR_16, MMCHAR_0,  MMCHAR_18, MMCHAR_19,
+	MMCHAR_20, MMCHAR_21, MMCHAR_0,  MMCHAR_23, MMCHAR_24,
+	MMCHAR_25, MMCHAR_26, MMCHAR_27
 };
 
 // TODO: Fix that array


Commit: c0a8a360833a7330b75f771fdb762568e48a9e37
    https://github.com/scummvm/scummvm/commit/c0a8a360833a7330b75f771fdb762568e48a9e37
Author: Strangerke (strangerke at scummvm.org)
Date: 2014-12-28T17:21:16+01:00

Commit Message:
ACCESS: MM - Implement some game logic

Changed paths:
    engines/access/martian/martian_game.cpp
    engines/access/martian/martian_game.h



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index 6392206..6722120 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -37,25 +37,77 @@ MartianEngine::MartianEngine(OSystem *syst, const AccessGameDescription *gameDes
 MartianEngine::~MartianEngine() {
 }
 
+void MartianEngine::initObjects() {
+	_room = new MartianRoom(this);
+	_scripts = new MartianScripts(this);
+}
+
+void MartianEngine::configSelect() {
+	// No implementation required in MM
+}
+
+void MartianEngine::initVariables() {
+	warning("TODO: initVariables");
+
+	// Set player room and position
+	_player->_roomNumber = 7;
+
+	_inventory->_startInvItem = 0;
+	_inventory->_startInvBox = 0;
+	Common::fill(&_objectsTable[0], &_objectsTable[100], (SpriteResource *)nullptr);
+	_player->_playerOff = false;
+
+	// Setup timers
+	const int TIMER_DEFAULTS[] = { 4, 10, 8, 1, 1, 1, 1, 2 };
+	for (int i = 0; i < 32; ++i) {
+		TimerEntry te;
+		te._initTm = te._timer = (i < 8) ? TIMER_DEFAULTS[i] : 1;
+		te._flag = 1;
+
+		_timers.push_back(te);
+	}
+
+	_player->_playerX = _player->_rawPlayer.x = TRAVEL_POS[_player->_roomNumber][0];
+	_player->_playerY = _player->_rawPlayer.y = TRAVEL_POS[_player->_roomNumber][1];
+	_room->_selectCommand = -1;
+	_events->setNormalCursor(CURSOR_CROSSHAIRS);
+	_mouseMode = 0;
+	_numAnimTimers = 0;
+}
+
 void MartianEngine::playGame() {
-	// Do introduction
-	doIntroduction();
-	if (shouldQuit())
-		return;
+	// Initialize Amazon game-specific objects
+	initObjects();
 
 	// Setup the game
 	setupGame();
+	configSelect();
 
-	_screen->clearScreen();
-	_screen->setPanel(0);
-	_screen->forceFadeOut();
+	if (_loadSaveSlot == -1) {
+		// Do introduction
+		doIntroduction();
+		if (shouldQuit())
+			return;
+	}
 
-	_events->showCursor();
+	do {
+		_restartFl = false;
+		_screen->clearScreen();
+		_screen->setPanel(0);
+		_screen->forceFadeOut();
+		_events->showCursor();
 
-	// Setup and execute the room
-	_room = new MartianRoom(this);
-	_scripts = new MartianScripts(this);
-	_room->doRoom();
+		initVariables();
+
+		// If there's a pending savegame to load, load it
+		if (_loadSaveSlot != -1) {
+			loadGameState(_loadSaveSlot);
+			_loadSaveSlot = -1;
+		}
+
+		// Execute the room
+		_room->doRoom();
+	} while (_restartFl);
 }
 
 void MartianEngine::doIntroduction() {
diff --git a/engines/access/martian/martian_game.h b/engines/access/martian/martian_game.h
index a83b67a..812aa37 100644
--- a/engines/access/martian/martian_game.h
+++ b/engines/access/martian/martian_game.h
@@ -53,6 +53,10 @@ private:
 	 */
 	void setupGame();
 
+	void initObjects();
+	void configSelect();
+	void initVariables();
+
 protected:
 	/**
 	 * Play the game


Commit: a33a9ae2e85c7999e9234538a3979d61ca431626
    https://github.com/scummvm/scummvm/commit/a33a9ae2e85c7999e9234538a3979d61ca431626
Author: Strangerke (strangerke at scummvm.org)
Date: 2014-12-29T07:22:51+01:00

Commit Message:
ACCESS: Split a bit more Player class, add some MM specific code

Changed paths:
  A engines/access/martian/martian_player.cpp
  A engines/access/martian/martian_player.h
    engines/access/access.cpp
    engines/access/access.h
    engines/access/amazon/amazon_player.cpp
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h
    engines/access/martian/martian_room.cpp
    engines/access/martian/martian_room.h
    engines/access/module.mk
    engines/access/player.cpp
    engines/access/player.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index 6ad1b22..14aa68c 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -51,6 +51,7 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 	_destIn = nullptr;
 	_current = nullptr;
 	_mouseMode = 0;
+	_playerDataCount = 0;
 	_currentMan = 0;
 	_currentManOld = -1;
 	_converseMode = 0;
diff --git a/engines/access/access.h b/engines/access/access.h
index a082b96..8801c1b 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -173,6 +173,7 @@ public:
 	ImageEntryList _images;
 	int _mouseMode;
 
+	int _playerDataCount;
 	int _currentManOld;
 	int _converseMode;
 	int _startAboutBox;
diff --git a/engines/access/amazon/amazon_player.cpp b/engines/access/amazon/amazon_player.cpp
index b1ed501..2f32db1 100644
--- a/engines/access/amazon/amazon_player.cpp
+++ b/engines/access/amazon/amazon_player.cpp
@@ -48,7 +48,7 @@ void AmazonPlayer::load() {
 		_downDelta = -2;
 		_scrollConst = 2;
 
-		for (int i = 0; i < PLAYER_DATA_COUNT; ++i) {
+		for (int i = 0; i < _vm->_playerDataCount; ++i) {
 			_walkOffRight[i] = OVEROFFR[i];
 			_walkOffLeft[i] = OVEROFFL[i];
 			_walkOffUp[i] = OVEROFFU[i];
diff --git a/engines/access/martian/martian_player.cpp b/engines/access/martian/martian_player.cpp
new file mode 100644
index 0000000..493776e
--- /dev/null
+++ b/engines/access/martian/martian_player.cpp
@@ -0,0 +1,62 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ *
+ */
+
+#include "common/scummsys.h"
+#include "access/access.h"
+#include "access/room.h"
+#include "access/martian/martian_game.h"
+#include "access/martian/martian_player.h"
+#include "access/martian/martian_resources.h"
+
+namespace Access {
+
+namespace Martian {
+
+MartianPlayer::MartianPlayer(AccessEngine *vm) : Player(vm) {
+	_game = (MartianEngine *)vm;
+}
+
+void MartianPlayer::load() {
+	Player::load();
+
+	// Overwrite game-specific values
+	_playerOffset.x = _vm->_screen->_scaleTable1[20];
+	_playerOffset.y = _vm->_screen->_scaleTable1[52];
+	_leftDelta = -9;
+	_rightDelta = 33;
+	_upDelta = 5;
+	_downDelta = -5;
+	_scrollConst = 5;
+
+	_sideWalkMin = 0;
+	_sideWalkMax = 7;
+	_upWalkMin = 8;
+	_upWalkMax = 14;
+	_downWalkMin = 15;
+	_downWalkMax = 23;
+
+	warning("TODO: Copy texPal into manPal");
+}
+
+} // End of namespace Martian
+
+} // End of namespace Access
diff --git a/engines/access/martian/martian_player.h b/engines/access/martian/martian_player.h
new file mode 100644
index 0000000..192f254
--- /dev/null
+++ b/engines/access/martian/martian_player.h
@@ -0,0 +1,48 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ *
+ */
+
+#ifndef ACCESS_MARTIAN_PLAYER_H
+#define ACCESS_MARTIAN_PLAYER_H
+
+#include "common/scummsys.h"
+#include "access/player.h"
+
+namespace Access {
+
+namespace Martian {
+
+class MartianEngine;
+
+class MartianPlayer : public Player {
+private:
+	MartianEngine *_game;
+public:
+	MartianPlayer(AccessEngine *vm);
+
+	virtual void load();
+};
+
+} // End of namespace Martian
+
+} // End of namespace Access
+
+#endif /* ACCESS_MARTIAN_PLAYER_H */
diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index 9f98824..78d14b7 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -719,6 +719,11 @@ const int COMBO_TABLE[54][4] = {
 	{ -1, -1, -1, -1 }
 };
 
+const int SIDEOFFR[] = {  4, 0, 7, 10,  3, 1, 2, 13, 0, 0, 0, 0 };
+const int SIDEOFFL[] = { 11, 6, 1,  4, 10, 6, 1,  4, 0, 0, 0, 0 };
+const int SIDEOFFU[] = {  1, 2, 0,  2,  2, 1, 1,  0, 0, 0, 0, 0 };
+const int SIDEOFFD[] = {  2, 0, 1,  1,  0, 1, 1,  1, 2, 0, 0, 0 };
+
 } // End of namespace Martian
 
 } // End of namespace Access
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index ce8b628..36b4ce3 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -45,6 +45,11 @@ extern const byte *const CHARTBL_MM[];
 
 extern const int COMBO_TABLE[54][4];
 
+extern const int SIDEOFFR[];
+extern const int SIDEOFFL[];
+extern const int SIDEOFFU[];
+extern const int SIDEOFFD[];
+
 } // End of namespace Martian
 
 } // End of namespace Access
diff --git a/engines/access/martian/martian_room.cpp b/engines/access/martian/martian_room.cpp
index e9d1b9d..972aada 100644
--- a/engines/access/martian/martian_room.cpp
+++ b/engines/access/martian/martian_room.cpp
@@ -43,72 +43,52 @@ void MartianRoom::loadRoom(int roomNumber) {
 }
 
 void MartianRoom::reloadRoom() {
-	loadRoom(_vm->_player->_roomNumber);
-
-	if (_roomFlag != 1) {
-		_vm->_currentMan = _roomFlag;
-		_vm->_currentManOld = _roomFlag;
-		_vm->_manScaleOff = 0;
-
-		switch (_vm->_currentMan) {
-		case 0:
-			_vm->_player->loadSprites("MAN.LZ");
-			break;
+	warning("TODO: Load TEXPAL.COL");
+//	_vm->_currentMan = _roomFlag;
+//	_vm->_currentManOld = _roomFlag;
+//	_vm->_manScaleOff = 0;
 
-		case 2:
-			_vm->_player->loadSprites("JMAN.LZ");
-			break;
+	_vm->_player->loadSprites("TEX.LZ");
+	warning("TODO: Load TEXPAL.COL");
 
-		case 3:
-			_vm->_player->loadSprites("OVERHEAD.LZ");
-			_vm->_manScaleOff = 1;
-			break;
-
-		default:
-			break;
-		}
-	}
+	loadRoom(_vm->_player->_roomNumber);
 
 	reloadRoom1();
 }
 
 void MartianRoom::reloadRoom1() {
-	if (_vm->_player->_roomNumber == 29 || _vm->_player->_roomNumber == 31
-			|| _vm->_player->_roomNumber == 42 || _vm->_player->_roomNumber == 44) {
-		//Resource *spriteData = _vm->_files->loadFile("MAYA.LZ");
-		//_vm->_inactive._spritesPtr = new SpriteResource(_vm, spriteData);
-		//delete spriteData;
-		_vm->_currentCharFlag = false;
-	}
-
 	_selectCommand = -1;
-	_vm->_events->setNormalCursor(CURSOR_CROSSHAIRS);
-	_vm->_mouseMode = 0;
-	_vm->_boxSelect = true;
+
+// CHECKME: Useful?
+//	_vm->_events->setNormalCursor(CURSOR_CROSSHAIRS);
+//	_vm->_mouseMode = 0;
+//	_vm->_boxSelect = true;
+
 	_vm->_player->_playerOff = false;
 
-	_vm->_screen->fadeOut();
+	_vm->_screen->forceFadeOut();
+	_vm->_events->hideCursor();
 	_vm->_screen->clearScreen();
+	_vm->_events->showCursor();
 	roomSet();
+	_vm->_player->load();
 
-	// TODO: Refactor
+	if (_vm->_player->_roomNumber != 47)
+		_vm->_player->calcManScale();
 
+	_vm->_events->hideCursor();
+	roomMenu();
 	_vm->_screen->setBufferScan();
 	setupRoom();
 	setWallCodes();
 	buildScreen();
-
-	if (!_vm->_screen->_vesaMode) {
-		_vm->copyBF2Vid();
-	} else if (_vm->_player->_roomNumber != 20 && _vm->_player->_roomNumber != 24
-			&& _vm->_player->_roomNumber != 33) {
-		_vm->_screen->setPalette();
-		_vm->copyBF2Vid();
-	}
-
+	_vm->copyBF2Vid();
+	warning("TODO: setManPalette");
+	_vm->_events->showCursor();
 	_vm->_player->_frame = 0;
 	_vm->_oldRects.clear();
 	_vm->_newRects.clear();
+	_vm->_events->clearEvents();
 }
 
 void MartianRoom::roomSet() {
diff --git a/engines/access/martian/martian_room.h b/engines/access/martian/martian_room.h
index 85529ce..cb2a8c2 100644
--- a/engines/access/martian/martian_room.h
+++ b/engines/access/martian/martian_room.h
@@ -52,8 +52,6 @@ public:
 
 	virtual ~MartianRoom();
 
-	virtual void loadRoomData(const byte *roomData) { warning("TODO - loadRoomData"); }
-
 	virtual void init4Quads() { }
 
 	virtual void roomMenu();
diff --git a/engines/access/module.mk b/engines/access/module.mk
index b6961ae..f7cf7f2 100644
--- a/engines/access/module.mk
+++ b/engines/access/module.mk
@@ -28,6 +28,7 @@ MODULE_OBJS := \
 	amazon/amazon_room.o \
 	amazon/amazon_scripts.o \
 	martian/martian_game.o \
+	martian/martian_player.o \
 	martian/martian_resources.o \
 	martian/martian_room.o \
 	martian/martian_scripts.o
diff --git a/engines/access/player.cpp b/engines/access/player.cpp
index d547aed..1fe58c6 100644
--- a/engines/access/player.cpp
+++ b/engines/access/player.cpp
@@ -26,24 +26,25 @@
 #include "access/access.h"
 #include "access/resources.h"
 #include "access/amazon/amazon_player.h"
+#include "access/martian/martian_player.h"
 
 namespace Access {
 
 Player *Player::init(AccessEngine *vm) {
 	switch (vm->getGameID()) {
 	case GType_Amazon:
+		vm->_playerDataCount = 8;
 		return new Amazon::AmazonPlayer(vm);
+	case GType_MartianMemorandum:
+		vm->_playerDataCount = 10;
+		return new Martian::MartianPlayer(vm);
 	default:
+		vm->_playerDataCount = 8;
 		return new Player(vm);
 	}
 }
 
 Player::Player(AccessEngine *vm) : Manager(vm), ImageEntry() {
-	Common::fill(&_walkOffRight[0], &_walkOffRight[PLAYER_DATA_COUNT], 0);
-	Common::fill(&_walkOffLeft[0], &_walkOffLeft[PLAYER_DATA_COUNT], 0);
-	Common::fill(&_walkOffUp[0], &_walkOffUp[PLAYER_DATA_COUNT], 0);
-	Common::fill(&_walkOffDown[0], &_walkOffDown[PLAYER_DATA_COUNT], 0);
-
 	_playerSprites = nullptr;
 	_playerSprites1 = nullptr;
 	_manPal1 = nullptr;
@@ -73,14 +74,36 @@ Player::Player(AccessEngine *vm) : Manager(vm), ImageEntry() {
 	_playerDirection = NONE;
 	_xFlag = _yFlag = 0;
 	_inactiveYOff = 0;
+	_walkOffRight = _walkOffLeft = nullptr;
+	_walkOffUp = _walkOffDown = nullptr;
+	_walkOffUR = _walkOffDR = nullptr;
+	_walkOffUL = _walkOffDL = nullptr;
 }
 
 Player::~Player() {
 	delete _playerSprites;
 	delete[] _manPal1;
+	delete[] _walkOffRight;
+	delete[] _walkOffLeft;
+	delete[] _walkOffUp;
+	delete[] _walkOffDown;
+	delete[] _walkOffUR;
+	delete[] _walkOffDR;
+	delete[] _walkOffUL;
+	delete[] _walkOffDL;
 }
 
 void Player::load() {
+	int dataCount = _vm->_playerDataCount;
+	_walkOffRight = new int[dataCount];
+	_walkOffLeft = new int[dataCount];
+	_walkOffUp = new int[dataCount];
+	_walkOffDown = new int[dataCount];
+	_walkOffUR = new Common::Point[dataCount];
+	_walkOffDR = new Common::Point[dataCount];
+	_walkOffUL = new Common::Point[dataCount];
+	_walkOffDL = new Common::Point[dataCount];
+
 	_playerOffset.x = _vm->_screen->_scaleTable1[25];
 	_playerOffset.y = _vm->_screen->_scaleTable1[67];
 	_leftDelta = -3;
@@ -89,7 +112,7 @@ void Player::load() {
 	_downDelta = -10;
 	_scrollConst = 5;
 
-	for (int i = 0; i < PLAYER_DATA_COUNT; ++i) {
+	for (int i = 0; i < dataCount; ++i) {
 		_walkOffRight[i] = SIDEOFFR[i];
 		_walkOffLeft[i] = SIDEOFFL[i];
 		_walkOffUp[i] = SIDEOFFU[i];
diff --git a/engines/access/player.h b/engines/access/player.h
index 26caec6..1b33ae6 100644
--- a/engines/access/player.h
+++ b/engines/access/player.h
@@ -31,8 +31,6 @@
 
 namespace Access {
 
-#define PLAYER_DATA_COUNT 8
-
 enum Direction {
 	NONE = 0,
 	UP = 1,
@@ -85,14 +83,14 @@ public:
 	SpriteResource *_playerSprites;
 	// Fields in original Player structure
 	byte *_monData;
-	int _walkOffRight[PLAYER_DATA_COUNT];
-	int _walkOffLeft[PLAYER_DATA_COUNT];
-	int _walkOffUp[PLAYER_DATA_COUNT];
-	int _walkOffDown[PLAYER_DATA_COUNT];
-	Common::Point _walkOffUR[PLAYER_DATA_COUNT];
-	Common::Point _walkOffDR[PLAYER_DATA_COUNT];
-	Common::Point _walkOffUL[PLAYER_DATA_COUNT];
-	Common::Point _walkOffDL[PLAYER_DATA_COUNT];
+	int *_walkOffRight;
+	int *_walkOffLeft;
+	int *_walkOffUp;
+	int *_walkOffDown;
+	Common::Point *_walkOffUR;
+	Common::Point *_walkOffDR;
+	Common::Point *_walkOffUL;
+	Common::Point *_walkOffDL;
 	byte _rawTempL;
 	int _rawXTemp;
 	byte _rawYTempL;


Commit: 88cca7c97b5cc648503c0401cd4679da27347792
    https://github.com/scummvm/scummvm/commit/88cca7c97b5cc648503c0401cd4679da27347792
Author: Strangerke (strangerke at scummvm.org)
Date: 2014-12-29T21:01:38+01:00

Commit Message:
ACCESS: MM - Fix Sprite Frame loading

Changed paths:
    engines/access/asurface.cpp



diff --git a/engines/access/asurface.cpp b/engines/access/asurface.cpp
index 38af7ad..21bf460 100644
--- a/engines/access/asurface.cpp
+++ b/engines/access/asurface.cpp
@@ -54,6 +54,12 @@ SpriteResource::~SpriteResource() {
 SpriteFrame::SpriteFrame(AccessEngine *vm, Common::SeekableReadStream *stream, int frameSize) {
 	int xSize = stream->readUint16LE();
 	int ySize = stream->readUint16LE();
+
+	if (vm->getGameID() == GType_MartianMemorandum) {
+		int size = stream->readUint16LE();
+		if (size != frameSize)
+			warning("Unexpected file difference: framesize %d - size %d %d - unknown %d", frameSize, xSize, ySize, unknown);
+	}
 	create(xSize, ySize);
 
 	// Empty surface


Commit: 053fe65b68d22328f63b1693e06ae19fabb49de3
    https://github.com/scummvm/scummvm/commit/053fe65b68d22328f63b1693e06ae19fabb49de3
Author: Strangerke (strangerke at scummvm.org)
Date: 2014-12-29T21:19:14+01:00

Commit Message:
ACCESS: MM - Fix Sprite Frame loading

Changed paths:
    engines/access/asurface.cpp



diff --git a/engines/access/asurface.cpp b/engines/access/asurface.cpp
index 21bf460..793e6e9 100644
--- a/engines/access/asurface.cpp
+++ b/engines/access/asurface.cpp
@@ -58,7 +58,7 @@ SpriteFrame::SpriteFrame(AccessEngine *vm, Common::SeekableReadStream *stream, i
 	if (vm->getGameID() == GType_MartianMemorandum) {
 		int size = stream->readUint16LE();
 		if (size != frameSize)
-			warning("Unexpected file difference: framesize %d - size %d %d - unknown %d", frameSize, xSize, ySize, unknown);
+			warning("Unexpected file difference: framesize %d - size %d %d - unknown %d", frameSize, xSize, ySize, size);
 	}
 	create(xSize, ySize);
 


Commit: d192d0b60c574ab6928234ea35f72aace396eda4
    https://github.com/scummvm/scummvm/commit/d192d0b60c574ab6928234ea35f72aace396eda4
Author: Strangerke (strangerke at scummvm.org)
Date: 2014-12-29T22:51:15+01:00

Commit Message:
ACCESS: MM - Load TEXPAL

Changed paths:
    engines/access/martian/martian_player.cpp
    engines/access/martian/martian_player.h
    engines/access/martian/martian_room.cpp
    engines/access/player.cpp
    engines/access/player.h



diff --git a/engines/access/martian/martian_player.cpp b/engines/access/martian/martian_player.cpp
index 493776e..f461751 100644
--- a/engines/access/martian/martian_player.cpp
+++ b/engines/access/martian/martian_player.cpp
@@ -53,8 +53,6 @@ void MartianPlayer::load() {
 	_upWalkMax = 14;
 	_downWalkMin = 15;
 	_downWalkMax = 23;
-
-	warning("TODO: Copy texPal into manPal");
 }
 
 } // End of namespace Martian
diff --git a/engines/access/martian/martian_player.h b/engines/access/martian/martian_player.h
index 192f254..63a21a1 100644
--- a/engines/access/martian/martian_player.h
+++ b/engines/access/martian/martian_player.h
@@ -37,7 +37,7 @@ private:
 	MartianEngine *_game;
 public:
 	MartianPlayer(AccessEngine *vm);
-
+	Resource *_texPal;
 	virtual void load();
 };
 
diff --git a/engines/access/martian/martian_room.cpp b/engines/access/martian/martian_room.cpp
index 972aada..dfc0dbc 100644
--- a/engines/access/martian/martian_room.cpp
+++ b/engines/access/martian/martian_room.cpp
@@ -43,13 +43,12 @@ void MartianRoom::loadRoom(int roomNumber) {
 }
 
 void MartianRoom::reloadRoom() {
-	warning("TODO: Load TEXPAL.COL");
 //	_vm->_currentMan = _roomFlag;
 //	_vm->_currentManOld = _roomFlag;
 //	_vm->_manScaleOff = 0;
 
+	_vm->_player->loadTexPalette();
 	_vm->_player->loadSprites("TEX.LZ");
-	warning("TODO: Load TEXPAL.COL");
 
 	loadRoom(_vm->_player->_roomNumber);
 
diff --git a/engines/access/player.cpp b/engines/access/player.cpp
index 1fe58c6..41c5b47 100644
--- a/engines/access/player.cpp
+++ b/engines/access/player.cpp
@@ -146,10 +146,27 @@ void Player::load() {
 	}
 }
 
+void Player::loadTexPalette() {
+	Resource *_texPal = _vm->_files->loadFile("TEXPAL.COL");
+	int size = _texPal->_size;
+	_manPal1 = new byte[size];
+	memcpy(_manPal1, _texPal->data(), size);	
+}
+
 void Player::loadSprites(const Common::String &name) {
 	freeSprites();
 
 	Resource *data = _vm->_files->loadFile(name);
+
+#if 0
+	Common::DumpFile *outFile = new Common::DumpFile();
+	Common::String outName = name + ".dump";
+	outFile->open(outName);
+	outFile->write(data->data(), data->_size);
+	outFile->finalize();
+	outFile->close();
+#endif
+
 	_playerSprites1 = new SpriteResource(_vm, data);
 	delete data;
 }
diff --git a/engines/access/player.h b/engines/access/player.h
index 1b33ae6..1e66a72 100644
--- a/engines/access/player.h
+++ b/engines/access/player.h
@@ -124,6 +124,8 @@ public:
 
 	virtual void load();
 
+	void loadTexPalette();
+
 	void loadSprites(const Common::String &name);
 
 	void freeSprites();


Commit: f96dbd52c793a6b96bee8ecde0148ae85dd9fd9e
    https://github.com/scummvm/scummvm/commit/f96dbd52c793a6b96bee8ecde0148ae85dd9fd9e
Author: Strangerke (strangerke at scummvm.org)
Date: 2014-12-31T10:10:32+01:00

Commit Message:
ACCESS: MM - Implement some more tex palette handling

Changed paths:
    engines/access/martian/martian_room.cpp
    engines/access/player.cpp
    engines/access/player.h



diff --git a/engines/access/martian/martian_room.cpp b/engines/access/martian/martian_room.cpp
index dfc0dbc..c4f38d8 100644
--- a/engines/access/martian/martian_room.cpp
+++ b/engines/access/martian/martian_room.cpp
@@ -82,7 +82,12 @@ void MartianRoom::reloadRoom1() {
 	setWallCodes();
 	buildScreen();
 	_vm->copyBF2Vid();
+
+	//
 	warning("TODO: setManPalette");
+	Common::copy(_vm->_player->_manPal1 + 0x2A0, _vm->_player->_manPal1 + 0x2A0 + 0x42, _vm->_screen->_manPal);
+	//
+
 	_vm->_events->showCursor();
 	_vm->_player->_frame = 0;
 	_vm->_oldRects.clear();
diff --git a/engines/access/player.cpp b/engines/access/player.cpp
index 41c5b47..fe555ec 100644
--- a/engines/access/player.cpp
+++ b/engines/access/player.cpp
@@ -140,7 +140,8 @@ void Player::load() {
 
 	_playerSprites = _playerSprites1;
 	if (_manPal1) {
-		Common::copy(_manPal1 + 0x270, _manPal1 + 0x270 + 0x60, _vm->_screen->_manPal);
+		// Those values are from MM as Amazon doesn't use it
+		Common::copy(_manPal1 + 0x2A0, _manPal1 + 0x2A0 + 0x42, _vm->_screen->_manPal);
 	} else {
 		Common::fill(_vm->_screen->_manPal, _vm->_screen->_manPal + 0x60, 0);
 	}
@@ -149,6 +150,7 @@ void Player::load() {
 void Player::loadTexPalette() {
 	Resource *_texPal = _vm->_files->loadFile("TEXPAL.COL");
 	int size = _texPal->_size;
+	assert(size == 768);
 	_manPal1 = new byte[size];
 	memcpy(_manPal1, _texPal->data(), size);	
 }
diff --git a/engines/access/player.h b/engines/access/player.h
index 1e66a72..db88892 100644
--- a/engines/access/player.h
+++ b/engines/access/player.h
@@ -56,7 +56,6 @@ protected:
 	int _diagUpWalkMin, _diagUpWalkMax;
 	int _diagDownWalkMin, _diagDownWalkMax;
 	SpriteResource *_playerSprites1;
-	byte *_manPal1;
 	int _scrollEnd;
 	int _inactiveYOff;
 
@@ -82,6 +81,7 @@ public:
 	Direction _playerDirection;
 	SpriteResource *_playerSprites;
 	// Fields in original Player structure
+	byte *_manPal1;
 	byte *_monData;
 	int *_walkOffRight;
 	int *_walkOffLeft;


Commit: 3ac8a26cb950f63c2f3b25995d268a30b470d1fd
    https://github.com/scummvm/scummvm/commit/3ac8a26cb950f63c2f3b25995d268a30b470d1fd
Author: Strangerke (strangerke at scummvm.org)
Date: 2014-12-31T10:11:15+01:00

Commit Message:
ACCESS: MM - Start implementing intro

Changed paths:
    engines/access/martian/martian_game.cpp
    engines/access/martian/martian_game.h
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index 6722120..3371610 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -110,33 +110,78 @@ void MartianEngine::playGame() {
 	} while (_restartFl);
 }
 
+bool MartianEngine::showCredits() {
+	_events->hideCursor();
+	_screen->clearBuffer();
+	_destIn = _screen;
+
+	int val1 = _demoStream->readSint16LE();
+	int val2 = 0;
+	int val3 = 0;
+
+	while(val1 != -1) {
+		val2 = _demoStream->readSint16LE();
+		val3 = _demoStream->readSint16LE();
+		_screen->plotImage(_introObjects, val3, Common::Point(val1, val2));
+
+		val1 = _demoStream->readSint16LE();
+	}
+
+	val2 = _demoStream->readSint16LE();
+	if (val2 == -1) {
+		_events->showCursor();
+		_screen->forceFadeOut();
+		return true;
+	}
+
+	_screen->forceFadeIn();
+	_timers[6]._timer = val2;
+	_timers[6]._initTm = val2;
+
+	while (!shouldQuit() && !_events->isKeyMousePressed() && _timers[6]._timer) {
+		_events->pollEventsAndWait();
+	}
+
+	_events->showCursor();
+	_screen->forceFadeOut();
+
+	if (_events->_rightButton)
+		return true;
+	else
+		return false;
+}
+
 void MartianEngine::doIntroduction() {
-	_screen->setInitialPalettte();
-	_events->setCursor(CURSOR_ARROW);
+	_midi->loadMusic(47, 3);
+	_midi->midiPlay();
+	_screen->setDisplayScan();
+	_events->hideCursor();
+	_screen->forceFadeOut();
+	Resource *data = _files->loadFile(41, 1);
+	_introObjects = new SpriteResource(this, data);
+	delete data;
+
+	_files->loadScreen(41, 0);
+	_buffer2.copyFrom(*_screen);
+	_buffer1.copyFrom(*_screen);
 	_events->showCursor();
-	_screen->setPanel(0);
+	_demoStream = new Common::MemoryReadStream(DEMO_DATA, 180);
 
-	// TODO: Worry about implementing full intro sequence later
-	return;
+	if (!showCredits()) {
+		_screen->copyFrom(_buffer2);
+		_screen->forceFadeIn();
 
-	doTitle();
-	if (shouldQuit())
-		return;
+		_events->_vbCount = 550;
+		while (!shouldQuit() && !_events->isKeyMousePressed() && _events->_vbCount > 0)
+			_events->pollEventsAndWait();
 
-	if (!_skipStart) {
-		_screen->setPanel(3);
-		doOpening();
-		if (shouldQuit())
-			return;
+		_screen->forceFadeOut();
+		while (!shouldQuit() && !_events->isKeyMousePressed()&& !showCredits())
+			_events->pollEventsAndWait();
 
-		if (!_skipStart) {
-			//doTent();
-			if (shouldQuit())
-				return;
-		}
+		warning("TODO: Free word_21E2B");
+		_midi->freeMusic();
 	}
-
-	doTitle();
 }
 
 void MartianEngine::doTitle() {
diff --git a/engines/access/martian/martian_game.h b/engines/access/martian/martian_game.h
index 812aa37..e1606d7 100644
--- a/engines/access/martian/martian_game.h
+++ b/engines/access/martian/martian_game.h
@@ -32,12 +32,15 @@ namespace Martian {
 class MartianEngine : public AccessEngine {
 private:
 	bool _skipStart;
-
+	SpriteResource *_introObjects;
+	Common::MemoryReadStream *_demoStream;
 	/**
 	 * Do the game introduction
 	 */
 	void doIntroduction();
 
+	bool showCredits();
+
 	/**
 	 * Do title sequence
 	 */
@@ -56,7 +59,6 @@ private:
 	void initObjects();
 	void configSelect();
 	void initVariables();
-
 protected:
 	/**
 	 * Play the game
diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index 78d14b7..22a0cf1 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -724,6 +724,27 @@ const int SIDEOFFL[] = { 11, 6, 1,  4, 10, 6, 1,  4, 0, 0, 0, 0 };
 const int SIDEOFFU[] = {  1, 2, 0,  2,  2, 1, 1,  0, 0, 0, 0, 0 };
 const int SIDEOFFD[] = {  2, 0, 1,  1,  0, 1, 1,  1, 2, 0, 0, 0 };
 
+const byte DEMO_DATA[] = {
+	0x1F, 0x00, 0x49, 0x00, 0x00, 0x00, 0xB7, 0x00, 0x49, 0x00,
+	0x01, 0x00, 0x79, 0x00, 0x6F, 0x00, 0x02, 0x00, 0xFF, 0xFF,
+	0xEA, 0x01, 0x75, 0x00, 0x46, 0x00, 0x03, 0x00, 0x46, 0x00,
+	0x5E, 0x00, 0x04, 0x00, 0xFF, 0xFF, 0xEA, 0x01, 0x72, 0x00,
+	0x3E, 0x00, 0x05, 0x00, 0x46, 0x00, 0x57, 0x00, 0x04, 0x00,
+	0x5C, 0x00, 0x6E, 0x00, 0x06, 0x00, 0xFF, 0xFF, 0xEA, 0x01,
+	0x63, 0x00, 0x48, 0x00, 0x07, 0x00, 0x2A, 0x00, 0x65, 0x00,
+	0x08, 0x00, 0xFF, 0xFF, 0xEA, 0x01, 0x7E, 0x00, 0x39, 0x00,
+	0x09, 0x00, 0x5C, 0x00, 0x57, 0x00, 0x06, 0x00, 0x45, 0x00,
+	0x6B, 0x00, 0x04, 0x00, 0xFF, 0xFF, 0xEA, 0x01, 0x5F, 0x00,
+	0x46, 0x00, 0x0A, 0x00, 0x67, 0x00, 0x62, 0x00, 0x0B, 0x00,
+	0x47, 0x00, 0x76, 0x00, 0x0C, 0x00, 0xFF, 0xFF, 0xEA, 0x01,
+	0x62, 0x00, 0x38, 0x00, 0x0D, 0x00, 0x47, 0x00, 0x55, 0x00,
+	0x0E, 0x00, 0x49, 0x00, 0x6A, 0x00, 0x0F, 0x00, 0xFF, 0xFF,
+	0xEA, 0x01, 0x18, 0x00, 0x22, 0x00, 0x10, 0x00, 0x17, 0x00,
+	0x3E, 0x00, 0x11, 0x00, 0x16, 0x00, 0x52, 0x00, 0x12, 0x00,
+	0xEE, 0x00, 0x7B, 0x00, 0x13, 0x00, 0xB5, 0x00, 0x93, 0x00,
+	0x0B, 0x00, 0xFF, 0xFF, 0xF4, 0x01, 0xFF, 0xFF, 0xFF, 0xFF
+};
+
 } // End of namespace Martian
 
 } // End of namespace Access
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index 36b4ce3..67f8cb4 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -50,6 +50,7 @@ extern const int SIDEOFFL[];
 extern const int SIDEOFFU[];
 extern const int SIDEOFFD[];
 
+extern const byte DEMO_DATA[];
 } // End of namespace Martian
 
 } // End of namespace Access


Commit: f6fb26ea664184669f6b2a576831325d852ea71f
    https://github.com/scummvm/scummvm/commit/f6fb26ea664184669f6b2a576831325d852ea71f
Author: Strangerke (strangerke at scummvm.org)
Date: 2014-12-31T13:13:47+01:00

Commit Message:
ACCESS: MM - Remove unused intro functions, fix display in showCredits

Changed paths:
    engines/access/martian/martian_game.cpp
    engines/access/martian/martian_game.h



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index 3371610..6a96160 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -112,7 +112,7 @@ void MartianEngine::playGame() {
 
 bool MartianEngine::showCredits() {
 	_events->hideCursor();
-	_screen->clearBuffer();
+	_screen->clearScreen();
 	_destIn = _screen;
 
 	int val1 = _demoStream->readSint16LE();
@@ -184,55 +184,6 @@ void MartianEngine::doIntroduction() {
 	}
 }
 
-void MartianEngine::doTitle() {
-	/*
-	_screen->setDisplayScan();
-	_destIn = &_buffer2;
-
-	_screen->forceFadeOut();
-	_events->hideCursor();
-
-	_sound->queueSound(0, 98, 30);
-
-	_files->_setPaletteFlag = false;
-	_files->loadScreen(0, 3);
-	
-	_buffer2.copyFrom(*_screen);
-	_buffer1.copyFrom(*_screen);
-	_screen->forceFadeIn();
-	_sound->playSound(1);
-
-	Resource *spriteData = _files->loadFile(0, 2);
-	_objectsTable[0] = new SpriteResource(this, spriteData);
-	delete spriteData;
-
-	_sound->playSound(1);
-
-	_files->_setPaletteFlag = false;
-	_files->loadScreen(0, 4);
-	_sound->playSound(1);
-
-	_buffer2.copyFrom(*_screen);
-	_buffer1.copyFrom(*_screen);
-	_sound->playSound(1);
-
-	const int COUNTDOWN[6] = { 2, 0x80, 1, 0x7d, 0, 0x87 };
-	for (_pCount = 0; _pCount < 3; ++_pCount) {
-		_buffer2.copyFrom(_buffer1);
-		int id = READ_LE_UINT16(COUNTDOWN + _pCount * 4);
-		int xp = READ_LE_UINT16(COUNTDOWN + _pCount * 4 + 2);
-		_screen->plotImage(_objectsTable[0], id, Common::Point(xp, 71));
-	}
-	// TODO: More to do
-
-	delete _objectsTable[0];
-	*/
-}
-
-void MartianEngine::doOpening() {
-	warning("TODO doOpening");
-}
-
 void MartianEngine::setupGame() {
 
 	// Setup timers
diff --git a/engines/access/martian/martian_game.h b/engines/access/martian/martian_game.h
index e1606d7..99d4926 100644
--- a/engines/access/martian/martian_game.h
+++ b/engines/access/martian/martian_game.h
@@ -42,16 +42,6 @@ private:
 	bool showCredits();
 
 	/**
-	 * Do title sequence
-	 */
-	void doTitle();
-
-	/**
-	 * Do opening sequence
-	 */
-	void doOpening();
-
-	/**
 	 * Setup variables for the game
 	 */
 	void setupGame();


Commit: e83e55e7be274ea884f144ce69849e8bc65b479b
    https://github.com/scummvm/scummvm/commit/e83e55e7be274ea884f144ce69849e8bc65b479b
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-01T15:35:20+01:00

Commit Message:
ACCESS: MM - Implement the display of notes at the beginning of chapters (WIP)

Changed paths:
    engines/access/martian/martian_game.cpp
    engines/access/martian/martian_game.h
    engines/access/martian/martian_scripts.cpp
    engines/access/martian/martian_scripts.h
    engines/access/sound.cpp
    engines/access/sound.h



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index 6a96160..a14d783 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -75,6 +75,88 @@ void MartianEngine::initVariables() {
 	_numAnimTimers = 0;
 }
 
+void MartianEngine::sub13E1F() {
+	_events->hideCursor();
+
+	_screen->_orgX1 = 58;
+	_screen->_orgY1 = 124;
+	_screen->_orgX2 = 297;
+	_screen->_orgY2 = 199;
+	_screen->drawRect();
+
+	_events->showCursor();
+}
+
+void MartianEngine::sub13E4C(const Common::String &msg) {
+	_fonts._charSet._lo = 1;
+	_fonts._charSet._hi = 8;
+	_fonts._charFor._lo = 0;
+	_fonts._charFor._hi = 255;
+
+	_screen->_maxChars = 40;
+	_screen->_printOrg = _screen->_printStart = Common::Point(59, 124);
+	
+	sub13E1F();
+
+	Common::String lines = msg;
+	Common::String line;
+	int width = 0;
+	bool lastLine = false;
+	do {
+		lastLine = _fonts._font2.getLine(lines, _screen->_maxChars * 6, line, width);
+
+		// Set font colors
+		_fonts._font2._fontColors[0] = 0;
+		_fonts._font2._fontColors[1] = 27;
+		_fonts._font2._fontColors[2] = 28;
+		_fonts._font2._fontColors[3] = 29;
+
+		_fonts._font2.drawString(_screen, line, _screen->_printOrg);
+		_screen->_printOrg = Common::Point(_screen->_printStart.x, _screen->_printOrg.y + 6);
+
+		if (_screen->_printOrg.y == 196) {
+			_events->waitKeyMouse();
+			sub13E1F();
+			_screen->_printOrg = _screen->_printStart;
+		}
+	} while (!lastLine);
+	_events->waitKeyMouse();
+}
+
+void MartianEngine::doSpecial5(int param1) {
+	warning("TODO: Push midi song");
+	_midi->stopSong();
+	_midi->_byte1F781 = false;
+	_midi->loadMusic(47, 4);
+	_midi->midiPlay();
+	_screen->setDisplayScan();
+	_events->clearEvents();
+	_screen->forceFadeOut();
+	_events->hideCursor();
+	_files->loadScreen("DATA.SC");
+	_events->showCursor();
+	_screen->setIconPalette();
+	_screen->forceFadeIn();
+	warning("TODO: LoadCells");
+	_timers[20]._timer = _timers[20]._initTm = 30;
+	Resource *_word20060 = _files->loadFile("NOTES.DAT");
+	_word20060->_stream->skip(param1 * 2);
+	int pos = _word20060->_stream->readUint16LE();
+	_word20060->_stream->seek(pos);
+	Common::String msg = "";
+	byte c;
+	while ((c = (char)_word20060->_stream->readByte()) != '\0')
+		msg += c;
+
+	sub13E4C(msg);
+	
+	_midi->stopSong();
+	_midi->freeMusic();
+
+	warning("TODO: Pop Midi");
+	// _midi->_byte1F781 = true;
+}
+
 void MartianEngine::playGame() {
 	// Initialize Amazon game-specific objects
 	initObjects();
@@ -85,9 +167,14 @@ void MartianEngine::playGame() {
 
 	if (_loadSaveSlot == -1) {
 		// Do introduction
-		doIntroduction();
+//		doCredits();
 		if (shouldQuit())
 			return;
+		
+		doSpecial5(4);
+		if (shouldQuit())
+			return;
+		_screen->forceFadeOut();
 	}
 
 	do {
@@ -135,10 +222,9 @@ bool MartianEngine::showCredits() {
 	}
 
 	_screen->forceFadeIn();
-	_timers[6]._timer = val2;
-	_timers[6]._initTm = val2;
+	_timers[3]._timer = _timers[3]._initTm = val2;
 
-	while (!shouldQuit() && !_events->isKeyMousePressed() && _timers[6]._timer) {
+	while (!shouldQuit() && !_events->isKeyMousePressed() && _timers[3]._timer) {
 		_events->pollEventsAndWait();
 	}
 
@@ -151,7 +237,8 @@ bool MartianEngine::showCredits() {
 		return false;
 }
 
-void MartianEngine::doIntroduction() {
+void MartianEngine::doCredits() {
+	_midi->_byte1F781 = false;
 	_midi->loadMusic(47, 3);
 	_midi->midiPlay();
 	_screen->setDisplayScan();
diff --git a/engines/access/martian/martian_game.h b/engines/access/martian/martian_game.h
index 99d4926..bd32527 100644
--- a/engines/access/martian/martian_game.h
+++ b/engines/access/martian/martian_game.h
@@ -37,7 +37,7 @@ private:
 	/**
 	 * Do the game introduction
 	 */
-	void doIntroduction();
+	void doCredits();
 
 	bool showCredits();
 
@@ -56,11 +56,15 @@ protected:
 	virtual void playGame();
 
 	virtual void dead(int deathId) {}
+
+	void sub13E1F();
+	void sub13E4C(const Common::String &msg);
 public:
 	MartianEngine(OSystem *syst, const AccessGameDescription *gameDesc);
 
 	virtual ~MartianEngine();
 
+	void doSpecial5(int param1);
 	void drawHelp();
 	virtual void establish(int esatabIndex, int sub) {};
 };
diff --git a/engines/access/martian/martian_scripts.cpp b/engines/access/martian/martian_scripts.cpp
index 0578872..8d936ba 100644
--- a/engines/access/martian/martian_scripts.cpp
+++ b/engines/access/martian/martian_scripts.cpp
@@ -34,7 +34,36 @@ MartianScripts::MartianScripts(AccessEngine *vm) : Scripts(vm) {
 	_game = (MartianEngine *)_vm;
 }
 
+void MartianScripts::cmdSpecial5(int param1) {
+	_game->doSpecial5(param1);
+}
+
 void MartianScripts::executeSpecial(int commandIndex, int param1, int param2) {
+	switch (commandIndex) {
+	case 0:
+		warning("TODO: cmdSpecial0");
+		break;
+	case 1:
+		warning("TODO: cmdSpecial1");
+		break;
+	case 2:
+		warning("TODO: cmdSpecial2");
+		break;
+	case 3:
+		warning("TODO: cmdSpecial3");
+		break;
+	case 4:
+		warning("TODO: cmdSpecial4");
+		break;
+	case 5:
+		cmdSpecial5(param1);
+		break;
+	case 6:
+		warning("TODO: cmdSpecial6");
+		break;
+	default:
+		warning("Unexpected Special code %d - Skipped", commandIndex);
+	}
 }
 
 typedef void(MartianScripts::*MartianScriptMethodPtr)();
diff --git a/engines/access/martian/martian_scripts.h b/engines/access/martian/martian_scripts.h
index fc7495f..125f1e4 100644
--- a/engines/access/martian/martian_scripts.h
+++ b/engines/access/martian/martian_scripts.h
@@ -35,9 +35,13 @@ class MartianEngine;
 class MartianScripts : public Scripts {
 private:
 	MartianEngine *_game;
+
+	void cmdSpecial5(int param1);
+
 protected:
 	virtual void executeSpecial(int commandIndex, int param1, int param2);
 	virtual void executeCommand(int commandIndex);
+
 public:
 	MartianScripts(AccessEngine *vm);
 };
diff --git a/engines/access/sound.cpp b/engines/access/sound.cpp
index a7d96da..9ade99c 100644
--- a/engines/access/sound.cpp
+++ b/engines/access/sound.cpp
@@ -178,6 +178,7 @@ MusicManager::MusicManager(AccessEngine *vm) : _vm(vm) {
 	_music = nullptr;
 	_tempMusic = nullptr;
 	_isLooping = false;
+	_byte1F781 = false;
 
 	MidiPlayer::createDriver();
 	MidiDriver::detectDevice(MDT_MIDI | MDT_ADLIB | MDT_PREFER_GM);
@@ -217,6 +218,12 @@ void MusicManager::midiPlay() {
 
 	if (READ_BE_UINT32(_music->data()) != MKTAG('F', 'O', 'R', 'M')) {
 		warning("midiPlay() Unexpected signature");
+		Common::DumpFile *outFile = new Common::DumpFile();
+		Common::String outName = "music.dump";
+		outFile->open(outName);
+		outFile->write(_music->data(), _music->_size);
+		outFile->finalize();
+		outFile->close();
 		_isPlaying = false;
 	} else {
 		_parser = MidiParser::createParser_XMIDI();
diff --git a/engines/access/sound.h b/engines/access/sound.h
index d0f4584..6bfdbcd 100644
--- a/engines/access/sound.h
+++ b/engines/access/sound.h
@@ -82,6 +82,7 @@ private:
 
 public:
 	Resource *_music;
+	bool _byte1F781;
 
 public:
 	MusicManager(AccessEngine *vm);


Commit: 0f11287b74664a509b85b30e722a1b706c0da0a7
    https://github.com/scummvm/scummvm/commit/0f11287b74664a509b85b30e722a1b706c0da0a7
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-02T00:16:46+01:00

Commit Message:
ACCESS: MM - Fix the color of notes

Changed paths:
    engines/access/martian/martian_game.cpp



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index a14d783..22a3c47 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -82,6 +82,7 @@ void MartianEngine::sub13E1F() {
 	_screen->_orgY1 = 124;
 	_screen->_orgX2 = 297;
 	_screen->_orgY2 = 199;
+	_screen->_lColor = 51;
 	_screen->drawRect();
 
 	_events->showCursor();
@@ -103,15 +104,8 @@ void MartianEngine::sub13E4C(const Common::String &msg) {
 	int width = 0;
 	bool lastLine = false;
 	do {
-		lastLine = _fonts._font2.getLine(lines, _screen->_maxChars * 6, line, width);
-
-		// Set font colors
-		_fonts._font2._fontColors[0] = 0;
-		_fonts._font2._fontColors[1] = 27;
-		_fonts._font2._fontColors[2] = 28;
-		_fonts._font2._fontColors[3] = 29;
-
-		_fonts._font2.drawString(_screen, line, _screen->_printOrg);
+		lastLine = _fonts._font1.getLine(lines, _screen->_maxChars * 6, line, width);
+		_fonts._font1.drawString(_screen, line, _screen->_printOrg);
 		_screen->_printOrg = Common::Point(_screen->_printStart.x, _screen->_printOrg.y + 6);
 
 		if (_screen->_printOrg.y == 196) {


Commit: c3e20acdf2fe3e98fbd024cdedbc6c8bf00d9783
    https://github.com/scummvm/scummvm/commit/c3e20acdf2fe3e98fbd024cdedbc6c8bf00d9783
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-02T00:22:54+01:00

Commit Message:
ACCESS: MM - Some renaming

Changed paths:
    engines/access/martian/martian_game.cpp
    engines/access/martian/martian_game.h



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index 22a3c47..a4cc752 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -75,7 +75,7 @@ void MartianEngine::initVariables() {
 	_numAnimTimers = 0;
 }
 
-void MartianEngine::sub13E1F() {
+void MartianEngine::setNoteParams() {
 	_events->hideCursor();
 
 	_screen->_orgX1 = 58;
@@ -88,7 +88,7 @@ void MartianEngine::sub13E1F() {
 	_events->showCursor();
 }
 
-void MartianEngine::sub13E4C(const Common::String &msg) {
+void MartianEngine::displayNote(const Common::String &msg) {
 	_fonts._charSet._lo = 1;
 	_fonts._charSet._hi = 8;
 	_fonts._charFor._lo = 0;
@@ -97,7 +97,7 @@ void MartianEngine::sub13E4C(const Common::String &msg) {
 	_screen->_maxChars = 40;
 	_screen->_printOrg = _screen->_printStart = Common::Point(59, 124);
 	
-	sub13E1F();
+	setNoteParams();
 
 	Common::String lines = msg;
 	Common::String line;
@@ -110,7 +110,7 @@ void MartianEngine::sub13E4C(const Common::String &msg) {
 
 		if (_screen->_printOrg.y == 196) {
 			_events->waitKeyMouse();
-			sub13E1F();
+			setNoteParams();
 			_screen->_printOrg = _screen->_printStart;
 		}
 	} while (!lastLine);
@@ -142,7 +142,7 @@ void MartianEngine::doSpecial5(int param1) {
 	while ((c = (char)_word20060->_stream->readByte()) != '\0')
 		msg += c;
 
-	sub13E4C(msg);
+	displayNote(msg);
 	
 	_midi->stopSong();
 	_midi->freeMusic();
diff --git a/engines/access/martian/martian_game.h b/engines/access/martian/martian_game.h
index bd32527..059644c 100644
--- a/engines/access/martian/martian_game.h
+++ b/engines/access/martian/martian_game.h
@@ -57,8 +57,8 @@ protected:
 
 	virtual void dead(int deathId) {}
 
-	void sub13E1F();
-	void sub13E4C(const Common::String &msg);
+	void setNoteParams();
+	void displayNote(const Common::String &msg);
 public:
 	MartianEngine(OSystem *syst, const AccessGameDescription *gameDesc);
 


Commit: ef1165e8b5a9ec26b5bcaf365769d45b87d80c65
    https://github.com/scummvm/scummvm/commit/ef1165e8b5a9ec26b5bcaf365769d45b87d80c65
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-02T00:44:34+01:00

Commit Message:
ACCESS: MM - More renaming

Changed paths:
    engines/access/martian/martian_game.cpp
    engines/access/martian/martian_game.h



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index a4cc752..8eea5d1 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -133,13 +133,13 @@ void MartianEngine::doSpecial5(int param1) {
 	_screen->forceFadeIn();
 	warning("TODO: LoadCells");
 	_timers[20]._timer = _timers[20]._initTm = 30;
-	Resource *_word20060 = _files->loadFile("NOTES.DAT");
-	_word20060->_stream->skip(param1 * 2);
-	int pos = _word20060->_stream->readUint16LE();
-	_word20060->_stream->seek(pos);
+	Resource *_notesRes = _files->loadFile("NOTES.DAT");
+	_notesRes->_stream->skip(param1 * 2);
+	int pos = _notesRes->_stream->readUint16LE();
+	_notesRes->_stream->seek(pos);
 	Common::String msg = "";
 	byte c;
-	while ((c = (char)_word20060->_stream->readByte()) != '\0')
+	while ((c = (char)_notesRes->_stream->readByte()) != '\0')
 		msg += c;
 
 	displayNote(msg);
@@ -161,10 +161,11 @@ void MartianEngine::playGame() {
 
 	if (_loadSaveSlot == -1) {
 		// Do introduction
-//		doCredits();
+		doCredits();
 		if (shouldQuit())
 			return;
-		
+
+		// Display Notes screen
 		doSpecial5(4);
 		if (shouldQuit())
 			return;
@@ -196,19 +197,19 @@ bool MartianEngine::showCredits() {
 	_screen->clearScreen();
 	_destIn = _screen;
 
-	int val1 = _demoStream->readSint16LE();
+	int val1 = _creditsStream->readSint16LE();
 	int val2 = 0;
 	int val3 = 0;
 
 	while(val1 != -1) {
-		val2 = _demoStream->readSint16LE();
-		val3 = _demoStream->readSint16LE();
+		val2 = _creditsStream->readSint16LE();
+		val3 = _creditsStream->readSint16LE();
 		_screen->plotImage(_introObjects, val3, Common::Point(val1, val2));
 
-		val1 = _demoStream->readSint16LE();
+		val1 = _creditsStream->readSint16LE();
 	}
 
-	val2 = _demoStream->readSint16LE();
+	val2 = _creditsStream->readSint16LE();
 	if (val2 == -1) {
 		_events->showCursor();
 		_screen->forceFadeOut();
@@ -246,7 +247,7 @@ void MartianEngine::doCredits() {
 	_buffer2.copyFrom(*_screen);
 	_buffer1.copyFrom(*_screen);
 	_events->showCursor();
-	_demoStream = new Common::MemoryReadStream(DEMO_DATA, 180);
+	_creditsStream = new Common::MemoryReadStream(DEMO_DATA, 180);
 
 	if (!showCredits()) {
 		_screen->copyFrom(_buffer2);
diff --git a/engines/access/martian/martian_game.h b/engines/access/martian/martian_game.h
index 059644c..03f3e0f 100644
--- a/engines/access/martian/martian_game.h
+++ b/engines/access/martian/martian_game.h
@@ -33,7 +33,7 @@ class MartianEngine : public AccessEngine {
 private:
 	bool _skipStart;
 	SpriteResource *_introObjects;
-	Common::MemoryReadStream *_demoStream;
+	Common::MemoryReadStream *_creditsStream;
 	/**
 	 * Do the game introduction
 	 */


Commit: 539497f009e5c1137017023212055bde6975ae6b
    https://github.com/scummvm/scummvm/commit/539497f009e5c1137017023212055bde6975ae6b
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-02T01:21:34+01:00

Commit Message:
ACCESS: MM - Implement setManPalette

Changed paths:
    engines/access/martian/martian_room.cpp
    engines/access/screen.cpp
    engines/access/screen.h



diff --git a/engines/access/martian/martian_room.cpp b/engines/access/martian/martian_room.cpp
index c4f38d8..10e9d60 100644
--- a/engines/access/martian/martian_room.cpp
+++ b/engines/access/martian/martian_room.cpp
@@ -57,12 +57,7 @@ void MartianRoom::reloadRoom() {
 
 void MartianRoom::reloadRoom1() {
 	_selectCommand = -1;
-
-// CHECKME: Useful?
-//	_vm->_events->setNormalCursor(CURSOR_CROSSHAIRS);
-//	_vm->_mouseMode = 0;
-//	_vm->_boxSelect = true;
-
+	warning("TODO: _word1F968 = -1;");
 	_vm->_player->_playerOff = false;
 
 	_vm->_screen->forceFadeOut();
@@ -83,11 +78,7 @@ void MartianRoom::reloadRoom1() {
 	buildScreen();
 	_vm->copyBF2Vid();
 
-	//
-	warning("TODO: setManPalette");
-	Common::copy(_vm->_player->_manPal1 + 0x2A0, _vm->_player->_manPal1 + 0x2A0 + 0x42, _vm->_screen->_manPal);
-	//
-
+	_vm->_screen->setManPalette();
 	_vm->_events->showCursor();
 	_vm->_player->_frame = 0;
 	_vm->_oldRects.clear();
diff --git a/engines/access/screen.cpp b/engines/access/screen.cpp
index 35069ba..ec2a825 100644
--- a/engines/access/screen.cpp
+++ b/engines/access/screen.cpp
@@ -112,6 +112,10 @@ void Screen::setInitialPalettte() {
 	g_system->getPaletteManager()->setPalette(INITIAL_PALETTE, 0, 18);
 }
 
+void Screen::setManPalette() {
+	Common::copy(_vm->_player->_manPal1 + 0x2A0, _vm->_player->_manPal1 + 0x2A0 + 0x42, _rawPalette + 672);
+}
+
 void Screen::loadPalette(int fileNum, int subfile) {
 	Resource *res = _vm->_files->loadFile(fileNum, subfile);
 	byte *palette = res->data();
diff --git a/engines/access/screen.h b/engines/access/screen.h
index 0fa111c..dcf339a 100644
--- a/engines/access/screen.h
+++ b/engines/access/screen.h
@@ -139,6 +139,11 @@ public:
 	 */
 	void setIconPalette() {}
 
+	/**
+	 * Set Tex palette (Martian Memorandum)
+	 */
+	void setManPalette();
+
 	void loadPalette(int fileNum, int subfile);
 
 	void setPalette();


Commit: 900dc7ffc004d36ff02d38f0cc615098571c7b41
    https://github.com/scummvm/scummvm/commit/900dc7ffc004d36ff02d38f0cc615098571c7b41
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-02T01:46:58+01:00

Commit Message:
ACCESS: MM - Implement setIconPalette for MM

Changed paths:
    engines/access/martian/martian_game.cpp
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h
    engines/access/screen.cpp
    engines/access/screen.h



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index 8eea5d1..5fe0359 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -247,7 +247,7 @@ void MartianEngine::doCredits() {
 	_buffer2.copyFrom(*_screen);
 	_buffer1.copyFrom(*_screen);
 	_events->showCursor();
-	_creditsStream = new Common::MemoryReadStream(DEMO_DATA, 180);
+	_creditsStream = new Common::MemoryReadStream(CREDIT_DATA, 180);
 
 	if (!showCredits()) {
 		_screen->copyFrom(_buffer2);
diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index 22a0cf1..f462329 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -724,7 +724,7 @@ const int SIDEOFFL[] = { 11, 6, 1,  4, 10, 6, 1,  4, 0, 0, 0, 0 };
 const int SIDEOFFU[] = {  1, 2, 0,  2,  2, 1, 1,  0, 0, 0, 0, 0 };
 const int SIDEOFFD[] = {  2, 0, 1,  1,  0, 1, 1,  1, 2, 0, 0, 0 };
 
-const byte DEMO_DATA[] = {
+const byte CREDIT_DATA[] = {
 	0x1F, 0x00, 0x49, 0x00, 0x00, 0x00, 0xB7, 0x00, 0x49, 0x00,
 	0x01, 0x00, 0x79, 0x00, 0x6F, 0x00, 0x02, 0x00, 0xFF, 0xFF,
 	0xEA, 0x01, 0x75, 0x00, 0x46, 0x00, 0x03, 0x00, 0x46, 0x00,
@@ -745,6 +745,14 @@ const byte DEMO_DATA[] = {
 	0x0B, 0x00, 0xFF, 0xFF, 0xF4, 0x01, 0xFF, 0xFF, 0xFF, 0xFF
 };
 
+const byte ICON_DATA[] = {
+	0x3F, 0x3F, 0x00, 0x00, 0x07, 0x16,
+	0x00, 0x0A, 0x1A, 0x00, 0x0D, 0x1F,
+	0x00, 0x11, 0x28, 0x00, 0x15, 0x30,
+	0x00, 0x19, 0x39, 0x00, 0x1B, 0x3F,
+	0x00, 0x2D, 0x3A 
+};
+
 } // End of namespace Martian
 
 } // End of namespace Access
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index 67f8cb4..4a3f227 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -50,7 +50,8 @@ extern const int SIDEOFFL[];
 extern const int SIDEOFFU[];
 extern const int SIDEOFFD[];
 
-extern const byte DEMO_DATA[];
+extern const byte CREDIT_DATA[];
+extern const byte ICON_DATA[];
 } // End of namespace Martian
 
 } // End of namespace Access
diff --git a/engines/access/screen.cpp b/engines/access/screen.cpp
index ec2a825..b7a2d3d 100644
--- a/engines/access/screen.cpp
+++ b/engines/access/screen.cpp
@@ -113,7 +113,13 @@ void Screen::setInitialPalettte() {
 }
 
 void Screen::setManPalette() {
-	Common::copy(_vm->_player->_manPal1 + 0x2A0, _vm->_player->_manPal1 + 0x2A0 + 0x42, _rawPalette + 672);
+	Common::copy(_vm->_screen->_manPal, _vm->_screen->_manPal + 0x42, _rawPalette + 672);
+}
+
+void Screen::setIconPalette() {
+	if (_vm->getGameID() == GType_MartianMemorandum) {
+		Common::copy(Martian::ICON_DATA, Martian::ICON_DATA + 0x1B, _rawPalette + 741);
+	}
 }
 
 void Screen::loadPalette(int fileNum, int subfile) {
diff --git a/engines/access/screen.h b/engines/access/screen.h
index dcf339a..a3b5585 100644
--- a/engines/access/screen.h
+++ b/engines/access/screen.h
@@ -137,7 +137,7 @@ public:
 	/**
 	 * Set icon palette
 	 */
-	void setIconPalette() {}
+	void setIconPalette();
 
 	/**
 	 * Set Tex palette (Martian Memorandum)


Commit: b2a4999f3cbf8808a10ffe5a4cbb1b536e0011d5
    https://github.com/scummvm/scummvm/commit/b2a4999f3cbf8808a10ffe5a4cbb1b536e0011d5
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-02T11:05:21+01:00

Commit Message:
ACCESS: MM - Fix mouse cursor when y between 177 and 184, add a call to takePicture (not yet implemented)

Changed paths:
    engines/access/martian/martian_room.cpp
    engines/access/martian/martian_room.h
    engines/access/room.cpp
    engines/access/room.h



diff --git a/engines/access/martian/martian_room.cpp b/engines/access/martian/martian_room.cpp
index 10e9d60..118679b 100644
--- a/engines/access/martian/martian_room.cpp
+++ b/engines/access/martian/martian_room.cpp
@@ -91,6 +91,12 @@ void MartianRoom::roomSet() {
 	_vm->_scripts->_sequence = 1000;
 	_vm->_scripts->searchForSequence();
 	_vm->_scripts->executeScript();
+
+	for (int i = 0; i < 30; i++)
+		_byte26CD2[i] = 0;
+
+	for (int i = 0; i < 10; i++)
+		_byte26CBC[i] = 0;
 }
 
 void MartianRoom::roomMenu() {
diff --git a/engines/access/martian/martian_room.h b/engines/access/martian/martian_room.h
index cb2a8c2..11501b6 100644
--- a/engines/access/martian/martian_room.h
+++ b/engines/access/martian/martian_room.h
@@ -39,6 +39,9 @@ private:
 	MartianEngine *_game;
 
 	void roomSet();
+
+	int _byte26CD2[30];
+	int _byte26CBC[10];
 protected:
 	virtual void loadRoom(int roomNumber);
 
diff --git a/engines/access/room.cpp b/engines/access/room.cpp
index f7c2eab..79e5200 100644
--- a/engines/access/room.cpp
+++ b/engines/access/room.cpp
@@ -55,6 +55,10 @@ void Room::freeTileData() {
 	_tile = nullptr;
 }
 
+void Room::takePicture() {
+	warning("TODO: takePicture");
+}
+
 void Room::doRoom() {
 	bool reloadFlag = false;
 
@@ -84,9 +88,13 @@ void Room::doRoom() {
 			_vm->_events->pollEventsAndWait();
 			_vm->_canSaveLoad = false;
 
-			_vm->_player->walk();
-			_vm->_midi->midiRepeat();
-			_vm->_player->checkScroll();
+			if ((_vm->getGameID() == GType_MartianMemorandum) && (_vm->_player->_roomNumber == 47)) {
+				takePicture();
+			} else {
+				_vm->_player->walk();
+				_vm->_midi->midiRepeat();
+				_vm->_player->checkScroll();
+			}
 
 			doCommands();
 			if (_vm->shouldQuitOrRestart())
@@ -136,7 +144,8 @@ void Room::doRoom() {
 				} else {
 					_vm->plotList();
 
-					if (_vm->_events->_mousePos.y < 177)
+					if (((_vm->getGameID() == GType_MartianMemorandum) && (_vm->_events->_mousePos.y < 184)) ||
+						((_vm->getGameID() == GType_Amazon) && (_vm->_events->_mousePos.y < 177)))
 						_vm->_events->setCursor(_vm->_events->_normalMouse);
 					else
 						_vm->_events->setCursor(CURSOR_ARROW);
diff --git a/engines/access/room.h b/engines/access/room.h
index 44279fa..dd8a359 100644
--- a/engines/access/room.h
+++ b/engines/access/room.h
@@ -72,6 +72,8 @@ private:
 	int calcLR(int yp);
 	int calcUD(int xp);
 
+	void takePicture();
+
 	/**
 	 * Cycles forwards or backwards through the list of commands
 	 */


Commit: f11032eb4e5591536b6565dcf7d7190777c868d8
    https://github.com/scummvm/scummvm/commit/f11032eb4e5591536b6565dcf7d7190777c868d8
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-02T21:34:48+01:00

Commit Message:
ACCESS: MM - Fix menu position

Changed paths:
    engines/access/martian/martian_room.cpp



diff --git a/engines/access/martian/martian_room.cpp b/engines/access/martian/martian_room.cpp
index 118679b..38361e5 100644
--- a/engines/access/martian/martian_room.cpp
+++ b/engines/access/martian/martian_room.cpp
@@ -107,8 +107,8 @@ void MartianRoom::roomMenu() {
 	_vm->_screen->saveScreen();
 	_vm->_screen->setDisplayScan();
 	_vm->_destIn = _vm->_screen;	// TODO: Redundant
-	_vm->_screen->plotImage(spr, 0, Common::Point(0, 177));
-	_vm->_screen->plotImage(spr, 1, Common::Point(143, 177));
+	_vm->_screen->plotImage(spr, 0, Common::Point(5, 184));
+	_vm->_screen->plotImage(spr, 1, Common::Point(155, 184));
 
 	_vm->_screen->restoreScreen();
 	delete spr;


Commit: 56754c2a9d98ba41f97e0596fd0015f3edb07366
    https://github.com/scummvm/scummvm/commit/56754c2a9d98ba41f97e0596fd0015f3edb07366
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-02T22:34:45+01:00

Commit Message:
ACCESS: MM - Make RMOUSE game-specific

Changed paths:
    engines/access/amazon/amazon_logic.cpp
    engines/access/amazon/amazon_resources.cpp
    engines/access/amazon/amazon_resources.h
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h
    engines/access/resources.cpp
    engines/access/resources.h
    engines/access/room.cpp
    engines/access/room.h



diff --git a/engines/access/amazon/amazon_logic.cpp b/engines/access/amazon/amazon_logic.cpp
index 436a875..d24629a 100644
--- a/engines/access/amazon/amazon_logic.cpp
+++ b/engines/access/amazon/amazon_logic.cpp
@@ -1591,7 +1591,7 @@ void River::moveCanoe() {
 		moveCanoe2();
 	} else {
 		if (events._leftButton && pt.y >= 140) {
-			if (pt.x < RMOUSE[8][0]) {
+			if (pt.x < _vm->_room->_rMouse[8][0]) {
 				// Disk icon wasn't clicked
 				_vm->_scripts->printString(BAR_MESSAGE);
 			} else {
diff --git a/engines/access/amazon/amazon_resources.cpp b/engines/access/amazon/amazon_resources.cpp
index 2010c7d..2b36ca9 100644
--- a/engines/access/amazon/amazon_resources.cpp
+++ b/engines/access/amazon/amazon_resources.cpp
@@ -2406,6 +2406,11 @@ const int CAST_END_OBJ1[4][4] = {
 	{ 3, 103, 1300, 10 }
 };
 
-} // End of namespace Amazon
+const int RMOUSE[10][2] = {
+	{ 0, 35 }, { 0, 0 }, { 36, 70 }, { 71, 106 }, { 107, 141 },
+	{ 142, 177 }, { 178, 212 }, { 213, 248 }, { 249, 283 }, { 284, 318 }
+};
 
+
+} // End of namespace Amazon
 } // End of namespace Access
diff --git a/engines/access/amazon/amazon_resources.h b/engines/access/amazon/amazon_resources.h
index a952860..190424b 100644
--- a/engines/access/amazon/amazon_resources.h
+++ b/engines/access/amazon/amazon_resources.h
@@ -138,11 +138,11 @@ extern const int HELP1COORDS[2][4];
 extern const int RIVER1OBJ[23][4];
 
 extern const int CAST_END_OBJ[26][4];
-
 extern const int CAST_END_OBJ1[4][4];
 
-} // End of namespace Amazon
+extern const int RMOUSE[10][2];
 
+} // End of namespace Amazon
 } // End of namespace Access
 
 #endif /* ACCESS_AMAZON_RESOURCES_H */
diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index f462329..f460800 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -753,6 +753,10 @@ const byte ICON_DATA[] = {
 	0x00, 0x2D, 0x3A 
 };
 
-} // End of namespace Martian
+const int RMOUSE[10][2] = {
+	{ 7, 36 },    { 38, 68 },   { 70, 99 },   { 102, 125 }, { 128, 152 },
+	{ 155, 185 }, { 188, 216 }, { 219, 260 }, { 263, 293 }, { 295, 214 }
+};
 
+} // End of namespace Martian
 } // End of namespace Access
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index 4a3f227..593681a 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -52,8 +52,11 @@ extern const int SIDEOFFD[];
 
 extern const byte CREDIT_DATA[];
 extern const byte ICON_DATA[];
-} // End of namespace Martian
 
+
+extern const int RMOUSE[10][2];
+
+} // End of namespace Martian
 } // End of namespace Access
 
 #endif /* ACCESS_MARTIAN_RESOURCES_H */
diff --git a/engines/access/resources.cpp b/engines/access/resources.cpp
index 4157cdf..118e887 100644
--- a/engines/access/resources.cpp
+++ b/engines/access/resources.cpp
@@ -59,11 +59,6 @@ const int DIAGOFFULY[] = { 3, 3, 1, 2, 2, 1, 1, 1, 0 };
 const int DIAGOFFDLX[] = { 4, 5, 3, 3, 5, 4, 6, 1, 0 };
 const int DIAGOFFDLY[] = { 2, 2, 1, 2, 3, 1, 2, 1, 0 };
 
-const int RMOUSE[10][2] = {
-	{ 0, 35 }, { 0, 0 }, { 36, 70 }, { 71, 106 }, { 107, 141 },
-	{ 142, 177 }, { 178, 212 }, { 213, 248 }, { 249, 283 }, { 284, 318 }
-};
-
 const char *const LOOK_MESSAGE = "LOOKING THERE REVEALS NOTHING OF INTEREST.";
 const char *const GET_MESSAGE  = "YOU CAN'T TAKE THAT.";
 const char *const OPEN_MESSAGE = "THAT DOESN'T OPEN.";
diff --git a/engines/access/resources.h b/engines/access/resources.h
index 8d59b1b..2ef931b 100644
--- a/engines/access/resources.h
+++ b/engines/access/resources.h
@@ -42,8 +42,6 @@ extern const int DIAGOFFULY[];
 extern const int DIAGOFFDLX[];
 extern const int DIAGOFFDLY[];
 
-extern const int RMOUSE[10][2];
-
 extern const char *const GENERAL_MESSAGES[];
 
 extern const int INVCOORDS[][4];
diff --git a/engines/access/room.cpp b/engines/access/room.cpp
index 79e5200..f10ba86 100644
--- a/engines/access/room.cpp
+++ b/engines/access/room.cpp
@@ -38,6 +38,23 @@ Room::Room(AccessEngine *vm) : Manager(vm) {
 	_selectCommand = 0;
 	_conFlag = false;
 	_selectCommand = -1;
+
+	switch (vm->getGameID()) {
+	case GType_Amazon:
+		for (int i = 0; i < 10; i++) {
+			_rMouse[i][0] = Amazon::RMOUSE[i][0];
+			_rMouse[i][1] = Amazon::RMOUSE[i][1];
+		}
+		break;
+	case GType_MartianMemorandum:
+		for (int i = 0; i < 10; i++) {
+			_rMouse[i][0] = Martian::RMOUSE[i][0];
+			_rMouse[i][1] = Martian::RMOUSE[i][1];
+		}
+		break;
+	default:
+		error("Game not supported");
+	}
 }
 
 Room::~Room() {
@@ -464,8 +481,8 @@ void Room::doCommands() {
 		if (_vm->_events->_mouseRow >= 22) {
 			// Mouse in user interface area
 			for (commandId = 0; commandId < 10; ++commandId) {
-				if (_vm->_events->_mousePos.x >= RMOUSE[commandId][0] &&
-					_vm->_events->_mousePos.x < RMOUSE[commandId][1])
+				if (_vm->_events->_mousePos.x >= _rMouse[commandId][0] &&
+					_vm->_events->_mousePos.x < _rMouse[commandId][1])
 					break;
 			}
 			if (commandId < 10)
@@ -564,7 +581,7 @@ void Room::executeCommand(int commandId) {
 
 	// Draw the button as selected
 	_vm->_screen->plotImage(spr, _selectCommand + 2,
-		Common::Point(RMOUSE[_selectCommand][0], 176));
+		Common::Point(_rMouse[_selectCommand][0], (_vm->getGameID() == GType_MartianMemorandum) ? 184 : 176));
 
 	_vm->_screen->restoreScreen();
 	_vm->_boxSelect = true;
diff --git a/engines/access/room.h b/engines/access/room.h
index dd8a359..2ecc1e8 100644
--- a/engines/access/room.h
+++ b/engines/access/room.h
@@ -129,6 +129,7 @@ public:
 	int _tileSize;
 	int _selectCommand;
 	bool _conFlag;
+	int _rMouse[10][2];
 public:
 	Room(AccessEngine *vm);
 


Commit: 022b81bbc3e1cc20b88b6984c3ef94baaadea17f
    https://github.com/scummvm/scummvm/commit/022b81bbc3e1cc20b88b6984c3ef94baaadea17f
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-02T22:49:36+01:00

Commit Message:
ACCESS: MM - Fix charMenu

Changed paths:
    engines/access/char.cpp



diff --git a/engines/access/char.cpp b/engines/access/char.cpp
index 49b8c2b..01b3349 100644
--- a/engines/access/char.cpp
+++ b/engines/access/char.cpp
@@ -158,8 +158,14 @@ void CharManager::charMenu() {
 	screen.saveScreen();
 	screen.setDisplayScan();
 
-	screen.plotImage(spr, 17, Common::Point(0, 176));
-	screen.plotImage(spr, 18, Common::Point(155, 176));
+	if (_vm->getGameID() == GType_MartianMemorandum) {
+		screen.plotImage(spr, 17, Common::Point(0, 184));
+		screen.plotImage(spr, 18, Common::Point(193, 184));
+	} else if (_vm->getGameID() == GType_Amazon) {
+		screen.plotImage(spr, 17, Common::Point(0, 176));
+		screen.plotImage(spr, 18, Common::Point(155, 176));
+	} else
+		error("Game not supported");
 
 	screen.restoreScreen();
 	delete spr;


Commit: 7e45ce9096eb86309e22ec0db966621f9d3b830c
    https://github.com/scummvm/scummvm/commit/7e45ce9096eb86309e22ec0db966621f9d3b830c
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-03T10:25:05+01:00

Commit Message:
ACCESS: MM - Make cmdTexSpeak game-dependent

Changed paths:
    engines/access/scripts.cpp



diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 2e22d9a..0188457 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -614,14 +614,18 @@ void Scripts::cmdCharSpeak() {
 void Scripts::cmdTexSpeak() {
 	_vm->_screen->_printOrg = _texsOrg;
 	_vm->_screen->_printStart = _texsOrg;
-	_vm->_screen->_maxChars = 20;
+	_vm->_screen->_maxChars = (_vm->getGameID() == GType_MartianMemorandum) ? 23 : 20;
 
 	byte v;
 	Common::String tmpStr = "";
 	while ((v = _data->readByte()) != 0)
 		tmpStr += (char)v;
 
-	_vm->_bubbleBox->_bubbleDisplStr = Common::String("JASON");
+	if (_vm->getGameID() == GType_MartianMemorandum)
+		_vm->_bubbleBox->_bubbleDisplStr = Common::String("TEX");
+	else
+		_vm->_bubbleBox->_bubbleDisplStr = Common::String("JASON");
+
 	_vm->_bubbleBox->placeBubble1(tmpStr);
 	findNull();
 }


Commit: fa07048bc4be0339b45d650873643f941aee96b2
    https://github.com/scummvm/scummvm/commit/fa07048bc4be0339b45d650873643f941aee96b2
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-04T21:38:37+01:00

Commit Message:
ACCESS: Improve the use of _establishTable as a boolean

Changed paths:
    engines/access/room.cpp
    engines/access/scripts.cpp



diff --git a/engines/access/room.cpp b/engines/access/room.cpp
index f10ba86..fa0c0c4 100644
--- a/engines/access/room.cpp
+++ b/engines/access/room.cpp
@@ -199,8 +199,8 @@ void Room::loadRoomData(const byte *roomData) {
 	_vm->_establishFlag = false;
 	if (roomInfo._estIndex != -1) {
 		_vm->_establishFlag = true;
-		if (_vm->_establishTable[roomInfo._estIndex] != 1) {
-			_vm->_establishTable[roomInfo._estIndex] = 1;
+		if (!_vm->_establishTable[roomInfo._estIndex]) {
+			_vm->_establishTable[roomInfo._estIndex] = true;
 			_vm->establish(0, roomInfo._estIndex);
 		}
 	}
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 0188457..a74cc7b 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -572,7 +572,7 @@ void Scripts::cmdSpecial() {
 	int p2 = _data->readUint16LE();
 
 	if (_specialFunction == 1) {
-		if (_vm->_establishTable[p2] == 1)
+		if (_vm->_establishTable[p2])
 			return;
 
 		_vm->_screen->savePalette();


Commit: 76f681efdfc0c9389ba09d63652847e156a65364
    https://github.com/scummvm/scummvm/commit/76f681efdfc0c9389ba09d63652847e156a65364
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-05T18:15:12+01:00

Commit Message:
ACCESS: Make opcodes dependant to game versions

Changed paths:
    engines/access/access.cpp
    engines/access/access.h
    engines/access/amazon/amazon_scripts.cpp
    engines/access/martian/martian_game.h
    engines/access/scripts.cpp
    engines/access/scripts.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index 14aa68c..dabcd13 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -93,6 +93,10 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 	_vidX = _vidY = 0;
 	_cheatFl = false;
 	_restartFl = false;
+
+	for (int i = 0; i < 7; i++)
+		TRAVEL[i] = 0;
+	STARTTRAVELITEM = STARTTRAVELBOX = 0;
 }
 
 AccessEngine::~AccessEngine() {
diff --git a/engines/access/access.h b/engines/access/access.h
index 8801c1b..de44905 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -206,6 +206,10 @@ public:
 	uint32 _newDate;
 	int _flags[256];
 
+	int TRAVEL[7];
+	int STARTTRAVELITEM;
+	int STARTTRAVELBOX;
+
 	bool _clearSummaryFlag;
 	bool _cheatFl;
 	bool _restartFl;
diff --git a/engines/access/amazon/amazon_scripts.cpp b/engines/access/amazon/amazon_scripts.cpp
index 633188e..d7ca408 100644
--- a/engines/access/amazon/amazon_scripts.cpp
+++ b/engines/access/amazon/amazon_scripts.cpp
@@ -33,6 +33,8 @@ namespace Amazon {
 
 AmazonScripts::AmazonScripts(AccessEngine *vm) : Scripts(vm) {
 	_game = (AmazonEngine *)_vm;
+
+	setOpcodes_v2();
 }
 
 void AmazonScripts::cLoop() {
diff --git a/engines/access/martian/martian_game.h b/engines/access/martian/martian_game.h
index 03f3e0f..155642a 100644
--- a/engines/access/martian/martian_game.h
+++ b/engines/access/martian/martian_game.h
@@ -61,7 +61,6 @@ protected:
 	void displayNote(const Common::String &msg);
 public:
 	MartianEngine(OSystem *syst, const AccessGameDescription *gameDesc);
-
 	virtual ~MartianEngine();
 
 	void doSpecial5(int param1);
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index a74cc7b..62366fd 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -37,12 +37,94 @@ Scripts::Scripts(AccessEngine *vm) : Manager(vm) {
 	_choiceStart = 0;
 	_charsOrg = Common::Point(0, 0);
 	_texsOrg = Common::Point(0, 0);
+	setOpcodes();
 }
 
 Scripts::~Scripts() {
 	freeScriptData();
 }
 
+void Scripts::setOpcodes() {
+	COMMAND_LIST[0] = &Scripts::cmdObject;
+	COMMAND_LIST[1] = &Scripts::cmdEndObject;
+	COMMAND_LIST[2] = &Scripts::cmdJumpLook;
+	COMMAND_LIST[3] = &Scripts::cmdJumpHelp;
+	COMMAND_LIST[4] = &Scripts::cmdJumpGet;
+	COMMAND_LIST[5] = &Scripts::cmdJumpMove;
+	COMMAND_LIST[6] = &Scripts::cmdJumpUse;
+	COMMAND_LIST[7] = &Scripts::cmdJumpTalk;
+	COMMAND_LIST[8] = &Scripts::cmdNull;
+	COMMAND_LIST[9] = &Scripts::cmdPrint;
+	COMMAND_LIST[10] = &Scripts::cmdRetPos;
+	COMMAND_LIST[11] = &Scripts::cmdAnim;
+	COMMAND_LIST[12] = &Scripts::cmdSetFlag;
+	COMMAND_LIST[13] = &Scripts::cmdCheckFlag;
+	COMMAND_LIST[14] = &Scripts::cmdGoto;
+	COMMAND_LIST[15] = &Scripts::cmdAddScore;
+	COMMAND_LIST[16] = &Scripts::cmdSetInventory;
+	COMMAND_LIST[17] = &Scripts::cmdCheckInventory;
+	COMMAND_LIST[18] = &Scripts::cmdSetTex;
+	COMMAND_LIST[19] = &Scripts::cmdNewRoom;
+	COMMAND_LIST[20] = &Scripts::cmdConverse;
+	COMMAND_LIST[21] = &Scripts::cmdCheckFrame;
+	COMMAND_LIST[22] = &Scripts::cmdCheckAnim;
+	COMMAND_LIST[23] = &Scripts::cmdSnd;
+	COMMAND_LIST[24] = &Scripts::cmdRetNeg;
+	COMMAND_LIST[25] = &Scripts::cmdRetPos;
+	COMMAND_LIST[26] = &Scripts::cmdCheckLoc;
+	COMMAND_LIST[27] = &Scripts::cmdSetAnim;
+	COMMAND_LIST[28] = &Scripts::cmdDispInv;
+	COMMAND_LIST[29] = &Scripts::cmdSetAbout;
+	COMMAND_LIST[30] = &Scripts::cmdSetTimer;
+	COMMAND_LIST[31] = &Scripts::cmdCheckTimer;
+	COMMAND_LIST[32] = &Scripts::cmdSetTravel;
+	COMMAND_LIST[33] = &Scripts::cmdJumpGoto;
+	COMMAND_LIST[34] = &Scripts::cmdSetVideo;
+	COMMAND_LIST[35] = &Scripts::cmdPlayVideo;
+	COMMAND_LIST[36] = &Scripts::cmdPlotImage;
+	COMMAND_LIST[37] = &Scripts::cmdSetDisplay;
+	COMMAND_LIST[38] = &Scripts::cmdSetBuffer;
+	COMMAND_LIST[39] = &Scripts::cmdSetScroll;
+	COMMAND_LIST[40] = &Scripts::cmdSaveRect;
+	COMMAND_LIST[41] = &Scripts::cmdVideoEnded;
+	COMMAND_LIST[42] = &Scripts::cmdSetBufVid;
+	COMMAND_LIST[43] = &Scripts::cmdPlayBufVid;
+	COMMAND_LIST[44] = &Scripts::cmdRemoveLast;
+	COMMAND_LIST[45] = &Scripts::cmdDoTravel;
+	COMMAND_LIST[46] = &Scripts::cmdCheckAbout;
+	COMMAND_LIST[47] = &Scripts::cmdSpecial;
+	COMMAND_LIST[48] = &Scripts::cmdSetCycle;
+	COMMAND_LIST[49] = &Scripts::cmdCycle;
+	COMMAND_LIST[50] = &Scripts::cmdCharSpeak;
+	COMMAND_LIST[51] = &Scripts::cmdTexSpeak;
+	COMMAND_LIST[52] = &Scripts::cmdTexChoice;
+	COMMAND_LIST[53] = &Scripts::cmdWait;
+	COMMAND_LIST[54] = &Scripts::cmdSetConPos;
+	COMMAND_LIST[55] = &Scripts::cmdCheckVFrame;
+	COMMAND_LIST[56] = &Scripts::cmdJumpChoice;
+	COMMAND_LIST[57] = &Scripts::cmdReturnChoice;
+	COMMAND_LIST[58] = &Scripts::cmdClearBlock;
+	COMMAND_LIST[59] = &Scripts::cmdLoadSound;
+	COMMAND_LIST[60] = &Scripts::cmdFreeSound;
+	COMMAND_LIST[61] = &Scripts::cmdSetVideoSound;
+	COMMAND_LIST[62] = &Scripts::cmdPlayVideoSound;
+	COMMAND_LIST[63] = &Scripts::cmdPrintWatch;
+	COMMAND_LIST[64] = &Scripts::cmdDispAbout;
+	COMMAND_LIST[65] = &Scripts::cmdPushLocation;
+	COMMAND_LIST[66] = &Scripts::cmdCheckTravel;
+	COMMAND_LIST[67] = &Scripts::cmdBlock;
+	COMMAND_LIST[68] = &Scripts::cmdPlayerOff;
+	COMMAND_LIST[69] = &Scripts::cmdPlayerOn;
+	COMMAND_LIST[70] = &Scripts::cmdDead;
+	COMMAND_LIST[71] = &Scripts::cmdFadeOut;
+	COMMAND_LIST[72] = &Scripts::cmdEndVideo;
+}
+
+void Scripts::setOpcodes_v2() {
+	COMMAND_LIST[15] = &Scripts::cmdSetInventory;
+	COMMAND_LIST[29] = &Scripts::cmdSetTimer();
+}
+
 void Scripts::setScript(Resource *res, bool restartFlag) {
 	_resource = res;
 	_data = res->_stream;
@@ -107,37 +189,7 @@ int Scripts::executeScript() {
 	return _returnCode;
 }
 
-typedef void(Scripts::*ScriptMethodPtr)();
-
 void Scripts::executeCommand(int commandIndex) {
-	static const ScriptMethodPtr COMMAND_LIST[] = {
-		&Scripts::cmdObject, &Scripts::cmdEndObject, &Scripts::cmdJumpLook,
-		&Scripts::cmdJumpHelp, &Scripts::cmdJumpGet, &Scripts::cmdJumpMove,
-		&Scripts::cmdJumpUse, &Scripts::cmdJumpTalk, &Scripts::cmdNull,
-		&Scripts::cmdPrint, &Scripts::cmdRetPos, &Scripts::cmdAnim,
-		&Scripts::cmdSetFlag, &Scripts::cmdCheckFlag, &Scripts::cmdGoto,
-		&Scripts::cmdAddScore, &Scripts::cmdSetInventory, &Scripts::cmdCheckInventory,
-		&Scripts::cmdSetTex, &Scripts::cmdNewRoom, &Scripts::cmdConverse,
-		&Scripts::cmdCheckFrame, &Scripts::cmdCheckAnim, &Scripts::cmdSnd,
-		&Scripts::cmdRetNeg, &Scripts::cmdRetPos, &Scripts::cmdCheckLoc,
-		&Scripts::cmdSetAnim, &Scripts::cmdDispInv, &Scripts::cmdSetAbout,
-		&Scripts::cmdSetTimer, &Scripts::cmdCheckTimer, &Scripts::cmdSetTravel,
-		&Scripts::cmdJumpGoto, &Scripts::cmdSetVideo, &Scripts::cmdPlayVideo,
-		&Scripts::cmdPlotImage, &Scripts::cmdSetDisplay, &Scripts::cmdSetBuffer,
-		&Scripts::cmdSetScroll, &Scripts::cmdSaveRect, &Scripts::cmdVideoEnded,
-		&Scripts::cmdSetBufVid, &Scripts::cmdPlayBufVid, &Scripts::cmdRemoveLast,
-		&Scripts::cmdDoTravel, &Scripts::cmdCheckAbout, &Scripts::cmdSpecial,
-		&Scripts::cmdSetCycle, &Scripts::cmdCycle, &Scripts::cmdCharSpeak,
-		&Scripts::cmdTexSpeak, &Scripts::cmdTexChoice, &Scripts::cmdWait,
-		&Scripts::cmdSetConPos, &Scripts::cmdCheckVFrame, &Scripts::cmdJumpChoice,
-		&Scripts::cmdReturnChoice, &Scripts::cmdClearBlock, &Scripts::cmdLoadSound,
-		&Scripts::cmdFreeSound, &Scripts::cmdSetVideoSound, &Scripts::cmdPlayVideoSound,
-		&Scripts::cmdPrintWatch, &Scripts::cmdDispAbout, &Scripts::cmdPushLocation,
-		&Scripts::cmdCheckTravel, &Scripts::cmdBlock, &Scripts::cmdPlayerOff,
-		&Scripts::cmdPlayerOn, &Scripts::cmdDead, &Scripts::cmdFadeOut,
-		&Scripts::cmdEndVideo
-	};
-
 	(this->*COMMAND_LIST[commandIndex])();
 }
 
@@ -266,11 +318,6 @@ void Scripts::cmdGoto() {
 }
 
 void Scripts::cmdAddScore() {
-	if (!_vm->isDemo()) {
-		cmdSetInventory();
-		return;
-	}
-
 	_data->skip(1);
 }
 
@@ -412,11 +459,6 @@ void Scripts::cmdDispInv() {
 }
 
 void Scripts::cmdSetAbout() {
-	if (!_vm->isDemo()) {
-		cmdSetTimer();
-		return;
-	}
-
 	error("TODO: DEMO - cmdSetAbout");
 }
 
@@ -459,11 +501,14 @@ void Scripts::cmdCheckTimer() {
 }
 
 void Scripts::cmdSetTravel() {
-	if (!_vm->isDemo()) {
+	if ((_vm->getGameID() == GType_Amazon) && !_vm->isDemo()) {
 		cmdJumpGoto();
-		return;
+	} else {
+		int idx = _data->readByte();
+		int dest = _data->readByte();
+		_vm->TRAVEL[idx] = dest;
+		_vm->STARTTRAVELITEM = _vm->STARTTRAVELBOX = 0;
 	}
-	error("TODO: DEMO - cmdSetTravel");
 }
 
 void Scripts::cmdJumpGoto() {
diff --git a/engines/access/scripts.h b/engines/access/scripts.h
index cfadf6d..f61d35f 100644
--- a/engines/access/scripts.h
+++ b/engines/access/scripts.h
@@ -35,6 +35,8 @@ class Scripts;
 #define SCRIPT_START_BYTE 0xE0
 #define ROOM_SCRIPT 2000
 
+typedef void(Scripts::*ScriptMethodPtr)();
+
 class Scripts : public Manager {
 private:
 	Resource *_resource;
@@ -43,6 +45,7 @@ private:
 	void charLoop();
 protected:
 	Common::SeekableReadStream *_data;
+	ScriptMethodPtr COMMAND_LIST[100];
 
 	virtual void executeSpecial(int commandIndex, int param1, int param2) = 0;
 	virtual void executeCommand(int commandIndex);
@@ -143,6 +146,9 @@ public:
 
 	virtual ~Scripts();
 
+	void setOpcodes();
+	void setOpcodes_v2();
+
 	void setScript(Resource *data, bool restartFlag = false);
 
 	void freeScriptData();


Commit: 0f9174fca7c06d157736056a78238f0086298055
    https://github.com/scummvm/scummvm/commit/0f9174fca7c06d157736056a78238f0086298055
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-05T19:36:38+01:00

Commit Message:
ACCESS: MM - Split some more opcodes

Changed paths:
    engines/access/scripts.cpp



diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 62366fd..05c2d93 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -122,7 +122,11 @@ void Scripts::setOpcodes() {
 
 void Scripts::setOpcodes_v2() {
 	COMMAND_LIST[15] = &Scripts::cmdSetInventory;
-	COMMAND_LIST[29] = &Scripts::cmdSetTimer();
+	COMMAND_LIST[29] = &Scripts::cmdSetTimer;
+	COMMAND_LIST[32] = &Scripts::cmdJumpGoto;
+	COMMAND_LIST[40] = &Scripts::cmdVideoEnded;
+	COMMAND_LIST[45] = COMMAND_LIST[46] = &Scripts::cmdSpecial;
+	COMMAND_LIST[63] = COMMAND_LIST[64] = COMMAND_LIST[66] = COMMAND_LIST[67] = &Scripts::cmdPushLocation;
 }
 
 void Scripts::setScript(Resource *res, bool restartFlag) {
@@ -501,14 +505,10 @@ void Scripts::cmdCheckTimer() {
 }
 
 void Scripts::cmdSetTravel() {
-	if ((_vm->getGameID() == GType_Amazon) && !_vm->isDemo()) {
-		cmdJumpGoto();
-	} else {
-		int idx = _data->readByte();
-		int dest = _data->readByte();
-		_vm->TRAVEL[idx] = dest;
-		_vm->STARTTRAVELITEM = _vm->STARTTRAVELBOX = 0;
-	}
+	int idx = _data->readByte();
+	int dest = _data->readByte();
+	_vm->TRAVEL[idx] = dest;
+	_vm->STARTTRAVELITEM = _vm->STARTTRAVELBOX = 0;
 }
 
 void Scripts::cmdJumpGoto() {
@@ -560,10 +560,6 @@ void Scripts::cmdSetScroll() {
 }
 
 void Scripts::cmdSaveRect() {
-	if (!_vm->isDemo()) {
-		cmdVideoEnded();
-		return;
-	}
 	error("TODO: DEMO - cmdSaveRect");
 }
 
@@ -596,18 +592,10 @@ void Scripts::cmdRemoveLast() {
 }
 
 void Scripts::cmdDoTravel() {
-	if (!_vm->isDemo()) {
-		cmdSpecial();
-		return;
-	}
 	error("TODO: DEMO - cmdDoTravel");
 }
 
 void Scripts::cmdCheckAbout() {
-	if (!_vm->isDemo()) {
-		cmdSpecial();
-		return;
-	}
 	error("TODO: DEMO - cmdCheckAbout");
 }
 
@@ -874,18 +862,10 @@ void Scripts::cmdPlayVideoSound() {
 }
 
 void Scripts::cmdPrintWatch() {
-	if (!_vm->isDemo()) {
-		cmdPushLocation();
-		return;
-	}
 	error("TODO: DEMO - cmdPrintWatch");
 }
 
 void Scripts::cmdDispAbout() {
-	if (!_vm->isDemo()) {
-		cmdPushLocation();
-		return;
-	}
 	error("TODO: DEMO - cmdDispAbout");
 }
 
@@ -894,18 +874,10 @@ void Scripts::cmdPushLocation() {
 }
 
 void Scripts::cmdCheckTravel() {
-	if (!_vm->isDemo()) {
-		cmdPushLocation();
-		return;
-	}
 	error("TODO: DEMO - cmdCheckTravel");
 }
 
 void Scripts::cmdBlock() {
-	if (!_vm->isDemo()) {
-		cmdPushLocation();
-		return;
-	}
 	error("TODO: DEMO - cmdBlock");
 }
 


Commit: e1ded539ea428efe811d763b8c025bf09c2559df
    https://github.com/scummvm/scummvm/commit/e1ded539ea428efe811d763b8c025bf09c2559df
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-05T22:43:21+01:00

Commit Message:
ACCESS: MM - Implement some game specific opcodes

Changed paths:
    engines/access/access.cpp
    engines/access/access.h
    engines/access/scripts.cpp
    engines/access/scripts.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index dabcd13..5973f3b 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -97,6 +97,10 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 	for (int i = 0; i < 7; i++)
 		TRAVEL[i] = 0;
 	STARTTRAVELITEM = STARTTRAVELBOX = 0;
+	for (int i = 0; i < 16; i++)
+		ASK[i];
+	_startAboutItem = 0;
+	_vidEnd = false;
 }
 
 AccessEngine::~AccessEngine() {
diff --git a/engines/access/access.h b/engines/access/access.h
index de44905..c853276 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -209,7 +209,9 @@ public:
 	int TRAVEL[7];
 	int STARTTRAVELITEM;
 	int STARTTRAVELBOX;
-
+	int ASK[16];
+	int _startAboutItem;
+	bool _vidEnd;
 	bool _clearSummaryFlag;
 	bool _cheatFl;
 	bool _restartFl;
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 05c2d93..a9f01f1 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -170,6 +170,10 @@ void Scripts::charLoop() {
 	_endFlag = endFlag;
 }
 
+void Scripts::printWatch() {
+	warning("TODO: printWatch");
+}
+
 void Scripts::findNull() {
 	// No implementation required in ScummVM, the strings in the script files are already skipped by the use of readByte()
 }
@@ -463,7 +467,11 @@ void Scripts::cmdDispInv() {
 }
 
 void Scripts::cmdSetAbout() {
-	error("TODO: DEMO - cmdSetAbout");
+	int idx = _data->readByte();
+	int val = _data->readByte();
+	_vm->ASK[idx] = val;
+	_vm->_startAboutBox = 0;
+	_vm->_startAboutItem = 0;
 }
 
 void Scripts::cmdSetTimer() {
@@ -560,7 +568,10 @@ void Scripts::cmdSetScroll() {
 }
 
 void Scripts::cmdSaveRect() {
-	error("TODO: DEMO - cmdSaveRect");
+	if (_vm->_vidEnd)
+		cmdGoto();
+	else
+		_data->skip(2);
 }
 
 void Scripts::cmdVideoEnded() {
@@ -596,7 +607,13 @@ void Scripts::cmdDoTravel() {
 }
 
 void Scripts::cmdCheckAbout() {
-	error("TODO: DEMO - cmdCheckAbout");
+	int idx = _data->readSint16LE();
+	int val = _data->readSint16LE();
+
+	if (_vm->ASK[idx] == val)
+		cmdGoto();
+	else
+		_data->skip(2);
 }
 
 void Scripts::cmdSpecial() {
@@ -862,7 +879,8 @@ void Scripts::cmdPlayVideoSound() {
 }
 
 void Scripts::cmdPrintWatch() {
-	error("TODO: DEMO - cmdPrintWatch");
+	printWatch();
+	findNull();
 }
 
 void Scripts::cmdDispAbout() {
diff --git a/engines/access/scripts.h b/engines/access/scripts.h
index f61d35f..4d074b6 100644
--- a/engines/access/scripts.h
+++ b/engines/access/scripts.h
@@ -43,6 +43,7 @@ private:
 	int _specialFunction;
 
 	void charLoop();
+	void printWatch();
 protected:
 	Common::SeekableReadStream *_data;
 	ScriptMethodPtr COMMAND_LIST[100];


Commit: 64d8d49b88c062eeb581518fea0d58aed9502ae9
    https://github.com/scummvm/scummvm/commit/64d8d49b88c062eeb581518fea0d58aed9502ae9
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-06T00:39:33+01:00

Commit Message:
ACCESS: MM - Format CURSOR data

Changed paths:
    engines/access/martian/martian_resources.cpp



diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index f460800..29d309e 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -41,47 +41,96 @@ const char *const FILENAMES[] = {
 };
 
 const byte MOUSE0[] = {
-	0, 0, 0, 0, 0, 2, 0xF7, 5, 0, 3, 0xF7, 0xF7, 5, 0, 3,
-	0xF7, 0xF7, 5, 0, 4, 0xF7, 0xF7, 0xF7, 5, 0, 4, 0xF7,
-	0xF7, 0xF7, 5, 0, 5, 0xF7, 0xF7, 0xF7, 0xF7, 5, 0, 5,
-	0xF7, 0xF7, 0xF7, 0xF7, 5, 0, 6, 0xF7, 0xF7, 0xF7, 0xF7,
-	0xF7, 5, 0, 6, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 5, 0, 7,
-	0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 5, 0, 6, 0xF7, 0xF7,
-	0xF7, 0xF7, 0xF7, 5, 0, 5, 0xF7, 0xF7, 0xF7, 0xF7, 5,
-	2, 3, 0xF7, 0xF7, 5, 3, 3, 0xF7, 0xF7, 5, 3, 3, 0xF7,
-	0xF7, 5, 4, 2, 0xF7, 5
+	// hotspot x and y, uint16 LE
+	0, 0, 0, 0,
+	// byte 1: number of skipped pixels
+	// byte 2: number of plotted pixels
+	// then, pixels
+	0, 2, 0xF7, 5,
+	0, 3, 0xF7, 0xF7, 5,
+	0, 3, 0xF7, 0xF7, 5,
+	0, 4, 0xF7, 0xF7, 0xF7, 5,
+	0, 4, 0xF7, 0xF7, 0xF7, 5,
+	0, 5, 0xF7, 0xF7, 0xF7, 0xF7, 5,
+	0, 5, 0xF7, 0xF7, 0xF7, 0xF7, 5,
+	0, 6, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 5,
+	0, 6, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 5,
+	0, 7, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 5,
+	0, 6, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 5,
+	0, 5, 0xF7, 0xF7, 0xF7, 0xF7, 5,
+	2, 3, 0xF7, 0xF7, 5,
+	3, 3, 0xF7, 0xF7, 5,
+	3, 3, 0xF7, 0xF7, 5,
+	4, 2, 0xF7, 5
 };
 const byte MOUSE1[] = {
-	7, 0, 7, 0, 6, 1, 0xF7, 4, 5, 0xFF, 0xFF, 0, 0xFF, 0xFF,
-	3, 7, 0xFF, 0, 0, 0, 0, 0, 0xFF, 2, 9, 0xFF, 0, 0, 0,
-	0xF7, 0, 0, 0, 0xFF, 1, 11, 0xFF, 0, 0, 0, 0, 0, 0,
-	0, 0, 0, 0xFF, 1, 11, 0xFF, 0, 0, 0, 0, 0xF7, 0, 0,
-	0, 0, 0xFF, 0, 13, 0xF7, 0, 0, 0xF7, 0, 0xF7, 0, 0xF7,
-	0, 0xF7, 0, 0, 0xF7, 1, 11, 0xFF, 0, 0, 0, 0, 0xF7,
-	0, 0, 0, 0, 0xFF, 1, 11, 0xFF, 0, 0, 0, 0, 0, 0, 0,
-	0, 0, 0xFF, 2, 9, 0xFF, 0, 0, 0, 0xF7, 0, 0, 0, 0xFF,
-	3, 7, 0xFF, 0, 0, 0, 0, 0, 0xFF, 4, 5, 0xFF, 0xFF, 0,
-	0xFF, 0xFF, 6, 1, 0xF7, 0, 0, 0, 0, 0, 0
+	// hotspot x and y, uint16 LE
+	7, 0, 7, 0,
+	// byte 1: number of skipped pixels
+	// byte 2: number of plotted pixels
+	// then, pixels
+	6, 1, 0xF7,
+	4, 5, 0xFF, 0xFF, 0, 0xFF, 0xFF,
+	3, 7, 0xFF, 0, 0, 0, 0, 0, 0xFF,
+	2, 9, 0xFF, 0, 0, 0, 0xF7, 0, 0, 0, 0xFF,
+	1, 11, 0xFF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xFF,
+	1, 11, 0xFF, 0, 0, 0, 0, 0xF7, 0, 0, 0, 0, 0xFF,
+	0, 13, 0xF7, 0, 0, 0xF7, 0, 0xF7, 0, 0xF7, 0, 0xF7, 0, 0, 0xF7,
+	1, 11, 0xFF, 0, 0, 0, 0, 0xF7, 0, 0, 0, 0, 0xFF,
+	1, 11, 0xFF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xFF,
+	2, 9, 0xFF, 0, 0, 0, 0xF7, 0, 0, 0, 0xFF,
+	3, 7, 0xFF, 0, 0, 0, 0, 0, 0xFF,
+	4, 5, 0xFF, 0xFF, 0, 0xFF, 0xFF,
+	6, 1, 0xF7,
+	0, 0,
+	0, 0,
+	0, 0
 };
 const byte MOUSE2[] = {
-	8, 0, 8, 0, 0, 0, 0, 0, 7, 2, 4, 5, 7, 2, 4, 5, 7, 2,
-	4, 5, 7, 2, 4, 5, 7, 2, 4, 5, 2, 12, 4, 4, 4, 4, 4,
-	0, 4, 4, 4, 4, 4, 5, 7, 2, 4, 5, 7, 2, 4, 5, 7, 2, 4,
-	5, 7, 2, 4, 5, 7, 2, 4, 5, 0, 0, 0, 0, 0, 0
+	// hotspot x and y, uint16 LE
+	8, 0, 8, 0,
+	// byte 1: number of skipped pixels
+	// byte 2: number of plotted pixels
+	// then, pixels
+	0, 0,
+	0, 0,
+	7, 2, 4, 5,
+	7, 2, 4, 5,
+	7, 2, 4, 5,
+	7, 2, 4, 5,
+	7, 2, 4, 5,
+	2, 12, 4, 4, 4, 4, 4, 0, 4, 4, 4, 4, 4, 5,
+	7, 2, 4, 5,
+	7, 2, 4, 5,
+	7, 2, 4, 5,
+	7, 2, 4, 5,
+	7, 2, 4, 5,
+	0, 0,
+	0, 0,
+	0, 0
 };
 const byte MOUSE3[] = {
-	0, 0, 0, 0, 0, 11, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
-	0, 12, 6, 7, 7, 7, 7, 7, 7, 7, 7, 6, 6, 5, 0, 12,
-	6, 7, 7, 7, 7, 7, 7, 7, 7, 6, 5, 5, 0, 12, 6, 6, 6,
-	6, 6, 6, 6, 6, 6, 6, 6, 5, 0, 12, 6, 6, 6, 6, 6, 5,
-	6, 6, 6, 6, 6, 5, 0, 12, 6, 6, 6, 6, 5, 0, 0, 6, 6,
-	6, 6, 5, 0, 12, 6, 6, 6, 6, 6, 0, 6, 6, 6, 6, 6, 5,
-	0, 12, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 5, 0, 12,
-	6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 5, 0, 12, 6, 6, 6,
-	6, 6, 5, 6, 6, 6, 6, 6, 5, 0, 12, 6, 6, 6, 6, 6, 5,
-	6, 6, 6, 6, 6, 5, 0, 12, 6, 6, 6, 6, 6, 6, 6, 6, 6,
-	6, 6, 5, 1, 11, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 0,
-	0, 0, 0, 0, 0
+	// hotspot x and y, uint16 LE
+	0, 0, 0, 0,
+	// byte 1: number of skipped pixels
+	// byte 2: number of plotted pixels
+	// then, pixels
+	0, 11, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
+	0, 12, 6, 7, 7, 7, 7, 7, 7, 7, 7, 6, 6, 5,
+	0, 12, 6, 7, 7, 7, 7, 7, 7, 7, 7, 6, 5, 5,
+	0, 12, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 5,
+	0, 12, 6, 6, 6, 6, 6, 5, 6, 6, 6, 6, 6, 5,
+	0, 12, 6, 6, 6, 6, 5, 0, 0, 6, 6, 6, 6, 5,
+	0, 12, 6, 6, 6, 6, 6, 0, 6, 6, 6, 6, 6, 5,
+	0, 12, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 5,
+	0, 12, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 5,
+	0, 12, 6, 6, 6, 6, 6, 5, 6, 6, 6, 6, 6, 5,
+	0, 12, 6, 6, 6, 6, 6, 5, 6, 6, 6, 6, 6, 5,
+	0, 12, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 5,
+	1, 11, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
+	0, 0,
+	0, 0,
+	0, 0
 };
 const byte *const CURSORS[4] = { MOUSE0, MOUSE1, MOUSE2, MOUSE3 };
 


Commit: cc75fb5fe0a5eaef623da48badf28a2d9fa05ed3
    https://github.com/scummvm/scummvm/commit/cc75fb5fe0a5eaef623da48badf28a2d9fa05ed3
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-06T00:40:13+01:00

Commit Message:
ACCESS: MM - Fix TRAVEL array size

Changed paths:
    engines/access/access.cpp
    engines/access/access.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index 5973f3b..996780d 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -94,7 +94,7 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 	_cheatFl = false;
 	_restartFl = false;
 
-	for (int i = 0; i < 7; i++)
+	for (int i = 0; i < 60; i++)
 		TRAVEL[i] = 0;
 	STARTTRAVELITEM = STARTTRAVELBOX = 0;
 	for (int i = 0; i < 16; i++)
diff --git a/engines/access/access.h b/engines/access/access.h
index c853276..e26dce1 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -206,11 +206,12 @@ public:
 	uint32 _newDate;
 	int _flags[256];
 
-	int TRAVEL[7];
+	int TRAVEL[60];
 	int STARTTRAVELITEM;
 	int STARTTRAVELBOX;
 	int ASK[16];
 	int _startAboutItem;
+
 	bool _vidEnd;
 	bool _clearSummaryFlag;
 	bool _cheatFl;


Commit: 7323140847b8c1c47ef9e0f7a825fa667ddf99cc
    https://github.com/scummvm/scummvm/commit/7323140847b8c1c47ef9e0f7a825fa667ddf99cc
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-06T00:41:10+01:00

Commit Message:
ACCESS: MM - Fix cmdSaveRect, implement cmdCheckTravel

Changed paths:
    engines/access/scripts.cpp



diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index a9f01f1..2a70fe3 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -568,10 +568,11 @@ void Scripts::cmdSetScroll() {
 }
 
 void Scripts::cmdSaveRect() {
-	if (_vm->_vidEnd)
-		cmdGoto();
-	else
-		_data->skip(2);
+	int x = _vm->_screen->_lastBoundsX;
+	int y = _vm->_screen->_lastBoundsY;
+	int w = _vm->_screen->_lastBoundsW;
+	int h = _vm->_screen->_lastBoundsH;
+	_vm->_newRects.push_back(Common::Rect(x, y, x + w, x + h));
 }
 
 void Scripts::cmdVideoEnded() {
@@ -892,7 +893,13 @@ void Scripts::cmdPushLocation() {
 }
 
 void Scripts::cmdCheckTravel() {
-	error("TODO: DEMO - cmdCheckTravel");
+	int idx = _data->readSint16LE();
+	int val = _data->readUint16LE();
+
+	if (_vm->TRAVEL[idx] == val)
+		cmdGoto();
+	else
+		_data->skip(2);
 }
 
 void Scripts::cmdBlock() {


Commit: 48ff7ca27606859bf3addbc12730517d58dae3f8
    https://github.com/scummvm/scummvm/commit/48ff7ca27606859bf3addbc12730517d58dae3f8
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-06T07:28:02+01:00

Commit Message:
ACCESS: MM - Fix some variable initialization

Changed paths:
    engines/access/martian/martian_game.cpp
    engines/access/martian/martian_room.cpp



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index 5fe0359..0b0644c 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -73,6 +73,7 @@ void MartianEngine::initVariables() {
 	_events->setNormalCursor(CURSOR_CROSSHAIRS);
 	_mouseMode = 0;
 	_numAnimTimers = 0;
+	TRAVEL[7] = 1;
 }
 
 void MartianEngine::setNoteParams() {
diff --git a/engines/access/martian/martian_room.cpp b/engines/access/martian/martian_room.cpp
index 38361e5..0134d12 100644
--- a/engines/access/martian/martian_room.cpp
+++ b/engines/access/martian/martian_room.cpp
@@ -57,7 +57,7 @@ void MartianRoom::reloadRoom() {
 
 void MartianRoom::reloadRoom1() {
 	_selectCommand = -1;
-	warning("TODO: _word1F968 = -1;");
+	_vm->_boxSelect = false; //-1
 	_vm->_player->_playerOff = false;
 
 	_vm->_screen->forceFadeOut();


Commit: 10e3a4c0bb27d65ab6e427786d0432981704da4c
    https://github.com/scummvm/scummvm/commit/10e3a4c0bb27d65ab6e427786d0432981704da4c
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-06T07:29:39+01:00

Commit Message:
ACCESS: MM - Split Display Inventory in 2 versions

Changed paths:
    engines/access/scripts.cpp
    engines/access/scripts.h



diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 2a70fe3..440ae5e 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -73,7 +73,7 @@ void Scripts::setOpcodes() {
 	COMMAND_LIST[25] = &Scripts::cmdRetPos;
 	COMMAND_LIST[26] = &Scripts::cmdCheckLoc;
 	COMMAND_LIST[27] = &Scripts::cmdSetAnim;
-	COMMAND_LIST[28] = &Scripts::cmdDispInv;
+	COMMAND_LIST[28] = &Scripts::cmdDispInv_v1;
 	COMMAND_LIST[29] = &Scripts::cmdSetAbout;
 	COMMAND_LIST[30] = &Scripts::cmdSetTimer;
 	COMMAND_LIST[31] = &Scripts::cmdCheckTimer;
@@ -122,6 +122,7 @@ void Scripts::setOpcodes() {
 
 void Scripts::setOpcodes_v2() {
 	COMMAND_LIST[15] = &Scripts::cmdSetInventory;
+	COMMAND_LIST[28] = &Scripts::cmdDispInv_v2;
 	COMMAND_LIST[29] = &Scripts::cmdSetTimer;
 	COMMAND_LIST[32] = &Scripts::cmdJumpGoto;
 	COMMAND_LIST[40] = &Scripts::cmdVideoEnded;
@@ -171,7 +172,7 @@ void Scripts::charLoop() {
 }
 
 void Scripts::printWatch() {
-	warning("TODO: printWatch");
+	error("TODO: printWatch");
 }
 
 void Scripts::findNull() {
@@ -462,7 +463,11 @@ void Scripts::cmdSetAnim() {
 		_vm->_animation->setAnimTimer(anim);
 }
 
-void Scripts::cmdDispInv() {
+void Scripts::cmdDispInv_v1() {
+	error("TODO: cmdDisplInv_v1");
+}
+
+void Scripts::cmdDispInv_v2() {
 	_vm->_inventory->newDisplayInv();
 }
 
diff --git a/engines/access/scripts.h b/engines/access/scripts.h
index 4d074b6..abb8e5a 100644
--- a/engines/access/scripts.h
+++ b/engines/access/scripts.h
@@ -87,7 +87,8 @@ protected:
 	void cmdRetNeg();
 	void cmdCheckLoc();
 	void cmdSetAnim();
-	void cmdDispInv();
+	void cmdDispInv_v1();
+	void cmdDispInv_v2();
 	void cmdSetAbout();
 	void cmdSetTimer();
 	void cmdCheckTimer();


Commit: e4f7a899d36ba6c8d51432fb6c7527227a76f53a
    https://github.com/scummvm/scummvm/commit/e4f7a899d36ba6c8d51432fb6c7527227a76f53a
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-07T00:22:25+01:00

Commit Message:
ACCESS: MM - Implement mainAreaClick

Changed paths:
    engines/access/martian/martian_room.cpp



diff --git a/engines/access/martian/martian_room.cpp b/engines/access/martian/martian_room.cpp
index 0134d12..d5b03db 100644
--- a/engines/access/martian/martian_room.cpp
+++ b/engines/access/martian/martian_room.cpp
@@ -115,8 +115,23 @@ void MartianRoom::roomMenu() {
 }
 
 void MartianRoom::mainAreaClick() {
+	Common::Point &mousePos = _vm->_events->_mousePos;
+	Common::Point pt = _vm->_events->calcRawMouse();
+	Screen &screen = *_vm->_screen;
+	Player &player = *_vm->_player;
+
+	if (_selectCommand == -1) {
+		player._moveTo = pt;
+		player._playerMove = true;
+	} else if (mousePos.x >= screen._windowXAdd &&
+		mousePos.x <= (screen._windowXAdd + screen._vWindowBytesWide) &&
+		mousePos.y >= screen._windowYAdd &&
+		mousePos.y <= (screen._windowYAdd + screen._vWindowLinesTall)) {
+			if (checkBoxes1(pt) >= 0) {
+				checkBoxes3();
+			}
+	}
 }
 
 } // End of namespace Martian
-
 } // End of namespace Access


Commit: dfffeef07748c9905c11fcad40b676da4660e487
    https://github.com/scummvm/scummvm/commit/dfffeef07748c9905c11fcad40b676da4660e487
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-07T23:01:46+01:00

Commit Message:
ACCESS: MM - Add Two arrays of strings

Changed paths:
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h



diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index 29d309e..ad269d4 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -807,5 +807,29 @@ const int RMOUSE[10][2] = {
 	{ 155, 185 }, { 188, 216 }, { 219, 260 }, { 263, 293 }, { 295, 214 }
 };
 
+const char *const TRAVDATA[] = {
+	"GALACTIC PICTURES", "TERRAFORM", "WASHROOM", "MR. BIG", "ALEXIS' HOME",
+	"JOHNNY FEDORA", "JUNKYARD IN", "TEX'S OFFICE", "MURDER SCENE", "PLAZA HOTEL",
+	"RESTAURANT", "GIFT SHOP", "LOVE SCENE", "RICK LOGAN", "HUT",
+	"SMUGGLERS BASE", "PYRAMID", "CASINO", "CAS LOBBY", "BAR",
+	"DUCTWORK", "RESTROOM", "OFFICE", "SAFE", "ALLEY",
+	"POWER PLANT", "PLANT OFFICE", "PLANT ROOM", "TEMPLE", "IN TEMPLE",
+	"JANE MANSFIELD'S HOME", "AEROBICS ACADEMY", "DR. LAWRENCE BARKLEY", "COLONISTS CAMP", "IN SLUM",
+	"REMOTE OUTPOST", "WALK", "CAVE", "PRISON", "ORACLE",
+	"JOCQUES SPARROW", "MAC MALDEN", "CHANTAL VARGAS", "GUY CALLABERO", "ROCKWELL BACHE",
+	"FERRIS COLLETTE", "NORA DESMOND ALEXANDER", "LOWELL PERCIVAL", "MICHELE BLOODWORTH", "BRADLEY ERICSON",
+	"COOPER BRADBURY", nullptr
+};
+
+const char *const ASKTBL[] = {
+	"NONE", "MARSHALL ALEXANDER", "TERRAFORM CORP.", "COLLIER STANTON", "ROCKWELL BACHE",
+	"JOCQUES SPARROW", "NORA DESMOND ALEXANDER", "GALACTIC PICTURES", "LAWRENCE BARKLEY", "TMS",
+	"MAC MALDEN", "STANTON EXPEDITION", "LOWELL PERCIVAL", "CHANTAL VARGAS", "RICK LOGAN",
+	"ALEXIS ALEXANDER", "FERRIS COLLETT", "GUY CALLABERO", "ORACLE STONE", "THOMAS DANGERFIELD",
+	"JANE MANSFIELD", "STACY CRAWFORD", "DICK CASTRO", "ROCKY BULLWINKEL", "DEACON HAWKE",
+	"NATHAN BLOODWORTH", "MICHELLE BLOODWORTH", "BRADLEY ERICSON", "COOPER BRADBURY", "MARTIAN MEMORANDUM",
+	"JOHNNY FEDORA", "RHONDA FOXWORTH", "ANGELO ANDRETTI", "TEX MURPHY", "ROBERT BLOODWORTH",
+	"LARRRY HAMMOND", nullptr
+};
 } // End of namespace Martian
 } // End of namespace Access
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index 593681a..fa30b4a 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -53,9 +53,10 @@ extern const int SIDEOFFD[];
 extern const byte CREDIT_DATA[];
 extern const byte ICON_DATA[];
 
-
 extern const int RMOUSE[10][2];
 
+extern const char *const TRAVDATA[];
+extern const char *const ASKTBL[];
 } // End of namespace Martian
 } // End of namespace Access
 


Commit: 69952c5ff585bac6d8125472e400ac52d14c8c55
    https://github.com/scummvm/scummvm/commit/69952c5ff585bac6d8125472e400ac52d14c8c55
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-08T01:53:05+01:00

Commit Message:
ACCESS: MM - Add Death arrays

Changed paths:
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h



diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index ad269d4..72839a2 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -831,5 +831,33 @@ const char *const ASKTBL[] = {
 	"JOHNNY FEDORA", "RHONDA FOXWORTH", "ANGELO ANDRETTI", "TEX MURPHY", "ROBERT BLOODWORTH",
 	"LARRRY HAMMOND", nullptr
 };
+
+const byte DEATH_SCREENS[] = {
+	5, 5, 3, 3, 7, 4, 6, 2, 2, 2, 1, 5, 3, 5, 2, 8, 5, 3, 8, 5
+};
+
+const char *const DEATHMESSAGE[] = {
+	"A VICIOUS THUG PULLS OUT HIS GUN AND AIR CONDITIONS YOUR BRAIN.",
+	"BIG DICK COMES BACK AND ANNOUNCES YOUR TIME IS UP. ONE OF HIS BOYS PROCEEDS TO PART YOUR EYEBROWS.",
+	"ALTHOUGH HIS FIRST SHOT MISSED, THE PUNK FINDS YOU AND TURNS YOU INTO A DOUGHNUT.",
+	"THE CREEP SPOTS YOU. HE TURNS AND FIRES HIS WEAPON. IT BURNS A HOLE A BUZZARD CAN FLY THROUGH.",
+	"OBVIOUSLY RICK LOGAN HAS A FEW TRICK UP HIS SLEEVE. A TREMENDOUS WEIGHT HITS YOUR HEAD. YOU MUMBLE; WATCH OUT FOR THAT TREE...",
+	"SLOWLY SINKING IN THE SLIMY OOZE, YOU THINK OF SEVERAL JELLO WRESTLING MATCHES YOU'VE ATTENDED. BUT NO MORE...",
+	"THE PATH SUDDENLY GIVES WAY AND YOU FEEL MANY STAKES TEAR THROUGH YOUR FLESH. HOW DO YOU LIKE YOUR STAKE",
+	"THE SNAKE SINKS ITS FANGS INTO YOU LEG. THE POISON WORKS QUICKLY. THE SNAKE THEN SWALLOWS YOU WHOLE.",
+	"YOU FADE AWAY, GLOWING LIKE A LIGHTBULB.",
+	"YOU TOUCH THE BUBBLING RADIOACTIVE SELTZER. IT IMMEDIATELY CAUSES VITAL ORGANS TO ELONGATE AND EXPLODE. YOU DIE WITH AN ABSURD AND FOOLISH LOOK ON YOUR FACE.",
+	"THE DOGS PRETTY HUNGRY. IT WON'T TAKE HIM LONG TO FINISH SO SIT BACK AND ENJOY IT.",
+	"ROCKY DOESN'T LIKE BEING FOLLOWED. HE DECIDES TO BEAT YOU. WITHIN AND INCH OF YOUR LIFE. UNFORTUNATELY, HE MISJUDGED THE DISTANCE",
+	"YOU STUMBLE INTO DEADLY LASER FIRE.",
+	"THE OUTPOST AND YOUR BODY PARTS ARE BLOWN TO KINGDOM COME.",
+	"YOU REACH THE TOP, BUT YOUR AIR SOON RUNS OUT LEAVING YOU BREATHLESS.",
+	"YOU DIE IN THE FIERY EXPLOSION.",
+	"YOU FALL HUNDREDS OF FEET TO YOUR DEATH.",
+	"YOU WALK ONTO A PRESSURE SENSITIVE SECURITY PAD. A LASER ZEROS IN AND BLOWS A HOLE THE SIZE OF A SUBARU TIRE THROUGH YOU.",
+	"DANGERFIELD'S EXPERIMENT BACKFIRES. IT RELEASES A DEMON FROM HIS SUBCONSCIOUS WHICH DESTROYS THE ENTIRE PLANET.",
+	"ONCE DANGERFIELD GETS OUT OF HIS CHAMBER, HE PULLS OUT A WEAPON AND LETS YOU HAVE IT."
+};
+
 } // End of namespace Martian
 } // End of namespace Access
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index fa30b4a..a6dc81d 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -57,6 +57,10 @@ extern const int RMOUSE[10][2];
 
 extern const char *const TRAVDATA[];
 extern const char *const ASKTBL[];
+
+extern const byte DEATH_SCREENS[];
+extern const char *const DEATHMESSAGE[];
+
 } // End of namespace Martian
 } // End of namespace Access
 


Commit: 8249de3d44eee83ebd2f638692b53842bda550fe
    https://github.com/scummvm/scummvm/commit/8249de3d44eee83ebd2f638692b53842bda550fe
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-09T08:20:59+01:00

Commit Message:
ACCESS: MM - Make Bubble Box variable, add MM bubble boxes

Changed paths:
    engines/access/access.cpp
    engines/access/access.h
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index 996780d..af3b2cc 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -106,6 +106,10 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 AccessEngine::~AccessEngine() {
 	delete _animation;
 	delete _bubbleBox;
+	delete _helpBox;
+	delete _travelBox;
+	delete _invBox;
+	delete _aboutBox;
 	delete _char;
 	delete _debugger;
 	delete _events;
@@ -151,7 +155,18 @@ void AccessEngine::initialize() {
 
 	// Create sub-objects of the engine
 	_animation = new AnimationManager(this);
-	_bubbleBox = new BubbleBox(this);
+	_bubbleBox = new BubbleBox(this, TYPE_2, 64, 32, 130, 122, 0, 0, 0, 0, "");
+	if (getGameID() == GType_MartianMemorandum) {
+		_helpBox = new BubbleBox(this, TYPE_1, 64, 24, 146, 122, 1, 32, 2, 76, "HELP");
+		_travelBox = new BubbleBox(this, TYPE_1, 64, 32, 194, 122, 1, 24, 2, 74, "TRAVEL");
+		_invBox = new BubbleBox(this, TYPE_1, 64, 32, 146, 122, 1, 32, 2, 76, "INVENTORY");
+		_aboutBox = new BubbleBox(this, TYPE_1, 64, 32, 194, 122, 1, 32, 2, 76, "ASK ABOUT");
+	} else {
+		_helpBox = nullptr;
+		_travelBox = nullptr;
+		_invBox = nullptr;
+		_aboutBox = nullptr;
+	}
 	_char = new CharManager(this);
 	_debugger = Debugger::init(this);
 	_events = new EventsManager(this);
diff --git a/engines/access/access.h b/engines/access/access.h
index e26dce1..3d839f6 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -137,6 +137,10 @@ protected:
 public:
 	AnimationManager *_animation;
 	BubbleBox *_bubbleBox;
+	BubbleBox *_helpBox;
+	BubbleBox *_travelBox;
+	BubbleBox *_invBox;
+	BubbleBox *_aboutBox;
 	CharManager *_char;
 	Debugger *_debugger;
 	EventsManager *_events;
diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index e37a814..7ecba7b 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -26,14 +26,14 @@
 
 namespace Access {
 
-BubbleBox::BubbleBox(AccessEngine *vm) : Manager(vm) {
-	_type = TYPE_2;
-	_bounds = Common::Rect(64, 32, 64 + 130, 32 + 122);
-	_bubbleDisplStr = "";
-	_fieldD = 0;
-	_fieldE = 0;
-	_fieldF = 0;
-	_field10 = 0;
+	BubbleBox::BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w, int h, int val1, int val2, int val3, int val4, Common::String title) : Manager(vm) {
+	_type = type;
+	_bounds = Common::Rect(x, y, x + w, y + h);
+	_bubbleDisplStr = title;
+	_fieldD = val1;
+	_fieldE = val2;
+	_fieldF = val3;
+	_field10 = val4;
 }
 
 void BubbleBox::load(Common::SeekableReadStream *stream) {
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index 0130344..8bfbc40 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -36,7 +36,7 @@ namespace Access {
 
 class AccessEngine;
 
-enum BoxType { TYPE_2 = 2, TYPE_4 = 4 };
+enum BoxType { TYPE_1 = 1, TYPE_2 = 2, TYPE_4 = 4 };
 
 class BubbleBox : public Manager {
 private:
@@ -56,7 +56,7 @@ public:
 
 	Common::Array<Common::Rect> _bubbles;
 public:
-	BubbleBox(AccessEngine *vm);
+	BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w, int h, int val1, int val2, int val3, int val4, Common::String title);
 
 	void load(Common::SeekableReadStream *stream);
 


Commit: ec381ae36439ba151c9b904e1139dba4b2b313c2
    https://github.com/scummvm/scummvm/commit/ec381ae36439ba151c9b904e1139dba4b2b313c2
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-12T00:04:38+01:00

Commit Message:
ACCESS: MM - Start implementing MM dialog box, split cmdConverse in two (WIP)

Changed paths:
    engines/access/access.cpp
    engines/access/access.h
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h
    engines/access/scripts.cpp
    engines/access/scripts.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index af3b2cc..adcb5fa 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -55,8 +55,6 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 	_currentMan = 0;
 	_currentManOld = -1;
 	_converseMode = 0;
-	_startAboutBox = 0;
-	_startTravelBox = 0;
 	_numAnimTimers = 0;
 	_startup = 0;
 	_currentCharFlag = false;
@@ -99,7 +97,7 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 	STARTTRAVELITEM = STARTTRAVELBOX = 0;
 	for (int i = 0; i < 16; i++)
 		ASK[i];
-	_startAboutItem = 0;
+	_startAboutItem = _startAboutBox = 0;
 	_vidEnd = false;
 }
 
diff --git a/engines/access/access.h b/engines/access/access.h
index 3d839f6..94e27e8 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -180,8 +180,6 @@ public:
 	int _playerDataCount;
 	int _currentManOld;
 	int _converseMode;
-	int _startAboutBox;
-	int _startTravelBox;
 	bool _currentCharFlag;
 	bool _boxSelect;
 	int _scale;
@@ -210,11 +208,17 @@ public:
 	uint32 _newDate;
 	int _flags[256];
 
+	// Fields used by MM
+	// TODO: Refactor
 	int TRAVEL[60];
 	int STARTTRAVELITEM;
 	int STARTTRAVELBOX;
 	int ASK[16];
 	int _startAboutItem;
+	int _startAboutBox;
+	int BOXDATASTART;
+	int BOXSELECTY;
+	//
 
 	bool _vidEnd;
 	bool _clearSummaryFlag;
diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index 7ecba7b..ec6a3b1 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -26,7 +26,7 @@
 
 namespace Access {
 
-	BubbleBox::BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w, int h, int val1, int val2, int val3, int val4, Common::String title) : Manager(vm) {
+BubbleBox::BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w, int h, int val1, int val2, int val3, int val4, Common::String title) : Manager(vm) {
 	_type = type;
 	_bounds = Common::Rect(x, y, x + w, y + h);
 	_bubbleDisplStr = title;
@@ -279,4 +279,9 @@ void BubbleBox::doBox(int item, int box) {
 	delete icons;
 }
 
+int BubbleBox::doBox_v1(int item, int box, int &type) {
+	warning("TODO: dobox_v1");
+	return -1;
+}
+
 } // End of namespace Access
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index 8bfbc40..f2ec3a2 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -82,6 +82,9 @@ public:
 	void drawBubble(int index);
 
 	void doBox(int item, int box);
+
+	int doBox_v1(int item, int box, int &type);
+	void getList() { warning("TODO: getList"); } // TODO: Check if implementation is useful
 };
 
 } // End of namespace Access
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 440ae5e..a50509d 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -38,6 +38,9 @@ Scripts::Scripts(AccessEngine *vm) : Manager(vm) {
 	_charsOrg = Common::Point(0, 0);
 	_texsOrg = Common::Point(0, 0);
 	setOpcodes();
+
+	for (int i = 0; i < 60; i++)
+		TMPLPTR[i] = 0;
 }
 
 Scripts::~Scripts() {
@@ -392,8 +395,8 @@ void Scripts::cmdNewRoom() {
 	cmdRetPos();
 }
 
-void Scripts::cmdConverse() {
-	_vm->_conversation = _data->readUint16LE();
+void Scripts::converse1(int val) {
+	_vm->_conversation = val;
 	_vm->_room->clearRoom();
 	_vm->freeChar();
 	_vm->_char->loadChar(_vm->_conversation);
@@ -409,6 +412,11 @@ void Scripts::cmdConverse() {
 	}
 }
 
+void Scripts::cmdConverse() {
+	int val = _data->readUint16LE();
+	converse1(val);
+}
+
 void Scripts::cmdCheckFrame() {
 	int id = _data->readUint16LE();
 	Animation *anim = _vm->_animation->findAnimation(id);
@@ -475,8 +483,7 @@ void Scripts::cmdSetAbout() {
 	int idx = _data->readByte();
 	int val = _data->readByte();
 	_vm->ASK[idx] = val;
-	_vm->_startAboutBox = 0;
-	_vm->_startAboutItem = 0;
+	_vm->_startAboutBox = _vm->_startAboutItem = 0;
 }
 
 void Scripts::cmdSetTimer() {
@@ -609,7 +616,41 @@ void Scripts::cmdRemoveLast() {
 }
 
 void Scripts::cmdDoTravel() {
-	error("TODO: DEMO - cmdDoTravel");
+	while (true) {
+		_vm->_travelBox->getList();
+		int type = 0;
+		int boxX = _vm->_travelBox->doBox_v1(_vm->STARTTRAVELITEM, _vm->STARTTRAVELBOX, type);
+		_vm->STARTTRAVELITEM = _vm->BOXDATASTART;
+		_vm->STARTTRAVELBOX = _vm->BOXSELECTY;
+
+		if (boxX == -1)
+			type = 2;
+
+		if (type != 2) {
+			int idx = TMPLPTR[boxX];
+			warning("TODO: if (_byte1EEB5[idx] != _byte26CB5) {");
+			// _vm->_bubbleBox->_bubbleTitle = "TRAVEL";
+			// _vm->_scripts->printString("YOU CAN'T GET THERE FROM HERE.");
+			// continue;
+			// }
+			if (_vm->_player->_roomNumber != idx) {
+				if (Martian::TRAVEL_POS[idx][0] == -1) {
+					_vm->_player->_roomNumber = idx;
+					_vm->_room->_conFlag = true;
+					_vm->_scripts->converse1(Martian::TRAVEL_POS[idx][1]);
+					return;
+				}
+				_vm->_player->_rawPlayer = Common::Point(Martian::TRAVEL_POS[idx][0], Martian::TRAVEL_POS[idx][1]);
+				cmdRetPos();
+				return;
+			}
+		}
+
+		if (_vm->_player->_roomNumber == -1)
+			continue;
+
+		return;
+	}
 }
 
 void Scripts::cmdCheckAbout() {
diff --git a/engines/access/scripts.h b/engines/access/scripts.h
index abb8e5a..d9715af 100644
--- a/engines/access/scripts.h
+++ b/engines/access/scripts.h
@@ -44,6 +44,8 @@ private:
 
 	void charLoop();
 	void printWatch();
+	void converse1(int val);
+
 protected:
 	Common::SeekableReadStream *_data;
 	ScriptMethodPtr COMMAND_LIST[100];
@@ -143,6 +145,8 @@ public:
 	int _choice;
 	int32 _choiceStart;
 	Common::Point _charsOrg, _texsOrg;
+
+	int TMPLPTR[60];
 public:
 	Scripts(AccessEngine *vm);
 


Commit: eacc0e085a8bac06acc430b262c4be96322b6aec
    https://github.com/scummvm/scummvm/commit/eacc0e085a8bac06acc430b262c4be96322b6aec
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-12T00:23:28+01:00

Commit Message:
ACCESS: MM - Add resource _byte1EEB5[]

Changed paths:
    engines/access/access.cpp
    engines/access/access.h
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h
    engines/access/scripts.cpp



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index adcb5fa..1daba74 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -98,6 +98,7 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 	for (int i = 0; i < 16; i++)
 		ASK[i];
 	_startAboutItem = _startAboutBox = 0;
+	_byte26CB5 = 0;
 	_vidEnd = false;
 }
 
diff --git a/engines/access/access.h b/engines/access/access.h
index 94e27e8..7882833 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -218,6 +218,7 @@ public:
 	int _startAboutBox;
 	int BOXDATASTART;
 	int BOXSELECTY;
+	byte _byte26CB5;
 	//
 
 	bool _vidEnd;
diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index 72839a2..c976fe2 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -859,5 +859,14 @@ const char *const DEATHMESSAGE[] = {
 	"ONCE DANGERFIELD GETS OUT OF HIS CHAMBER, HE PULLS OUT A WEAPON AND LETS YOU HAVE IT."
 };
 
+const byte _byte1EEB5[] = {
+	0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+	0, 0, 0, 0, 0, 0, 0, 1, 1, 1,
+	1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+	1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+	0, 0, 0, 0, 0, 1, 0, 1, 1, 1,
+	1
+};
+
 } // End of namespace Martian
 } // End of namespace Access
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index a6dc81d..e758a89 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -61,6 +61,8 @@ extern const char *const ASKTBL[];
 extern const byte DEATH_SCREENS[];
 extern const char *const DEATHMESSAGE[];
 
+extern const byte _byte1EEB5[];
+
 } // End of namespace Martian
 } // End of namespace Access
 
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index a50509d..0daa1b9 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -628,11 +628,11 @@ void Scripts::cmdDoTravel() {
 
 		if (type != 2) {
 			int idx = TMPLPTR[boxX];
-			warning("TODO: if (_byte1EEB5[idx] != _byte26CB5) {");
-			// _vm->_bubbleBox->_bubbleTitle = "TRAVEL";
-			// _vm->_scripts->printString("YOU CAN'T GET THERE FROM HERE.");
-			// continue;
-			// }
+			if (Martian::_byte1EEB5[idx] != _vm->_byte26CB5) {
+				_vm->_bubbleBox->_bubbleTitle = "TRAVEL";
+				_vm->_scripts->printString("YOU CAN'T GET THERE FROM HERE.");
+				continue;
+			}
 			if (_vm->_player->_roomNumber != idx) {
 				if (Martian::TRAVEL_POS[idx][0] == -1) {
 					_vm->_player->_roomNumber = idx;


Commit: 6a288bc4761eb527865ade714af12143957ddf73
    https://github.com/scummvm/scummvm/commit/6a288bc4761eb527865ade714af12143957ddf73
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-13T00:46:45+01:00

Commit Message:
ACCESS: MM - Work some more on doBox_v1

Changed paths:
    engines/access/access.cpp
    engines/access/access.h
    engines/access/asurface.cpp
    engines/access/asurface.h
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h
    engines/access/screen.cpp
    engines/access/screen.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index 1daba74..944f921 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -99,6 +99,8 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 		ASK[i];
 	_startAboutItem = _startAboutBox = 0;
 	_byte26CB5 = 0;
+	BCNT = 0;
+
 	_vidEnd = false;
 }
 
diff --git a/engines/access/access.h b/engines/access/access.h
index 7882833..0080673 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -219,6 +219,7 @@ public:
 	int BOXDATASTART;
 	int BOXSELECTY;
 	byte _byte26CB5;
+	int BCNT;
 	//
 
 	bool _vidEnd;
diff --git a/engines/access/asurface.cpp b/engines/access/asurface.cpp
index 793e6e9..1417b0e 100644
--- a/engines/access/asurface.cpp
+++ b/engines/access/asurface.cpp
@@ -316,6 +316,17 @@ void ASurface::drawRect() {
 	Graphics::Surface::fillRect(Common::Rect(_orgX1, _orgY1, _orgX2, _orgY2), _lColor);
 }
 
+void ASurface::drawLine(int x1, int y1, int x2, int y2, int col) {
+	Graphics::Surface::drawLine(x1, y1, x2, y2, col);
+}
+
+void ASurface::drawBox() {
+	Graphics::Surface::drawLine(_orgX1, _orgY1, _orgX2, _orgY1, _lColor);
+	Graphics::Surface::drawLine(_orgX1, _orgY2, _orgX2, _orgY2, _lColor);
+	Graphics::Surface::drawLine(_orgX2, _orgY1, _orgX2, _orgY1, _lColor);
+	Graphics::Surface::drawLine(_orgX2, _orgY2, _orgX2, _orgY2, _lColor);
+}
+
 void ASurface::flipHorizontal(ASurface &dest) {
 	dest.create(this->w, this->h);
 	for (int y = 0; y < h; ++y) {
diff --git a/engines/access/asurface.h b/engines/access/asurface.h
index 763e3e6..3b7104c 100644
--- a/engines/access/asurface.h
+++ b/engines/access/asurface.h
@@ -95,6 +95,10 @@ public:
 
 	virtual void drawRect();
 
+	virtual void drawLine(int x1, int y1, int x2, int y2, int col);
+
+	virtual void drawBox();
+
 	virtual void transCopyFrom(ASurface *src, const Common::Point &destPos);
 
 	virtual void transCopyFrom(ASurface *src, const Common::Rect &bounds);
diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index ec6a3b1..8ac3adb 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -34,6 +34,10 @@ BubbleBox::BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w
 	_fieldE = val2;
 	_fieldF = val3;
 	_field10 = val4;
+	BOXSTARTX = BOXSTARTY = 0;
+	BICONSTARTX = 0;
+	BOXENDY = 0;
+	BOXPSTARTX = BOXPSTARTY = 0;
 }
 
 void BubbleBox::load(Common::SeekableReadStream *stream) {
@@ -280,7 +284,125 @@ void BubbleBox::doBox(int item, int box) {
 }
 
 int BubbleBox::doBox_v1(int item, int box, int &type) {
-	warning("TODO: dobox_v1");
+	FontManager &fonts = _vm->_fonts;
+
+	_startItem = item;
+	_startBox = box;
+
+	// Save state information
+	_vm->_screen->saveScreen();
+	_vm->_screen->setDisplayScan();
+
+	fonts._charFor._hi = 0xff;
+	fonts._charSet._lo = 1;
+	fonts._charSet._hi = 0;
+
+	_vm->_destIn = _vm->_screen;	// TODO: Redundant
+
+	if (_type != TYPE_2) {
+		Common::Rect r = _bounds;
+		r.left -= 2;
+		_vm->_screen->saveBlock(r);
+	}
+
+	// Set the up boundaries and color to use for the box background
+	_vm->_screen->_orgX1 = _bounds.left - 2;
+	_vm->_screen->_orgY1 = _bounds.top;
+	_vm->_screen->_orgX2 = _bounds.right - 2;
+	_vm->_screen->_orgY2 = _bounds.bottom;
+	_vm->_screen->_lColor = 0xFB;
+
+	// Draw a background for the entire area
+	_vm->_screen->drawRect();
+
+	// Draw the inner box;
+	++_vm->_screen->_orgX1;
+	++_vm->_screen->_orgY1;
+	--_vm->_screen->_orgX2;
+	--_vm->_screen->_orgY2;
+	_vm->_screen->_lColor = 0xF9;
+	
+	// Draw the inner border
+	_vm->_screen->drawBox();
+
+	// Get icons data
+	Resource *iconData = _vm->_files->loadFile("ICONS.LZ");
+	SpriteResource *icons = new SpriteResource(_vm, iconData);
+	delete iconData;
+
+	// Draw upper border
+	_vm->BCNT = (_vm->_screen->_orgX2 - _vm->_screen->_orgX1) >> 4;
+	int oldX = _vm->_screen->_orgX1;
+	for ( ;_vm->BCNT > 0; --_vm->BCNT) {
+		_vm->_screen->plotImage(icons, 16, Common::Point(_vm->_screen->_orgX1, _vm->_screen->_orgY1));
+		_vm->_screen->_orgX1 += 16;
+	}
+
+	_vm->_screen->_orgX1 = oldX;
+	int oldY = _vm->_screen->_orgY2;
+	_vm->_screen->_orgY2 = _vm->_screen->_orgY1 + 8;
+	_vm->_screen->_lColor = 0xF9;
+
+	BOXSTARTY = _vm->_screen->_orgY2 + 1;
+	_vm->_screen->_orgY2 = oldY;
+
+	if (_type != TYPE_2) {
+		oldY = _vm->_screen->_orgY1;
+		--_vm->_screen->_orgY2;
+		_vm->_screen->_orgY2 -= 8;
+		if (_type == TYPE_3)
+			_vm->_screen->_orgY2 -= 8;
+		_vm->_screen->drawRect();
+
+		int tmpX = BICONSTARTX = _vm->_screen->_orgX1;
+		BOXSTARTX = tmpX + 1;
+		int tmpY = BOXENDY = _vm->_screen->_orgY1;
+
+		if (_type == TYPE_3)
+			BOXSTARTY = tmpY - 7;
+		else
+			BOXSTARTY = tmpY + 1;
+
+		if (_type == TYPE_3)
+			warning("TODO: Implement more of TYPE_3");
+
+		_vm->_screen->_orgY1 = oldY;
+	}
+
+	if ((_type == TYPE_0) || (_type == TYPE_3))
+		warning("TODO: Implement more of TYPE_0 or TYPE_3");
+
+	int len = _bubbleDisplStr.size();
+	int ax = _bounds.top >> 3;
+	ax -= len;
+	ax /= 2;
+	int cx = _bounds.left >> 3;
+	BOXPSTARTX = cx;
+	ax += cx << 16;
+
+	cx = _bounds.right >> 3;
+	int bp = _bounds.right - (cx << 3) + 1;
+	if (bp == 8) {
+		++cx;
+		bp = 0;
+	}
+
+	_rowOff = bp;
+	BOXPSTARTY = cx;
+	ax += cx;
+
+	_vm->_fonts._charFor._lo = -1;
+	_vm->_events->setCursor(CURSOR_ARROW);
+
+	_vm->_fonts._font1.drawString(_vm->_screen, _bubbleDisplStr, _vm->_screen->_printOrg);
+
+	if (_type == TYPE_2) {
+		_vm->_events->showCursor();
+		warning("TODO: pop values");
+		_vm->_screen->restoreScreen();
+	}
+
+	warning("TODO: more dobox_v1");
 	return -1;
 }
 
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index f2ec3a2..36826db 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -36,13 +36,19 @@ namespace Access {
 
 class AccessEngine;
 
-enum BoxType { TYPE_1 = 1, TYPE_2 = 2, TYPE_4 = 4 };
+enum BoxType { TYPE_0 = 0, TYPE_1 = 1, TYPE_2 = 2, TYPE_3 = 3, TYPE_4 = 4 };
 
 class BubbleBox : public Manager {
 private:
 	int _startItem, _startBox;
 	int _charCol, _rowOff;
 	Common::Point _fileStart;
+	int BOXSTARTX;
+	int BOXSTARTY;
+	int BOXENDY;
+	int BICONSTARTX;
+	int BOXPSTARTX;
+	int BOXPSTARTY;
 public:
 	BoxType _type;
 	Common::Rect _bounds;
diff --git a/engines/access/screen.cpp b/engines/access/screen.cpp
index b7a2d3d..2b535b6 100644
--- a/engines/access/screen.cpp
+++ b/engines/access/screen.cpp
@@ -276,6 +276,11 @@ void Screen::drawRect() {
 	ASurface::drawRect();
 }
 
+void Screen::drawBox() {
+	addDirtyRect(Common::Rect(_orgX1, _orgY1, _orgX2, _orgY2));
+	ASurface::drawBox();
+}
+
 void Screen::transCopyFrom(ASurface *src, const Common::Point &destPos) {
 	addDirtyRect(Common::Rect(destPos.x, destPos.y, destPos.x + src->w, destPos.y + src->h));
 	ASurface::transCopyFrom(src, destPos);
diff --git a/engines/access/screen.h b/engines/access/screen.h
index a3b5585..a5431bc 100644
--- a/engines/access/screen.h
+++ b/engines/access/screen.h
@@ -92,6 +92,8 @@ public:
 
 	virtual void drawRect();
 
+	virtual void drawBox();
+
 	virtual void transCopyFrom(ASurface *src, const Common::Point &destPos);
 
 	virtual void transCopyFrom(ASurface *src, const Common::Rect &bounds);


Commit: 93e8b47e13ba2a4ffda11707ede5a8d3bec052a8
    https://github.com/scummvm/scummvm/commit/93e8b47e13ba2a4ffda11707ede5a8d3bec052a8
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-13T21:52:40+01:00

Commit Message:
ACCESS: MM - Some more work on BubbleBox class

Changed paths:
    engines/access/access.cpp
    engines/access/access.h
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index 944f921..acef375 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -100,6 +100,12 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 	_startAboutItem = _startAboutBox = 0;
 	_byte26CB5 = 0;
 	BCNT = 0;
+	BOXDATASTART = BOXDATAEND = 0;
+	BOXSELECTY = 0;
+	BOXSELECTYOLD = -1;
+	NUMBLINES = 0;
+	_word234F3 = _word234F7 = _word234F5 = _word234F9 = 0;
+	_word234FB = _word234FF = _word234FD = _word23501 = 0;
 
 	_vidEnd = false;
 }
diff --git a/engines/access/access.h b/engines/access/access.h
index 0080673..5db2aea 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -217,9 +217,14 @@ public:
 	int _startAboutItem;
 	int _startAboutBox;
 	int BOXDATASTART;
+	int BOXDATAEND;
 	int BOXSELECTY;
+	int BOXSELECTYOLD;
+	int NUMBLINES;
 	byte _byte26CB5;
 	int BCNT;
+	int _word234F3, _word234F7, _word234F5, _word234F9;
+	int _word234FB, _word234FF, _word234FD, _word23501;
 	//
 
 	bool _vidEnd;
diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index 8ac3adb..6b95d0e 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -30,12 +30,13 @@ BubbleBox::BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w
 	_type = type;
 	_bounds = Common::Rect(x, y, x + w, y + h);
 	_bubbleDisplStr = title;
-	_fieldD = val1;
-	_fieldE = val2;
-	_fieldF = val3;
-	_field10 = val4;
+	_btnId1 = val1;
+	_btnX1 = val2;
+	_btnId2 = val3;
+	_btnX2 = val4;
+	_btnId3 = _btnX3 = 0; // Unused in MM and Amazon?
 	BOXSTARTX = BOXSTARTY = 0;
-	BICONSTARTX = 0;
+	BICONSTARTX = BICONSTARTY = 0;
 	BOXENDY = 0;
 	BOXPSTARTX = BOXPSTARTY = 0;
 }
@@ -283,6 +284,14 @@ void BubbleBox::doBox(int item, int box) {
 	delete icons;
 }
 
+void BubbleBox::displayBoxData() {
+	warning("TODO displayBoxData");
+}
+
+void BubbleBox::drawSelectBox() {
+	warning("TODO drawSelectBox");
+}
+
 int BubbleBox::doBox_v1(int item, int box, int &type) {
 	FontManager &fonts = _vm->_fonts;
 
@@ -349,9 +358,9 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 	if (_type != TYPE_2) {
 		oldY = _vm->_screen->_orgY1;
 		--_vm->_screen->_orgY2;
-		_vm->_screen->_orgY2 -= 8;
+		_vm->_screen->_orgY1 = _vm->_screen->_orgY2 - 8;
 		if (_type == TYPE_3)
-			_vm->_screen->_orgY2 -= 8;
+			_vm->_screen->_orgY1 -= 8;
 		_vm->_screen->drawRect();
 
 		int tmpX = BICONSTARTX = _vm->_screen->_orgX1;
@@ -359,9 +368,9 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 		int tmpY = BOXENDY = _vm->_screen->_orgY1;
 
 		if (_type == TYPE_3)
-			BOXSTARTY = tmpY - 7;
+			BICONSTARTY = tmpY - 7;
 		else
-			BOXSTARTY = tmpY + 1;
+			BICONSTARTY = tmpY + 1;
 
 		if (_type == TYPE_3)
 			warning("TODO: Implement more of TYPE_3");
@@ -402,6 +411,99 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 		_vm->_screen->restoreScreen();
 	}
 
+	_vm->_destIn = _vm->_screen;
+
+	// Draw buttons
+	int ICON1T = 0;
+	int ICON1X = 0;
+	int ICON1Y = 0;
+	if (_btnId1) {
+		ICON1T = _btnId1;
+		ICON1X = BICONSTARTX + _btnX1;
+		ICON1Y = BICONSTARTY;
+		_vm->_screen->plotImage(icons, ICON1T + 10, Common::Point(ICON1X, ICON1Y));
+
+		int ICON2T = 0;
+		int ICON2X = 0;
+		int ICON2Y = 0;
+		if (_btnId2) {
+			ICON2T = _btnId2;
+			ICON2X = BICONSTARTX + _btnX2;
+			ICON2Y = BICONSTARTY;
+			_vm->_screen->plotImage(icons, ICON2T + 10, Common::Point(ICON2X, ICON2Y));
+
+			int ICON3T = 0;
+			int ICON3X = 0;
+			int ICON3Y = 0;
+			if (_btnId3) {
+				ICON3T = _btnId3;
+				ICON3X = BICONSTARTX + _btnX3;
+				ICON3Y = BICONSTARTY;
+				_vm->_screen->plotImage(icons, ICON3T + 10, Common::Point(ICON3X, ICON3Y));
+			}
+		}
+	}
+	
+	_vm->_screen->restoreScreen();
+	_vm->BOXDATASTART = _startItem;
+	_vm->BOXSELECTYOLD = -1;
+	_vm->BOXSELECTY = _startBox;
+
+	_vm->NUMBLINES = (_bounds.bottom >> 3) - 2;
+	if (_type == TYPE_3)
+		--_vm->NUMBLINES;
+
+	_vm->_events->showCursor();
+	displayBoxData();
+	drawSelectBox();
+
+	while (true) {
+		_vm->_events->pollEvents();
+		if (_vm->_events->_leftButton)
+			continue;
+
+		if ((_type != TYPE_1) && (_vm->_timers[2]._flag == 0)) {
+			++_vm->_timers[2]._flag;
+			if ((_vm->_events->_mousePos.x >= _vm->_word234F3) && (_vm->_events->_mousePos.x <= _vm->_word234F7)
+			&& (_vm->_events->_mousePos.y >= _vm->_word234F5) && (_vm->_events->_mousePos.y < _vm->_word234F9)) {
+				if (_vm->BCNT) {
+					if (_vm->BOXSELECTY != 0) {
+						--_vm->BOXSELECTY;
+						drawSelectBox();
+					} else if (_vm->BOXDATASTART != 0) {
+						--_vm->BOXDATASTART;
+						displayBoxData();
+						drawSelectBox();
+					}
+				}
+				continue;
+			} else if ((_vm->_events->_mousePos.x >= _vm->_word234FB) && (_vm->_events->_mousePos.x <= _vm->_word234FF)
+			&& (_vm->_events->_mousePos.y >= _vm->_word234FD) && (_vm->_events->_mousePos.y < _vm->_word23501)) {
+				if (_vm->BCNT) {
+					if (_vm->BCNT == _vm->NUMBLINES) {
+						if (_vm->BCNT != _vm->BOXSELECTY + 1) {
+							++_vm->BOXSELECTY;
+							drawSelectBox();
+						} else if (_vm->BOXDATAEND == 0) {
+							++_vm->BOXDATASTART;
+							displayBoxData();
+							drawSelectBox();
+						}
+					} else if (_vm->BCNT != _vm->BOXSELECTY + 1) {
+						++_vm->BOXSELECTY;
+						drawSelectBox();
+					}
+				}
+				continue;
+			}
+		}
+		warning("TODO Case 1");
+
+		displayBoxData();
+		drawSelectBox();
+	}
+
+
 	warning("TODO: more dobox_v1");
 	return -1;
 }
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index 36826db..4aa9e26 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -43,22 +43,26 @@ private:
 	int _startItem, _startBox;
 	int _charCol, _rowOff;
 	Common::Point _fileStart;
-	int BOXSTARTX;
-	int BOXSTARTY;
+	int BOXSTARTX, BOXSTARTY;
 	int BOXENDY;
-	int BICONSTARTX;
-	int BOXPSTARTX;
-	int BOXPSTARTY;
+	int BICONSTARTX, BICONSTARTY;
+	int BOXPSTARTX, BOXPSTARTY;
+
+	void displayBoxData();
+	void drawSelectBox();
+
 public:
 	BoxType _type;
 	Common::Rect _bounds;
 	Common::StringArray _nameIndex;
 	Common::String _bubbleTitle;
 	Common::String _bubbleDisplStr;
-	int _fieldD;
-	int _fieldE;
-	int _fieldF;
-	int _field10;
+	int _btnId1;
+	int _btnX1;
+	int _btnId2;
+	int _btnX2;
+	int _btnId3;
+	int _btnX3;
 
 	Common::Array<Common::Rect> _bubbles;
 public:


Commit: 3a57f208165c849bd8f68eacd1eaad818af5f75e
    https://github.com/scummvm/scummvm/commit/3a57f208165c849bd8f68eacd1eaad818af5f75e
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-14T23:44:24+01:00

Commit Message:
ACCESS: MM - Implement displayBoxData

Changed paths:
    engines/access/access.cpp
    engines/access/access.h
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index acef375..fc01373 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -106,6 +106,7 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 	NUMBLINES = 0;
 	_word234F3 = _word234F7 = _word234F5 = _word234F9 = 0;
 	_word234FB = _word234FF = _word234FD = _word23501 = 0;
+	TEMPLIST = nullptr;
 
 	_vidEnd = false;
 }
@@ -162,12 +163,12 @@ void AccessEngine::initialize() {
 
 	// Create sub-objects of the engine
 	_animation = new AnimationManager(this);
-	_bubbleBox = new BubbleBox(this, TYPE_2, 64, 32, 130, 122, 0, 0, 0, 0, "");
+	_bubbleBox = new BubbleBox(this, TYPE_2, 64, 32, 130, 122, 0, 0, 0, 0, "", nullptr);
 	if (getGameID() == GType_MartianMemorandum) {
-		_helpBox = new BubbleBox(this, TYPE_1, 64, 24, 146, 122, 1, 32, 2, 76, "HELP");
-		_travelBox = new BubbleBox(this, TYPE_1, 64, 32, 194, 122, 1, 24, 2, 74, "TRAVEL");
-		_invBox = new BubbleBox(this, TYPE_1, 64, 32, 146, 122, 1, 32, 2, 76, "INVENTORY");
-		_aboutBox = new BubbleBox(this, TYPE_1, 64, 32, 194, 122, 1, 32, 2, 76, "ASK ABOUT");
+		_helpBox = new BubbleBox(this, TYPE_1, 64, 24, 146, 122, 1, 32, 2, 76, "HELP", TEMPLIST);
+		_travelBox = new BubbleBox(this, TYPE_1, 64, 32, 194, 122, 1, 24, 2, 74, "TRAVEL", TEMPLIST);
+		_invBox = new BubbleBox(this, TYPE_1, 64, 32, 146, 122, 1, 32, 2, 76, "INVENTORY", TEMPLIST);
+		_aboutBox = new BubbleBox(this, TYPE_1, 64, 32, 194, 122, 1, 32, 2, 76, "ASK ABOUT", TEMPLIST);
 	} else {
 		_helpBox = nullptr;
 		_travelBox = nullptr;
diff --git a/engines/access/access.h b/engines/access/access.h
index 5db2aea..d60a62f 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -225,6 +225,7 @@ public:
 	int BCNT;
 	int _word234F3, _word234F7, _word234F5, _word234F9;
 	int _word234FB, _word234FF, _word234FD, _word23501;
+	byte *TEMPLIST;
 	//
 
 	bool _vidEnd;
diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index 6b95d0e..19b9c1f 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -26,7 +26,7 @@
 
 namespace Access {
 
-BubbleBox::BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w, int h, int val1, int val2, int val3, int val4, Common::String title) : Manager(vm) {
+BubbleBox::BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w, int h, int val1, int val2, int val3, int val4, Common::String title, byte *tmpList) : Manager(vm) {
 	_type = type;
 	_bounds = Common::Rect(x, y, x + w, y + h);
 	_bubbleDisplStr = title;
@@ -37,8 +37,10 @@ BubbleBox::BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w
 	_btnId3 = _btnX3 = 0; // Unused in MM and Amazon?
 	BOXSTARTX = BOXSTARTY = 0;
 	BICONSTARTX = BICONSTARTY = 0;
-	BOXENDY = 0;
+	BOXENDX = BOXENDY = 0;
 	BOXPSTARTX = BOXPSTARTY = 0;
+	// Unused in AGoE
+	_tempListPtr = tmpList;
 }
 
 void BubbleBox::load(Common::SeekableReadStream *stream) {
@@ -285,7 +287,64 @@ void BubbleBox::doBox(int item, int box) {
 }
 
 void BubbleBox::displayBoxData() {
-	warning("TODO displayBoxData");
+	_vm->BOXDATAEND = 0;
+	_rowOff = 2;
+	_vm->_fonts._charSet._lo = 7;  // 0xF7
+	_vm->_fonts._charSet._hi = 15;
+	_vm->_fonts._charFor._lo = 15; // 0xFF
+	_vm->_fonts._charFor._hi = 15;
+
+	if (!_tempListPtr)
+		return;
+
+	int idx = 0;
+	if ((_type == TYPE_1) || (_type == TYPE_3)) {
+		_vm->BCNT = 0;
+
+		if (_tempListPtr[idx] == -1) {
+			_vm->BOXDATAEND = 1;
+			return;
+		}
+
+		_vm->_events->hideCursor();
+
+		_vm->_screen->_orgX1 = BOXSTARTX;
+		_vm->_screen->_orgX2 = BOXENDX;
+		_vm->_screen->_orgY1 = BOXSTARTY;
+		_vm->_screen->_orgY2 = BOXENDY;
+		_vm->_screen->_lColor = 0xFA;
+		_vm->_screen->drawRect();
+		_vm->_events->showCursor();
+	}
+	
+	_vm->_events->hideCursor();
+	int oldPStartY = BOXPSTARTY;
+	++BOXPSTARTY;
+
+	for (int i = 0; i < _vm->BOXDATASTART; i++, idx++) {
+		while (_tempListPtr[idx] != 0)
+			++idx;
+	}
+
+	while (true) {
+		warning("TODO: SETCURSOR");
+		warning("TODO: PRINTSTR");
+		++idx;
+		++BOXPSTARTY;
+		++_vm->BCNT;
+		if (_tempListPtr[idx] == nullptr) {
+			BOXPSTARTY = oldPStartY;
+			_vm->_events->showCursor();
+			_vm->BOXDATAEND = 1;
+			return;
+		}
+
+		if (_vm->BCNT == _vm->NUMBLINES) {
+			BOXPSTARTY = oldPStartY;
+			_vm->_events->showCursor();
+			return;
+		}
+	}
 }
 
 void BubbleBox::drawSelectBox() {
@@ -503,9 +562,7 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 		drawSelectBox();
 	}
 
-
 	warning("TODO: more dobox_v1");
 	return -1;
 }
-
 } // End of namespace Access
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index 4aa9e26..082f2f7 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -44,7 +44,7 @@ private:
 	int _charCol, _rowOff;
 	Common::Point _fileStart;
 	int BOXSTARTX, BOXSTARTY;
-	int BOXENDY;
+	int BOXENDX, BOXENDY;
 	int BICONSTARTX, BICONSTARTY;
 	int BOXPSTARTX, BOXPSTARTY;
 
@@ -57,6 +57,7 @@ public:
 	Common::StringArray _nameIndex;
 	Common::String _bubbleTitle;
 	Common::String _bubbleDisplStr;
+	byte *_tempListPtr;
 	int _btnId1;
 	int _btnX1;
 	int _btnId2;
@@ -66,7 +67,7 @@ public:
 
 	Common::Array<Common::Rect> _bubbles;
 public:
-	BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w, int h, int val1, int val2, int val3, int val4, Common::String title);
+	BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w, int h, int val1, int val2, int val3, int val4, Common::String title, byte* tmpList);
 
 	void load(Common::SeekableReadStream *stream);
 


Commit: f1aa191f8c3acd0bfa259c4239bc6aadc9c9b0b0
    https://github.com/scummvm/scummvm/commit/f1aa191f8c3acd0bfa259c4239bc6aadc9c9b0b0
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-15T00:40:43+01:00

Commit Message:
ACCESS: MM - Implement getList

Changed paths:
    engines/access/access.cpp
    engines/access/access.h
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h
    engines/access/martian/martian_game.cpp
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h
    engines/access/scripts.cpp



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index fc01373..d239d08 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -95,7 +95,7 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 	for (int i = 0; i < 60; i++)
 		TRAVEL[i] = 0;
 	STARTTRAVELITEM = STARTTRAVELBOX = 0;
-	for (int i = 0; i < 16; i++)
+	for (int i = 0; i < 33; i++)
 		ASK[i];
 	_startAboutItem = _startAboutBox = 0;
 	_byte26CB5 = 0;
@@ -163,12 +163,12 @@ void AccessEngine::initialize() {
 
 	// Create sub-objects of the engine
 	_animation = new AnimationManager(this);
-	_bubbleBox = new BubbleBox(this, TYPE_2, 64, 32, 130, 122, 0, 0, 0, 0, "", nullptr);
+	_bubbleBox = new BubbleBox(this, TYPE_2, 64, 32, 130, 122, 0, 0, 0, 0, "");
 	if (getGameID() == GType_MartianMemorandum) {
-		_helpBox = new BubbleBox(this, TYPE_1, 64, 24, 146, 122, 1, 32, 2, 76, "HELP", TEMPLIST);
-		_travelBox = new BubbleBox(this, TYPE_1, 64, 32, 194, 122, 1, 24, 2, 74, "TRAVEL", TEMPLIST);
-		_invBox = new BubbleBox(this, TYPE_1, 64, 32, 146, 122, 1, 32, 2, 76, "INVENTORY", TEMPLIST);
-		_aboutBox = new BubbleBox(this, TYPE_1, 64, 32, 194, 122, 1, 32, 2, 76, "ASK ABOUT", TEMPLIST);
+		_helpBox = new BubbleBox(this, TYPE_1, 64, 24, 146, 122, 1, 32, 2, 76, "HELP");
+		_travelBox = new BubbleBox(this, TYPE_1, 64, 32, 194, 122, 1, 24, 2, 74, "TRAVEL");
+		_invBox = new BubbleBox(this, TYPE_1, 64, 32, 146, 122, 1, 32, 2, 76, "INVENTORY");
+		_aboutBox = new BubbleBox(this, TYPE_1, 64, 32, 194, 122, 1, 32, 2, 76, "ASK ABOUT");
 	} else {
 		_helpBox = nullptr;
 		_travelBox = nullptr;
diff --git a/engines/access/access.h b/engines/access/access.h
index d60a62f..ec19850 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -211,9 +211,9 @@ public:
 	// Fields used by MM
 	// TODO: Refactor
 	int TRAVEL[60];
+	int ASK[33];
 	int STARTTRAVELITEM;
 	int STARTTRAVELBOX;
-	int ASK[16];
 	int _startAboutItem;
 	int _startAboutBox;
 	int BOXDATASTART;
diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index 19b9c1f..30d33a7 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -26,7 +26,7 @@
 
 namespace Access {
 
-BubbleBox::BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w, int h, int val1, int val2, int val3, int val4, Common::String title, byte *tmpList) : Manager(vm) {
+BubbleBox::BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w, int h, int val1, int val2, int val3, int val4, Common::String title) : Manager(vm) {
 	_type = type;
 	_bounds = Common::Rect(x, y, x + w, y + h);
 	_bubbleDisplStr = title;
@@ -40,7 +40,8 @@ BubbleBox::BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w
 	BOXENDX = BOXENDY = 0;
 	BOXPSTARTX = BOXPSTARTY = 0;
 	// Unused in AGoE
-	_tempListPtr = tmpList;
+	for (int i = 0; i < 60; i++)
+		_tempListPtr[i] = "";
 }
 
 void BubbleBox::load(Common::SeekableReadStream *stream) {
@@ -294,14 +295,14 @@ void BubbleBox::displayBoxData() {
 	_vm->_fonts._charFor._lo = 15; // 0xFF
 	_vm->_fonts._charFor._hi = 15;
 
-	if (!_tempListPtr)
+	if (_tempListPtr[0].size() == 0)
 		return;
 
 	int idx = 0;
 	if ((_type == TYPE_1) || (_type == TYPE_3)) {
 		_vm->BCNT = 0;
 
-		if (_tempListPtr[idx] == -1) {
+		if (_tempListPtr[idx].size() == 0) {
 			_vm->BOXDATAEND = 1;
 			return;
 		}
@@ -322,7 +323,7 @@ void BubbleBox::displayBoxData() {
 	++BOXPSTARTY;
 
 	for (int i = 0; i < _vm->BOXDATASTART; i++, idx++) {
-		while (_tempListPtr[idx] != 0)
+		while (_tempListPtr[idx].size() != 0)
 			++idx;
 	}
 
@@ -332,7 +333,7 @@ void BubbleBox::displayBoxData() {
 		++idx;
 		++BOXPSTARTY;
 		++_vm->BCNT;
-		if (_tempListPtr[idx] == nullptr) {
+		if (_tempListPtr[idx].size() == 0) {
 			BOXPSTARTY = oldPStartY;
 			_vm->_events->showCursor();
 			_vm->BOXDATAEND = 1;
@@ -565,4 +566,17 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 	warning("TODO: more dobox_v1");
 	return -1;
 }
+
+void BubbleBox::getList(const char *data[], int *flags) {
+	int srcIdx = 0;
+	int destIdx = 0;
+	while (data[srcIdx]) {
+		if (flags[srcIdx]) {
+			_tempListPtr[destIdx] = Common::String(data[srcIdx]);
+			++destIdx;
+		}
+		srcIdx++;
+	}
+	_tempListPtr[destIdx] = "";
+}
 } // End of namespace Access
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index 082f2f7..ceafe13 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -57,7 +57,7 @@ public:
 	Common::StringArray _nameIndex;
 	Common::String _bubbleTitle;
 	Common::String _bubbleDisplStr;
-	byte *_tempListPtr;
+	Common::String _tempListPtr[60];
 	int _btnId1;
 	int _btnX1;
 	int _btnId2;
@@ -67,7 +67,7 @@ public:
 
 	Common::Array<Common::Rect> _bubbles;
 public:
-	BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w, int h, int val1, int val2, int val3, int val4, Common::String title, byte* tmpList);
+	BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w, int h, int val1, int val2, int val3, int val4, Common::String title);
 
 	void load(Common::SeekableReadStream *stream);
 
@@ -95,7 +95,7 @@ public:
 	void doBox(int item, int box);
 
 	int doBox_v1(int item, int box, int &type);
-	void getList() { warning("TODO: getList"); } // TODO: Check if implementation is useful
+	void getList(const char *data[], int *flags);
 };
 
 } // End of namespace Access
diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index 0b0644c..3ad9b65 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -74,6 +74,7 @@ void MartianEngine::initVariables() {
 	_mouseMode = 0;
 	_numAnimTimers = 0;
 	TRAVEL[7] = 1;
+	ASK[33] = 1;
 }
 
 void MartianEngine::setNoteParams() {
diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index c976fe2..09e16c1 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -807,7 +807,7 @@ const int RMOUSE[10][2] = {
 	{ 155, 185 }, { 188, 216 }, { 219, 260 }, { 263, 293 }, { 295, 214 }
 };
 
-const char *const TRAVDATA[] = {
+const char *TRAVDATA[] = {
 	"GALACTIC PICTURES", "TERRAFORM", "WASHROOM", "MR. BIG", "ALEXIS' HOME",
 	"JOHNNY FEDORA", "JUNKYARD IN", "TEX'S OFFICE", "MURDER SCENE", "PLAZA HOTEL",
 	"RESTAURANT", "GIFT SHOP", "LOVE SCENE", "RICK LOGAN", "HUT",
@@ -832,6 +832,14 @@ const char *const ASKTBL[] = {
 	"LARRRY HAMMOND", nullptr
 };
 
+
+byte HELP[] = {
+	1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+	1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+	1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+	1, 1, 1, 1, 1, 1, 1, 1, 1, 1
+};
+
 const byte DEATH_SCREENS[] = {
 	5, 5, 3, 3, 7, 4, 6, 2, 2, 2, 1, 5, 3, 5, 2, 8, 5, 3, 8, 5
 };
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index e758a89..fc9150d 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -55,8 +55,9 @@ extern const byte ICON_DATA[];
 
 extern const int RMOUSE[10][2];
 
-extern const char *const TRAVDATA[];
+extern byte HELP[];
 extern const char *const ASKTBL[];
+extern const char *TRAVDATA[];
 
 extern const byte DEATH_SCREENS[];
 extern const char *const DEATHMESSAGE[];
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 0daa1b9..114e0e7 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -617,7 +617,7 @@ void Scripts::cmdRemoveLast() {
 
 void Scripts::cmdDoTravel() {
 	while (true) {
-		_vm->_travelBox->getList();
+		_vm->_travelBox->getList(Martian::TRAVDATA, _vm->TRAVEL);
 		int type = 0;
 		int boxX = _vm->_travelBox->doBox_v1(_vm->STARTTRAVELITEM, _vm->STARTTRAVELBOX, type);
 		_vm->STARTTRAVELITEM = _vm->BOXDATASTART;


Commit: 0c14e42bd2dcbbc1029b835cd379c163345468ad
    https://github.com/scummvm/scummvm/commit/0c14e42bd2dcbbc1029b835cd379c163345468ad
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-15T08:23:55+01:00

Commit Message:
ACCESS: MM - Implement up and down arrows in BubbleBox

Changed paths:
    engines/access/access.cpp
    engines/access/access.h
    engines/access/asurface.cpp
    engines/access/asurface.h
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index d239d08..d0b2b78 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -100,7 +100,8 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 	_startAboutItem = _startAboutBox = 0;
 	_byte26CB5 = 0;
 	BCNT = 0;
-	BOXDATASTART = BOXDATAEND = 0;
+	BOXDATASTART = 0;
+	BOXDATAEND = false;
 	BOXSELECTY = 0;
 	BOXSELECTYOLD = -1;
 	NUMBLINES = 0;
diff --git a/engines/access/access.h b/engines/access/access.h
index ec19850..90c3d1f 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -217,7 +217,7 @@ public:
 	int _startAboutItem;
 	int _startAboutBox;
 	int BOXDATASTART;
-	int BOXDATAEND;
+	bool BOXDATAEND;
 	int BOXSELECTY;
 	int BOXSELECTYOLD;
 	int NUMBLINES;
diff --git a/engines/access/asurface.cpp b/engines/access/asurface.cpp
index 1417b0e..1029c35 100644
--- a/engines/access/asurface.cpp
+++ b/engines/access/asurface.cpp
@@ -320,6 +320,10 @@ void ASurface::drawLine(int x1, int y1, int x2, int y2, int col) {
 	Graphics::Surface::drawLine(x1, y1, x2, y2, col);
 }
 
+void ASurface::drawLine() {
+	Graphics::Surface::drawLine(_orgX1, _orgY1, _orgX2, _orgY1, _lColor);
+}
+
 void ASurface::drawBox() {
 	Graphics::Surface::drawLine(_orgX1, _orgY1, _orgX2, _orgY1, _lColor);
 	Graphics::Surface::drawLine(_orgX1, _orgY2, _orgX2, _orgY2, _lColor);
diff --git a/engines/access/asurface.h b/engines/access/asurface.h
index 3b7104c..0c656a0 100644
--- a/engines/access/asurface.h
+++ b/engines/access/asurface.h
@@ -97,6 +97,8 @@ public:
 
 	virtual void drawLine(int x1, int y1, int x2, int y2, int col);
 
+	virtual void drawLine();
+
 	virtual void drawBox();
 
 	virtual void transCopyFrom(ASurface *src, const Common::Point &destPos);
diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index 30d33a7..f0d3c8b 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -287,8 +287,13 @@ void BubbleBox::doBox(int item, int box) {
 	delete icons;
 }
 
+void BubbleBox::SETCURSORPOS(int posX, int posY) {
+//	_vm->_screen->_printStart = _vm->_screen->_printOrg = Common::Point((posX << 3) + _rowOff, posY << 3);
+	warning("TODO: CURSORSET");
+}
+
 void BubbleBox::displayBoxData() {
-	_vm->BOXDATAEND = 0;
+	_vm->BOXDATAEND = false;
 	_rowOff = 2;
 	_vm->_fonts._charSet._lo = 7;  // 0xF7
 	_vm->_fonts._charSet._hi = 15;
@@ -303,7 +308,7 @@ void BubbleBox::displayBoxData() {
 		_vm->BCNT = 0;
 
 		if (_tempListPtr[idx].size() == 0) {
-			_vm->BOXDATAEND = 1;
+			_vm->BOXDATAEND = true;
 			return;
 		}
 
@@ -322,13 +327,12 @@ void BubbleBox::displayBoxData() {
 	int oldPStartY = BOXPSTARTY;
 	++BOXPSTARTY;
 
-	for (int i = 0; i < _vm->BOXDATASTART; i++, idx++) {
-		while (_tempListPtr[idx].size() != 0)
-			++idx;
-	}
+	idx += _vm->BOXDATASTART;
 
 	while (true) {
-		warning("TODO: SETCURSOR");
+//		SETCURSORPOS(BOXPSTARTX, BOXPSTARTY);
+//		_vm->_fonts._font1.drawString(_vm->_screen, _tempListPtr[idx], Common::Point((BOXPSTARTX << 3) + _rowOff, BOXPSTARTY << 3));
+
 		warning("TODO: PRINTSTR");
 		++idx;
 		++BOXPSTARTY;
@@ -336,7 +340,7 @@ void BubbleBox::displayBoxData() {
 		if (_tempListPtr[idx].size() == 0) {
 			BOXPSTARTY = oldPStartY;
 			_vm->_events->showCursor();
-			_vm->BOXDATAEND = 1;
+			_vm->BOXDATAEND = true;
 			return;
 		}
 
@@ -438,8 +442,54 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 		_vm->_screen->_orgY1 = oldY;
 	}
 
-	if ((_type == TYPE_0) || (_type == TYPE_3))
-		warning("TODO: Implement more of TYPE_0 or TYPE_3");
+	if ((_type != TYPE_0) && (_type != TYPE_2)) {
+		_vm->_screen->_orgY1 += 8;
+		if (_type == TYPE_3)
+			_vm->_screen->_orgY2 -= 8;
+
+		_vm->_screen->_orgY2 -= 8;
+		_vm->_word234F7 = _vm->_word234FF = _vm->_screen->_orgX2;
+		_vm->_word234F3 = _vm->_word234FB = _vm->_screen->_orgX1 = _vm->_screen->_orgX2 - 8;
+		BOXENDX = _vm->_screen->_orgX1 - 1;
+		_vm->_screen->drawBox();
+
+		_vm->_screen->_orgY1 += 6;
+		_vm->_screen->_orgY2 -= 6;
+		_vm->_screen->drawBox();
+
+		_vm->_word234F9 = _vm->_screen->_orgY1 + 1;
+		_vm->_word234F5 = _vm->_word234F9 - 5;
+		_vm->_word234FD = _vm->_screen->_orgY2 + 1;
+		_vm->_word23501 = _vm->_word234FD - 6;
+		_vm->_screen->_orgX1 += 4;
+		_vm->_screen->_orgX2 = _vm->_screen->_orgX1;
+		_vm->_screen->_orgY1 -= 4;
+		_vm->_screen->_orgY2 += 2;
+		_vm->_screen->drawLine();
+
+		++_vm->_screen->_orgY1;
+		--_vm->_screen->_orgX1;
+		++_vm->_screen->_orgX2;
+		_vm->_screen->drawLine();
+
+		++_vm->_screen->_orgY1;
+		--_vm->_screen->_orgX1;
+		++_vm->_screen->_orgX2;
+		_vm->_screen->drawLine();
+
+		_vm->_screen->_orgY1 = _vm->_screen->_orgY2;
+		_vm->_screen->drawLine();
+
+		++_vm->_screen->_orgX1;
+		--_vm->_screen->_orgX2;
+		++_vm->_screen->_orgY1;
+		_vm->_screen->drawLine();
+
+		++_vm->_screen->_orgX1;
+		--_vm->_screen->_orgX2;
+		++_vm->_screen->_orgY1;
+		_vm->_screen->drawLine();
+	}
 
 	int len = _bubbleDisplStr.size();
 	int ax = _bounds.top >> 3;
@@ -544,7 +594,7 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 						if (_vm->BCNT != _vm->BOXSELECTY + 1) {
 							++_vm->BOXSELECTY;
 							drawSelectBox();
-						} else if (_vm->BOXDATAEND == 0) {
+						} else if (!_vm->BOXDATAEND) {
 							++_vm->BOXDATASTART;
 							displayBoxData();
 							drawSelectBox();
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index ceafe13..15dee09 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -96,6 +96,7 @@ public:
 
 	int doBox_v1(int item, int box, int &type);
 	void getList(const char *data[], int *flags);
+	void SETCURSORPOS(int posX, int posY);
 };
 
 } // End of namespace Access


Commit: 519ecbb7be987d8a2e01fb3687ef021b2afb16e6
    https://github.com/scummvm/scummvm/commit/519ecbb7be987d8a2e01fb3687ef021b2afb16e6
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-16T01:32:01+01:00

Commit Message:
ACCESS: MM - Initial string display in doBox_v1

Changed paths:
    engines/access/bubble_box.cpp



diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index f0d3c8b..7405121 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -331,7 +331,8 @@ void BubbleBox::displayBoxData() {
 
 	while (true) {
 //		SETCURSORPOS(BOXPSTARTX, BOXPSTARTY);
-//		_vm->_fonts._font1.drawString(_vm->_screen, _tempListPtr[idx], Common::Point((BOXPSTARTX << 3) + _rowOff, BOXPSTARTY << 3));
+		warning("%d %d -> %d %d", BOXPSTARTX, BOXPSTARTY, (BOXPSTARTX << 3) + _rowOff, BOXPSTARTY << 3);
+		_vm->_fonts._font1.drawString(_vm->_screen, _tempListPtr[idx], Common::Point((BOXPSTARTX << 3) + _rowOff, BOXPSTARTY << 3));
 
 		warning("TODO: PRINTSTR");
 		++idx;
@@ -492,27 +493,28 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 	}
 
 	int len = _bubbleDisplStr.size();
-	int ax = _bounds.top >> 3;
-	ax -= len;
-	ax /= 2;
-	int cx = _bounds.left >> 3;
-	BOXPSTARTX = cx;
-	ax += cx << 16;
-
-	cx = _bounds.right >> 3;
-	int bp = _bounds.right - (cx << 3) + 1;
+	int newX = _bounds.top >> 3;
+	newX = (len - newX) / 2;
+
+	BOXPSTARTX = _bounds.left >> 3;
+	newX += BOXPSTARTX;
+
+	int newY = _bounds.top >> 3;
+	int bp = _bounds.top - (newY << 3) + 1;
 	if (bp == 8) {
-		++cx;
+		++newY;
 		bp = 0;
 	}
 
 	_rowOff = bp;
-	BOXPSTARTY = cx;
-	ax += cx;
+	BOXPSTARTY = newY;
 
-	_vm->_fonts._charFor._lo = -1;
-	_vm->_events->setCursor(CURSOR_ARROW);
+	// setcursorpos
+	_vm->_screen->_printOrg.y = _vm->_screen->_printStart.y = (newY << 3) + _rowOff;
+	_vm->_screen->_printOrg.x = _vm->_screen->_printStart.x = (newX << 3);
+	//
 
+	_vm->_fonts._charFor._lo = -1;
 	_vm->_fonts._font1.drawString(_vm->_screen, _bubbleDisplStr, _vm->_screen->_printOrg);
 
 	if (_type == TYPE_2) {


Commit: 6f2b648b083d795e2b6148b1b60936e67c615a3a
    https://github.com/scummvm/scummvm/commit/6f2b648b083d795e2b6148b1b60936e67c615a3a
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-16T08:09:57+01:00

Commit Message:
ACCESS: MM - Implement drawSelectBox

Changed paths:
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h



diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index 7405121..e40001a 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -288,8 +288,13 @@ void BubbleBox::doBox(int item, int box) {
 }
 
 void BubbleBox::SETCURSORPOS(int posX, int posY) {
-//	_vm->_screen->_printStart = _vm->_screen->_printOrg = Common::Point((posX << 3) + _rowOff, posY << 3);
-	warning("TODO: CURSORSET");
+	_vm->_screen->_printStart = _vm->_screen->_printOrg = Common::Point((posX << 3) + _rowOff, posY << 3);
+	warning("Missing call to SETCURSOR");
+}
+
+void BubbleBox::PRINTSTR(Common::String msg) {
+	warning("TODO: Proper implementation of PRINTSTR");
+	_vm->_fonts._font1.drawString(_vm->_screen, msg, _vm->_screen->_printOrg);
 }
 
 void BubbleBox::displayBoxData() {
@@ -330,11 +335,9 @@ void BubbleBox::displayBoxData() {
 	idx += _vm->BOXDATASTART;
 
 	while (true) {
-//		SETCURSORPOS(BOXPSTARTX, BOXPSTARTY);
-		warning("%d %d -> %d %d", BOXPSTARTX, BOXPSTARTY, (BOXPSTARTX << 3) + _rowOff, BOXPSTARTY << 3);
-		_vm->_fonts._font1.drawString(_vm->_screen, _tempListPtr[idx], Common::Point((BOXPSTARTX << 3) + _rowOff, BOXPSTARTY << 3));
+		SETCURSORPOS(BOXPSTARTX, BOXPSTARTY);
+		PRINTSTR(_tempListPtr[idx]);
 
-		warning("TODO: PRINTSTR");
 		++idx;
 		++BOXPSTARTY;
 		++_vm->BCNT;
@@ -354,7 +357,38 @@ void BubbleBox::displayBoxData() {
 }
 
 void BubbleBox::drawSelectBox() {
-	warning("TODO drawSelectBox");
+	if (_tempListPtr[0].size() == 0)
+		return;
+
+	if (((_type != TYPE_1) && (_type != TYPE_3)) || !_vm->BCNT)
+		return;
+
+	if (_vm->BOXSELECTYOLD != -1) {
+		_vm->_events->hideCursor();
+		_vm->_screen->_lColor = 0xFA;
+
+		int val = _vm->BOXSELECTYOLD + BOXPSTARTY + 1;
+		_vm->_screen->_orgY1 = (val << 3) + 2;
+		_vm->_screen->_orgY2 = _vm->_screen->_orgY1 + 7;
+		_vm->_screen->_orgX1 = BOXSTARTX;
+		_vm->_screen->_orgX2 = BOXENDX;
+		_vm->_screen->drawBox();
+		_vm->_events->showCursor();
+	}
+
+	_vm->_events->hideCursor();
+	_vm->BOXSELECTYOLD = _vm->BOXSELECTY;
+	int val = BOXPSTARTY + _vm->BOXSELECTY + 1;
+	_vm->_screen->_orgY1 = (val << 3) + 2;
+	_vm->_screen->_orgY2 = _vm->_screen->_orgY1 + 7;
+	_vm->_screen->_orgX1 = BOXSTARTX;
+	_vm->_screen->_orgX2 = BOXENDX;
+	_vm->_screen->_lColor = 0xFE;
+	_vm->_screen->drawBox();
+	_vm->_events->showCursor();
+
+	if (_type == TYPE_3)
+		warning("TODO: List filenames");
 }
 
 int BubbleBox::doBox_v1(int item, int box, int &type) {
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index 15dee09..52ee497 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -97,6 +97,7 @@ public:
 	int doBox_v1(int item, int box, int &type);
 	void getList(const char *data[], int *flags);
 	void SETCURSORPOS(int posX, int posY);
+	void PRINTSTR(Common::String msg);
 };
 
 } // End of namespace Access


Commit: 82027ef3253eb109eac457bc103756acc27a78c6
    https://github.com/scummvm/scummvm/commit/82027ef3253eb109eac457bc103756acc27a78c6
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-16T23:24:13+01:00

Commit Message:
ACCESS: MM - Finish the implementation of doBox_v1

Changed paths:
    engines/access/bubble_box.cpp



diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index e40001a..980ffd0 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -392,7 +392,10 @@ void BubbleBox::drawSelectBox() {
 }
 
 int BubbleBox::doBox_v1(int item, int box, int &type) {
+	static const int ICONW[] = { 0, 11, 28, 19, 19, 15 };
+
 	FontManager &fonts = _vm->_fonts;
+	int retval = -1;
 
 	_startItem = item;
 	_startBox = box;
@@ -454,6 +457,8 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 	BOXSTARTY = _vm->_screen->_orgY2 + 1;
 	_vm->_screen->_orgY2 = oldY;
 
+	int tmpX = 0;
+	int tmpY = 0;
 	if (_type != TYPE_2) {
 		oldY = _vm->_screen->_orgY1;
 		--_vm->_screen->_orgY2;
@@ -461,10 +466,10 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 		if (_type == TYPE_3)
 			_vm->_screen->_orgY1 -= 8;
 		_vm->_screen->drawRect();
+		tmpX = BICONSTARTX = _vm->_screen->_orgX1;
 
-		int tmpX = BICONSTARTX = _vm->_screen->_orgX1;
 		BOXSTARTX = tmpX + 1;
-		int tmpY = BOXENDY = _vm->_screen->_orgY1;
+		tmpY = BOXENDY = _vm->_screen->_orgY1;
 
 		if (_type == TYPE_3)
 			BICONSTARTY = tmpY - 7;
@@ -563,24 +568,24 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 	int ICON1T = 0;
 	int ICON1X = 0;
 	int ICON1Y = 0;
+	int ICON2T = 0;
+	int ICON2X = 0;
+	int ICON2Y = 0;
+	int ICON3T = 0;
+	int ICON3X = 0;
+	int ICON3Y = 0;
 	if (_btnId1) {
 		ICON1T = _btnId1;
 		ICON1X = BICONSTARTX + _btnX1;
 		ICON1Y = BICONSTARTY;
 		_vm->_screen->plotImage(icons, ICON1T + 10, Common::Point(ICON1X, ICON1Y));
 
-		int ICON2T = 0;
-		int ICON2X = 0;
-		int ICON2Y = 0;
 		if (_btnId2) {
 			ICON2T = _btnId2;
 			ICON2X = BICONSTARTX + _btnX2;
 			ICON2Y = BICONSTARTY;
 			_vm->_screen->plotImage(icons, ICON2T + 10, Common::Point(ICON2X, ICON2Y));
 
-			int ICON3T = 0;
-			int ICON3X = 0;
-			int ICON3Y = 0;
 			if (_btnId3) {
 				ICON3T = _btnId3;
 				ICON3X = BICONSTARTX + _btnX3;
@@ -603,9 +608,9 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 	displayBoxData();
 	drawSelectBox();
 
-	while (true) {
+	while (!_vm->shouldQuit()) {
 		_vm->_events->pollEvents();
-		if (_vm->_events->_leftButton)
+		if (!_vm->_events->_leftButton)
 			continue;
 
 		if ((_type != TYPE_1) && (_vm->_timers[2]._flag == 0)) {
@@ -643,14 +648,55 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 				continue;
 			}
 		}
-		warning("TODO Case 1");
 
-		displayBoxData();
-		drawSelectBox();
-	}
+		if ((_vm->_events->_mousePos.x >= BOXSTARTX) && (_vm->_events->_mousePos.x <= BOXENDX)
+		&&  (_vm->_events->_mousePos.y >= BOXSTARTY) && (_vm->_events->_mousePos.y <= BOXENDY)) {
+			int val = (_vm->_events->_mousePos.x >> 3) - BOXPSTARTY;
+			if (val > _vm->BCNT)
+				continue;
+			--val;
+			if (_type == TYPE_3)
+				_vm->_boxSelect = val;
+			else {
+				retval = 1;
+				if (_vm->BOXSELECTY == val)
+					break;
+				_vm->BOXSELECTY = val;
+				_vm->_events->debounceLeft();
+				drawSelectBox();
+				continue;
+			}
+		}
+
+		if ((_vm->_events->_mousePos.y >= ICON1Y) && (_vm->_events->_mousePos.y <= ICON1Y + 8)
+		&&  (_vm->_events->_mousePos.x >= ICON1X)) {
+			retval = 1;
+			if (_vm->_events->_mousePos.x < ICON1X + ICONW[ICON1T])
+				break;
+
+			if ((_vm->_events->_mousePos.x >= ICON2X) && (_vm->_events->_mousePos.x < ICON2X + ICONW[ICON2T])) {
+				retval = 2;
+				break;
+			}
 
-	warning("TODO: more dobox_v1");
-	return -1;
+			if ((_vm->_events->_mousePos.x >= ICON3X) && (_vm->_events->_mousePos.x < ICON3X + ICONW[ICON3T])) {
+				retval = 3;
+				break;
+			}
+
+			if (_type != TYPE_3)
+				continue;
+			
+			if ((_vm->_events->_mousePos.x < tmpX) || (_vm->_events->_mousePos.x > tmpX + 144))
+				continue;
+
+			if ((_vm->_events->_mousePos.y < tmpY) || (_vm->_events->_mousePos.y > tmpY + 8))
+				continue;
+
+			warning("TODO: sub175B5");
+		}
+	}
+	return retval;
 }
 
 void BubbleBox::getList(const char *data[], int *flags) {


Commit: 27a9a046153c20d664394079f123f46a7ccde470
    https://github.com/scummvm/scummvm/commit/27a9a046153c20d664394079f123f46a7ccde470
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-17T09:42:41+01:00

Commit Message:
ACCESS: MM - Fix crash in cmdDoTravel, some renaming

Changed paths:
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h
    engines/access/scripts.cpp
    engines/access/scripts.h



diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index 980ffd0..e55f7f8 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -40,8 +40,10 @@ BubbleBox::BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w
 	BOXENDX = BOXENDY = 0;
 	BOXPSTARTX = BOXPSTARTY = 0;
 	// Unused in AGoE
-	for (int i = 0; i < 60; i++)
-		_tempListPtr[i] = "";
+	for (int i = 0; i < 60; i++) {
+		_tempList[i] = "";
+		_tempListIdx[i] = 0;
+	}
 }
 
 void BubbleBox::load(Common::SeekableReadStream *stream) {
@@ -305,14 +307,14 @@ void BubbleBox::displayBoxData() {
 	_vm->_fonts._charFor._lo = 15; // 0xFF
 	_vm->_fonts._charFor._hi = 15;
 
-	if (_tempListPtr[0].size() == 0)
+	if (_tempList[0].size() == 0)
 		return;
 
 	int idx = 0;
 	if ((_type == TYPE_1) || (_type == TYPE_3)) {
 		_vm->BCNT = 0;
 
-		if (_tempListPtr[idx].size() == 0) {
+		if (_tempList[idx].size() == 0) {
 			_vm->BOXDATAEND = true;
 			return;
 		}
@@ -336,12 +338,12 @@ void BubbleBox::displayBoxData() {
 
 	while (true) {
 		SETCURSORPOS(BOXPSTARTX, BOXPSTARTY);
-		PRINTSTR(_tempListPtr[idx]);
+		PRINTSTR(_tempList[idx]);
 
 		++idx;
 		++BOXPSTARTY;
 		++_vm->BCNT;
-		if (_tempListPtr[idx].size() == 0) {
+		if (_tempList[idx].size() == 0) {
 			BOXPSTARTY = oldPStartY;
 			_vm->_events->showCursor();
 			_vm->BOXDATAEND = true;
@@ -357,7 +359,7 @@ void BubbleBox::displayBoxData() {
 }
 
 void BubbleBox::drawSelectBox() {
-	if (_tempListPtr[0].size() == 0)
+	if (_tempList[0].size() == 0)
 		return;
 
 	if (((_type != TYPE_1) && (_type != TYPE_3)) || !_vm->BCNT)
@@ -391,11 +393,11 @@ void BubbleBox::drawSelectBox() {
 		warning("TODO: List filenames");
 }
 
-int BubbleBox::doBox_v1(int item, int box, int &type) {
+int BubbleBox::doBox_v1(int item, int box, int &btnSelected) {
 	static const int ICONW[] = { 0, 11, 28, 19, 19, 15 };
 
 	FontManager &fonts = _vm->_fonts;
-	int retval = -1;
+	int retval_ = -1;
 
 	_startItem = item;
 	_startBox = box;
@@ -546,8 +548,9 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 	}
 
 	_rowOff = bp;
-	BOXPSTARTY = newY;
+	retval_ = BOXPSTARTY = newY;
 
+	
 	// setcursorpos
 	_vm->_screen->_printOrg.y = _vm->_screen->_printStart.y = (newY << 3) + _rowOff;
 	_vm->_screen->_printOrg.x = _vm->_screen->_printStart.x = (newX << 3);
@@ -560,6 +563,7 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 		_vm->_events->showCursor();
 		warning("TODO: pop values");
 		_vm->_screen->restoreScreen();
+		return retval_;
 	}
 
 	_vm->_destIn = _vm->_screen;
@@ -658,7 +662,7 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 			if (_type == TYPE_3)
 				_vm->_boxSelect = val;
 			else {
-				retval = 1;
+				btnSelected = 1;
 				if (_vm->BOXSELECTY == val)
 					break;
 				_vm->BOXSELECTY = val;
@@ -670,17 +674,17 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 
 		if ((_vm->_events->_mousePos.y >= ICON1Y) && (_vm->_events->_mousePos.y <= ICON1Y + 8)
 		&&  (_vm->_events->_mousePos.x >= ICON1X)) {
-			retval = 1;
+			btnSelected = 1;
 			if (_vm->_events->_mousePos.x < ICON1X + ICONW[ICON1T])
 				break;
 
 			if ((_vm->_events->_mousePos.x >= ICON2X) && (_vm->_events->_mousePos.x < ICON2X + ICONW[ICON2T])) {
-				retval = 2;
+				btnSelected = 2;
 				break;
 			}
 
 			if ((_vm->_events->_mousePos.x >= ICON3X) && (_vm->_events->_mousePos.x < ICON3X + ICONW[ICON3T])) {
-				retval = 3;
+				btnSelected = 3;
 				break;
 			}
 
@@ -696,7 +700,16 @@ int BubbleBox::doBox_v1(int item, int box, int &type) {
 			warning("TODO: sub175B5");
 		}
 	}
-	return retval;
+
+	_vm->_events->hideCursor();
+	_vm->_screen->restoreBlock();
+	_vm->_events->showCursor();
+	_vm->_events->debounceLeft();
+	if (_vm->BCNT == 0)
+		retval_ = -1;
+	else
+		retval_ = _vm->BOXDATASTART + _vm->BOXSELECTY;
+	return retval_;
 }
 
 void BubbleBox::getList(const char *data[], int *flags) {
@@ -704,11 +717,12 @@ void BubbleBox::getList(const char *data[], int *flags) {
 	int destIdx = 0;
 	while (data[srcIdx]) {
 		if (flags[srcIdx]) {
-			_tempListPtr[destIdx] = Common::String(data[srcIdx]);
+			_tempList[destIdx] = Common::String(data[srcIdx]);
+			_tempListIdx[destIdx] = srcIdx;
 			++destIdx;
 		}
 		srcIdx++;
 	}
-	_tempListPtr[destIdx] = "";
+	_tempList[destIdx] = "";
 }
 } // End of namespace Access
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index 52ee497..5697c73 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -57,7 +57,8 @@ public:
 	Common::StringArray _nameIndex;
 	Common::String _bubbleTitle;
 	Common::String _bubbleDisplStr;
-	Common::String _tempListPtr[60];
+	Common::String _tempList[60];
+	int _tempListIdx[60];
 	int _btnId1;
 	int _btnX1;
 	int _btnId2;
@@ -94,7 +95,7 @@ public:
 
 	void doBox(int item, int box);
 
-	int doBox_v1(int item, int box, int &type);
+	int doBox_v1(int item, int box, int &btnSelected);
 	void getList(const char *data[], int *flags);
 	void SETCURSORPOS(int posX, int posY);
 	void PRINTSTR(Common::String msg);
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 114e0e7..e823f61 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -38,9 +38,6 @@ Scripts::Scripts(AccessEngine *vm) : Manager(vm) {
 	_charsOrg = Common::Point(0, 0);
 	_texsOrg = Common::Point(0, 0);
 	setOpcodes();
-
-	for (int i = 0; i < 60; i++)
-		TMPLPTR[i] = 0;
 }
 
 Scripts::~Scripts() {
@@ -618,16 +615,16 @@ void Scripts::cmdRemoveLast() {
 void Scripts::cmdDoTravel() {
 	while (true) {
 		_vm->_travelBox->getList(Martian::TRAVDATA, _vm->TRAVEL);
-		int type = 0;
-		int boxX = _vm->_travelBox->doBox_v1(_vm->STARTTRAVELITEM, _vm->STARTTRAVELBOX, type);
+		int btnSelected = 0;
+		int boxX = _vm->_travelBox->doBox_v1(_vm->STARTTRAVELITEM, _vm->STARTTRAVELBOX, btnSelected);
 		_vm->STARTTRAVELITEM = _vm->BOXDATASTART;
 		_vm->STARTTRAVELBOX = _vm->BOXSELECTY;
 
 		if (boxX == -1)
-			type = 2;
+			btnSelected = 2;
 
-		if (type != 2) {
-			int idx = TMPLPTR[boxX];
+		if (btnSelected != 2) {
+			int idx = _vm->_travelBox->_tempListIdx[boxX];
 			if (Martian::_byte1EEB5[idx] != _vm->_byte26CB5) {
 				_vm->_bubbleBox->_bubbleTitle = "TRAVEL";
 				_vm->_scripts->printString("YOU CAN'T GET THERE FROM HERE.");
diff --git a/engines/access/scripts.h b/engines/access/scripts.h
index d9715af..ba05203 100644
--- a/engines/access/scripts.h
+++ b/engines/access/scripts.h
@@ -146,7 +146,6 @@ public:
 	int32 _choiceStart;
 	Common::Point _charsOrg, _texsOrg;
 
-	int TMPLPTR[60];
 public:
 	Scripts(AccessEngine *vm);
 


Commit: c4e8460ba2a82560a29f32a08f31580befba78c1
    https://github.com/scummvm/scummvm/commit/c4e8460ba2a82560a29f32a08f31580befba78c1
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-17T14:26:56+01:00

Commit Message:
ACCESS: MM - Fix a bug related to the down arrow, some refactoring and renaming

Changed paths:
    engines/access/access.cpp
    engines/access/access.h
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index d0b2b78..8e9d52f 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -105,8 +105,6 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 	BOXSELECTY = 0;
 	BOXSELECTYOLD = -1;
 	NUMBLINES = 0;
-	_word234F3 = _word234F7 = _word234F5 = _word234F9 = 0;
-	_word234FB = _word234FF = _word234FD = _word23501 = 0;
 	TEMPLIST = nullptr;
 
 	_vidEnd = false;
diff --git a/engines/access/access.h b/engines/access/access.h
index 90c3d1f..176fb64 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -223,8 +223,6 @@ public:
 	int NUMBLINES;
 	byte _byte26CB5;
 	int BCNT;
-	int _word234F3, _word234F7, _word234F5, _word234F9;
-	int _word234FB, _word234FF, _word234FD, _word23501;
 	byte *TEMPLIST;
 	//
 
diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index e55f7f8..21e2501 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -44,6 +44,8 @@ BubbleBox::BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w
 		_tempList[i] = "";
 		_tempListIdx[i] = 0;
 	}
+	_btnUpPos = Common::Rect(0, 0, 0, 0);
+	_btnDownPos = Common::Rect(0, 0, 0, 0);
 }
 
 void BubbleBox::load(Common::SeekableReadStream *stream) {
@@ -490,8 +492,8 @@ int BubbleBox::doBox_v1(int item, int box, int &btnSelected) {
 			_vm->_screen->_orgY2 -= 8;
 
 		_vm->_screen->_orgY2 -= 8;
-		_vm->_word234F7 = _vm->_word234FF = _vm->_screen->_orgX2;
-		_vm->_word234F3 = _vm->_word234FB = _vm->_screen->_orgX1 = _vm->_screen->_orgX2 - 8;
+		_btnUpPos.right = _btnDownPos.right = _vm->_screen->_orgX2;
+		_btnUpPos.left = _btnDownPos.left = _vm->_screen->_orgX1 = _vm->_screen->_orgX2 - 8;
 		BOXENDX = _vm->_screen->_orgX1 - 1;
 		_vm->_screen->drawBox();
 
@@ -499,10 +501,11 @@ int BubbleBox::doBox_v1(int item, int box, int &btnSelected) {
 		_vm->_screen->_orgY2 -= 6;
 		_vm->_screen->drawBox();
 
-		_vm->_word234F9 = _vm->_screen->_orgY1 + 1;
-		_vm->_word234F5 = _vm->_word234F9 - 5;
-		_vm->_word234FD = _vm->_screen->_orgY2 + 1;
-		_vm->_word23501 = _vm->_word234FD - 6;
+		_btnUpPos.bottom = _vm->_screen->_orgY1 + 1;
+		_btnUpPos.top = _btnUpPos.bottom - 5;
+		_btnDownPos.top = _vm->_screen->_orgY2 + 1;
+		_btnDownPos.bottom = _btnDownPos.top + 6;
+
 		_vm->_screen->_orgX1 += 4;
 		_vm->_screen->_orgX2 = _vm->_screen->_orgX1;
 		_vm->_screen->_orgY1 -= 4;
@@ -619,8 +622,7 @@ int BubbleBox::doBox_v1(int item, int box, int &btnSelected) {
 
 		if ((_type != TYPE_1) && (_vm->_timers[2]._flag == 0)) {
 			++_vm->_timers[2]._flag;
-			if ((_vm->_events->_mousePos.x >= _vm->_word234F3) && (_vm->_events->_mousePos.x <= _vm->_word234F7)
-			&& (_vm->_events->_mousePos.y >= _vm->_word234F5) && (_vm->_events->_mousePos.y < _vm->_word234F9)) {
+			if (_btnUpPos.contains(_vm->_events->_mousePos)) {
 				if (_vm->BCNT) {
 					if (_vm->BOXSELECTY != 0) {
 						--_vm->BOXSELECTY;
@@ -632,8 +634,7 @@ int BubbleBox::doBox_v1(int item, int box, int &btnSelected) {
 					}
 				}
 				continue;
-			} else if ((_vm->_events->_mousePos.x >= _vm->_word234FB) && (_vm->_events->_mousePos.x <= _vm->_word234FF)
-			&& (_vm->_events->_mousePos.y >= _vm->_word234FD) && (_vm->_events->_mousePos.y < _vm->_word23501)) {
+			} else if (_btnDownPos.contains(_vm->_events->_mousePos)) {
 				if (_vm->BCNT) {
 					if (_vm->BCNT == _vm->NUMBLINES) {
 						if (_vm->BCNT != _vm->BOXSELECTY + 1) {
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index 5697c73..dd6a043 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -65,6 +65,8 @@ public:
 	int _btnX2;
 	int _btnId3;
 	int _btnX3;
+	Common::Rect _btnUpPos;
+	Common::Rect _btnDownPos;
 
 	Common::Array<Common::Rect> _bubbles;
 public:


Commit: b1477438bbc440e6bc240adc19029e7d2817da33
    https://github.com/scummvm/scummvm/commit/b1477438bbc440e6bc240adc19029e7d2817da33
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-18T15:26:05+01:00

Commit Message:
ACCESS: MM - Implement displayInv

Changed paths:
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h
    engines/access/inventory.cpp
    engines/access/inventory.h
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h
    engines/access/room.cpp
    engines/access/scripts.h



diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index 21e2501..97bdbed 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -713,7 +713,7 @@ int BubbleBox::doBox_v1(int item, int box, int &btnSelected) {
 	return retval_;
 }
 
-void BubbleBox::getList(const char *data[], int *flags) {
+void BubbleBox::getList(const char *const data[], int *flags) {
 	int srcIdx = 0;
 	int destIdx = 0;
 	while (data[srcIdx]) {
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index dd6a043..065e0ef 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -98,7 +98,7 @@ public:
 	void doBox(int item, int box);
 
 	int doBox_v1(int item, int box, int &btnSelected);
-	void getList(const char *data[], int *flags);
+	void getList(const char *const data[], int *flags);
 	void SETCURSORPOS(int posX, int posY);
 	void PRINTSTR(Common::String msg);
 };
diff --git a/engines/access/inventory.cpp b/engines/access/inventory.cpp
index 8db62a4..781650b 100644
--- a/engines/access/inventory.cpp
+++ b/engines/access/inventory.cpp
@@ -70,7 +70,7 @@ InventoryManager::InventoryManager(AccessEngine *vm) : Manager(vm) {
 	case GType_MartianMemorandum:
 		names = Martian::INVENTORY_NAMES;
 		combineP = &Martian::COMBO_TABLE[0][0];
-		_inv.resize(54);
+		_inv.resize(55);
 		break;
 	default:
 		error("Unknown game");
@@ -208,6 +208,33 @@ int InventoryManager::newDisplayInv() {
 	return result;
 }
 
+int InventoryManager::displayInv() {
+	warning("TODO: displayInv");
+	int *inv = (int *) malloc (Martian::INVENTORY_SIZE * sizeof(int));
+
+	for (int i = 0; i < Martian::INVENTORY_SIZE; i++)
+		inv[i] = _inv[i]._value;
+	_vm->_events->forceSetCursor(CURSOR_CROSSHAIRS);
+	_vm->_invBox->getList(Martian::INVENTORY_NAMES, inv);
+
+	int btnSelected = 0;
+	int boxX = _vm->_invBox->doBox_v1(_startInvItem, _startInvBox, btnSelected);
+	_startInvItem = _vm->BOXDATASTART;
+	_startInvBox= _vm->BOXSELECTY;
+
+	if (boxX == -1)
+		btnSelected = 2;
+
+	if (btnSelected != 2)
+		_vm->_useItem = _vm->_invBox->_tempListIdx[boxX];
+	else
+		_vm->_useItem = -1;
+
+
+	free(inv);
+	return 0;
+}
+
 void InventoryManager::savedFields() {
 	Screen &screen = *_vm->_screen;
 	Room &room = *_vm->_room;
diff --git a/engines/access/inventory.h b/engines/access/inventory.h
index 6a9390e..1d88bf4 100644
--- a/engines/access/inventory.h
+++ b/engines/access/inventory.h
@@ -128,6 +128,7 @@ public:
 	void refreshInventory();
 
 	int newDisplayInv();
+	int displayInv();
 
 	/**
 	* Synchronize savegame data
diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index 09e16c1..5e07cd7 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -188,17 +188,19 @@ const int TRAVEL_POS[][2] = {
 	{ -1, 21 }
 };
 
+const int INVENTORY_SIZE = 55;
 const char *const INVENTORY_NAMES[] = {
-	"CAMERA", "LENS", "PHOTOS", "MAIL", "GUN", "CASH", "COMLINK", "AMMO",
-	"LOCKPICK KIT", "EARRING", "RECIEPTS", "PAPER", "LADDER", "BOOTS",
-	"DOCUMENTS", "KNIFE", "DAGGER", "KEYS", "ROCK", "LOG", "SHOVEL",
-	"STONE", "REMOTE CONTROL", "FOOD AND WATER", "DOOR CARD KEY",
+	"CAMERA", "LENS", "PHOTOS", "MAIL", "GUN",
+	"CASH", "COMLINK", "AMMO", "LOCKPICK KIT", "EARRING",
+	"RECIEPTS", "PAPER", "LADDER", "BOOTS", "DOCUMENTS",
+	"KNIFE", "DAGGER", "KEYS", "ROCK", "LOG",
+	"SHOVEL", "STONE", "REMOTE CONTROL", "FOOD AND WATER", "DOOR CARD KEY",
 	"FLASHLIGHT", "INTERLOCK KEY", "TOOLS", "REBREATHER", "JET PACK",
-	"ROD", "HCL2", "SAFE CARD KEY", "TUNING FORK", "STONE", "ROSE",
-	"KEY", "NOTE", "ALLEN WRENCH", "HOVER BOARD", "BLUE PRINTS",
-	"LETTER", "MEMORANDUM", "MARKERS", "FILM", "ANDRETTI FILM",
-	"GLASSES", "AMULET", "FACIAL KIT", "CAT FOOD", "MONKEY WRENCH",
-	"BIG DICK CARD", "BRA", "BOLT"
+	"ROD", "HCL2", "SAFE CARD KEY", "TUNING FORK", "STONE",
+	"ROSE", "KEY", "NOTE", "ALLEN WRENCH", "HOVER BOARD",
+	"BLUE PRINTS", "LETTER", "MEMORANDUM", "MARKERS", "FILM",
+	"ANDRETTI FILM", "GLASSES", "AMULET", "FACIAL KIT", "CAT FOOD",
+	"MONKEY WRENCH", "BIG DICK CARD", "BRA", "BOLT", nullptr
 };
 
 const byte ROOM_TABLE1[] = {
@@ -807,7 +809,7 @@ const int RMOUSE[10][2] = {
 	{ 155, 185 }, { 188, 216 }, { 219, 260 }, { 263, 293 }, { 295, 214 }
 };
 
-const char *TRAVDATA[] = {
+const char *const TRAVDATA[] = {
 	"GALACTIC PICTURES", "TERRAFORM", "WASHROOM", "MR. BIG", "ALEXIS' HOME",
 	"JOHNNY FEDORA", "JUNKYARD IN", "TEX'S OFFICE", "MURDER SCENE", "PLAZA HOTEL",
 	"RESTAURANT", "GIFT SHOP", "LOVE SCENE", "RICK LOGAN", "HUT",
@@ -832,7 +834,6 @@ const char *const ASKTBL[] = {
 	"LARRRY HAMMOND", nullptr
 };
 
-
 byte HELP[] = {
 	1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
 	1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index fc9150d..fb147ac 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -35,6 +35,7 @@ extern const byte *const CURSORS[4];
 
 extern const int TRAVEL_POS[][2];
 
+extern const int INVENTORY_SIZE;
 extern const char *const INVENTORY_NAMES[];
 
 extern const byte *const ROOM_TABLE[];
@@ -57,7 +58,7 @@ extern const int RMOUSE[10][2];
 
 extern byte HELP[];
 extern const char *const ASKTBL[];
-extern const char *TRAVDATA[];
+extern const char *const TRAVDATA[];
 
 extern const byte DEATH_SCREENS[];
 extern const char *const DEATHMESSAGE[];
diff --git a/engines/access/room.cpp b/engines/access/room.cpp
index fa0c0c4..669ee26 100644
--- a/engines/access/room.cpp
+++ b/engines/access/room.cpp
@@ -515,9 +515,6 @@ void Room::cycleCommand(int incr) {
 }
 
 void Room::handleCommand(int commandId) {
-	if (commandId == 1)
-		--commandId;
-
 	if (commandId == 9) {
 		_vm->_events->debounceLeft();
 		_vm->_canSaveLoad = true;
@@ -536,39 +533,75 @@ void Room::executeCommand(int commandId) {
 	EventsManager &events = *_vm->_events;
 	_selectCommand = commandId;
 
-	switch (commandId) {
-	case 0:
-		events.forceSetCursor(CURSOR_LOOK);
-		break;
-	case 2:
-		events.forceSetCursor(CURSOR_USE);
-		break;
-	case 3:
-		events.forceSetCursor(CURSOR_TAKE);
-		break;
-	case 4:
-		events.setCursor(CURSOR_ARROW);
-		if (_vm->_inventory->newDisplayInv() == 2) {
-			commandOff();
+	if (_vm->getGameID() == GType_MartianMemorandum) {
+		switch (commandId) {
+		case 4:
+			events.setCursor(CURSOR_ARROW);
+			if (_vm->_inventory->displayInv() == 2) {
+				commandOff();
+				return;
+			}
+			if (_vm->_useItem == 39) {
+				if (_vm->_player->_roomNumber == 23)
+					_vm->_currentMan = 1;
+				commandOff();
+				return;
+			} else if (_vm->_useItem == 6) {
+				_vm->_flags[3] = 2;
+				_vm->_scripts->converse1(24);
+
+				_conFlag = true;
+				while (_conFlag && !_vm->shouldQuitOrRestart()) {
+					_conFlag = false;
+					_vm->_scripts->executeScript();
+				}
+
+				_vm->_boxSelect = true;
+			}
+			break;
+		case 7:
+			walkCursor();
 			return;
+		default:
+			// No set cursor in MM. Forcing to CROSSHAIRS
+			events.setCursor(CURSOR_CROSSHAIRS);
+			break;
+		}
+	} else {
+		switch (commandId) {
+		case 0:
+		case 1:
+			events.forceSetCursor(CURSOR_LOOK);
+			break;
+		case 2:
+			events.forceSetCursor(CURSOR_USE);
+			break;
+		case 3:
+			events.forceSetCursor(CURSOR_TAKE);
+			break;
+		case 4:
+			events.setCursor(CURSOR_ARROW);
+			if (_vm->_inventory->newDisplayInv() == 2) {
+				commandOff();
+				return;
+			}
+			break;
+		case 5:
+			events.forceSetCursor(CURSOR_CLIMB);
+			break;
+		case 6:
+			events.forceSetCursor(CURSOR_TALK);
+			break;
+		case 7:
+			walkCursor();
+			return;
+		case 8:
+			events.forceSetCursor(CURSOR_HELP);
+			break;
+		default:
+			break;
 		}
-		break;
-	case 5:
-		events.forceSetCursor(CURSOR_CLIMB);
-		break;
-	case 6:
-		events.forceSetCursor(CURSOR_TALK);
-		break;
-	case 7:
-		walkCursor();
-		return;
-	case 8:
-		events.forceSetCursor(CURSOR_HELP);
-		break;
-	default:
-		break;
 	}
-
 	// Draw the default toolbar menu at the bottom of the screen
 	roomMenu();
 	_vm->_screen->saveScreen();
diff --git a/engines/access/scripts.h b/engines/access/scripts.h
index ba05203..a9f8bec 100644
--- a/engines/access/scripts.h
+++ b/engines/access/scripts.h
@@ -44,7 +44,6 @@ private:
 
 	void charLoop();
 	void printWatch();
-	void converse1(int val);
 
 protected:
 	Common::SeekableReadStream *_data;
@@ -172,6 +171,7 @@ public:
 	// Script commands that need to be public
 	void cmdFreeSound();
 	void cmdRetPos();
+	void converse1(int val);
 };
 
 } // End of namespace Access


Commit: 6ba81a974936d25846cd4e273393c39f206ad2f7
    https://github.com/scummvm/scummvm/commit/6ba81a974936d25846cd4e273393c39f206ad2f7
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-19T00:11:05+01:00

Commit Message:
ACCESS: MM - Implement printBubble_v1

Changed paths:
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h
    engines/access/inventory.cpp
    engines/access/scripts.cpp
    engines/access/scripts.h



diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index 97bdbed..da3ae66 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -74,7 +74,7 @@ void BubbleBox::clearBubbles() {
 }
 
 void BubbleBox::placeBubble(const Common::String &msg) {
-	_vm->_screen->_maxChars = 27;
+	_vm->_screen->_maxChars = (_vm->getGameID() == GType_MartianMemorandum) ? 30 : 27;
 	placeBubble1(msg);
 }
 
@@ -82,15 +82,18 @@ void BubbleBox::placeBubble1(const Common::String &msg) {
 	_bubbles.clear();
 	_vm->_fonts._charSet._lo = 1;
 	_vm->_fonts._charSet._hi = 8;
-	_vm->_fonts._charFor._lo = 29;
-	_vm->_fonts._charFor._hi = 32;
+	_vm->_fonts._charFor._lo = (_vm->getGameID() == GType_MartianMemorandum) ? 247 : 29;
+	_vm->_fonts._charFor._hi = (_vm->getGameID() == GType_MartianMemorandum) ? 255 : 32;
 
 	calcBubble(msg);
 
 	Common::Rect r = _bubbles[0];
 	r.translate(-2, 0);
 	_vm->_screen->saveBlock(r);
-	printBubble(msg);
+	if (_vm->getGameID() == GType_MartianMemorandum)
+		printBubble_v1(msg);
+	else
+		printBubble_v2(msg);
 }
 
 void BubbleBox::calcBubble(const Common::String &msg) {
@@ -149,7 +152,29 @@ void BubbleBox::calcBubble(const Common::String &msg) {
 	_vm->_screen->_printStart = printStart;
 }
 
-void BubbleBox::printBubble(const Common::String &msg) {
+void BubbleBox::printBubble_v1(const Common::String &msg) {
+	drawBubble(_bubbles.size() - 1);
+	
+	// Loop through drawing the lines
+	Common::String s = msg;
+	Common::String line;
+	int width = 0;
+	bool lastLine;
+	do {
+		// Get next line
+		Font &font2 = _vm->_fonts._font2;
+		lastLine = font2.getLine(s, _vm->_screen->_maxChars * 6, line, width);
+		// Draw the text
+		font2.drawString(_vm->_screen, line, _vm->_screen->_printOrg);
+
+		// Move print position
+		_vm->_screen->_printOrg.y += 6;
+		_vm->_screen->_printOrg.x = _vm->_screen->_printStart.x;
+	} while (!lastLine);
+
+}
+
+void BubbleBox::printBubble_v2(const Common::String &msg) {
 	drawBubble(_bubbles.size() - 1);
 
 	// Loop through drawing the lines
@@ -183,7 +208,11 @@ void BubbleBox::printBubble(const Common::String &msg) {
 
 void BubbleBox::drawBubble(int index) {
 	_bounds = _bubbles[index];
-	doBox(0, 0);
+	if (_vm->getGameID() == GType_MartianMemorandum) {
+		int btnSelected = 0;
+		doBox_v1(0, 0, btnSelected);
+	} else
+		doBox(0, 0);
 }
 
 void BubbleBox::doBox(int item, int box) {
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index 065e0ef..26cda6c 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -87,7 +87,8 @@ public:
 	/**
 	 * Prints a text bubble and it's contents
 	 */
-	void printBubble(const Common::String &msg);
+	void printBubble_v1(const Common::String &msg);
+	void printBubble_v2(const Common::String &msg);
 
 	/*
 	 * Draws the background for a text bubble
diff --git a/engines/access/inventory.cpp b/engines/access/inventory.cpp
index 781650b..1d78839 100644
--- a/engines/access/inventory.cpp
+++ b/engines/access/inventory.cpp
@@ -230,7 +230,6 @@ int InventoryManager::displayInv() {
 	else
 		_vm->_useItem = -1;
 
-
 	free(inv);
 	return 0;
 }
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index e823f61..4e19659 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -54,7 +54,7 @@ void Scripts::setOpcodes() {
 	COMMAND_LIST[6] = &Scripts::cmdJumpUse;
 	COMMAND_LIST[7] = &Scripts::cmdJumpTalk;
 	COMMAND_LIST[8] = &Scripts::cmdNull;
-	COMMAND_LIST[9] = &Scripts::cmdPrint;
+	COMMAND_LIST[9] = &Scripts::cmdPrint_v1;
 	COMMAND_LIST[10] = &Scripts::cmdRetPos;
 	COMMAND_LIST[11] = &Scripts::cmdAnim;
 	COMMAND_LIST[12] = &Scripts::cmdSetFlag;
@@ -121,6 +121,7 @@ void Scripts::setOpcodes() {
 }
 
 void Scripts::setOpcodes_v2() {
+	COMMAND_LIST[9] = &Scripts::cmdPrint_v2;
 	COMMAND_LIST[15] = &Scripts::cmdSetInventory;
 	COMMAND_LIST[28] = &Scripts::cmdDispInv_v2;
 	COMMAND_LIST[29] = &Scripts::cmdSetTimer;
@@ -257,12 +258,24 @@ void Scripts::cmdNull() {
 
 #define PRINT_TIMER 25
 
-void Scripts::cmdPrint() {
+void Scripts::cmdPrint_v2() {
 	// Get a text line for display
 	Common::String msg = readString();
 	printString(msg);
 }
 
+void Scripts::cmdPrint_v1() {
+	_vm->_screen->_printOrg = Common::Point(20, 42);
+	_vm->_screen->_printStart = Common::Point(20, 32);
+	Common::String msg = readString();
+	_vm->_bubbleBox->placeBubble(msg);
+	_vm->_events->waitKeyMouse();
+	_vm->_events->hideCursor();
+	_vm->_screen->restoreBlock();
+	_vm->_events->showCursor();
+	findNull();
+}
+
 void Scripts::printString(const Common::String &msg) {
 	_vm->_screen->_printOrg = Common::Point(20, 42);
 	_vm->_screen->_printStart = Common::Point(20, 42);
@@ -751,7 +764,7 @@ void Scripts::cmdTexChoice() {
 		tmpStr += (char)v;
 
 	_vm->_bubbleBox->calcBubble(tmpStr);
-	_vm->_bubbleBox->printBubble(tmpStr);
+	_vm->_bubbleBox->printBubble_v2(tmpStr);
 
 	Common::Array<Common::Rect> responseCoords;
 	responseCoords.push_back(_vm->_bubbleBox->_bounds);
@@ -766,7 +779,7 @@ void Scripts::cmdTexChoice() {
 	if (tmpStr.size() != 0) {
 		_vm->_bubbleBox->_bubbleDisplStr = Common::String("RESPONSE 2");
 		_vm->_bubbleBox->calcBubble(tmpStr);
-		_vm->_bubbleBox->printBubble(tmpStr);
+		_vm->_bubbleBox->printBubble_v2(tmpStr);
 		responseCoords.push_back(_vm->_bubbleBox->_bounds);
 		_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + 11;
 	}
@@ -781,7 +794,7 @@ void Scripts::cmdTexChoice() {
 	if (tmpStr.size() != 0) {
 		_vm->_bubbleBox->_bubbleDisplStr = Common::String("RESPONSE 3");
 		_vm->_bubbleBox->calcBubble(tmpStr);
-		_vm->_bubbleBox->printBubble(tmpStr);
+		_vm->_bubbleBox->printBubble_v2(tmpStr);
 		responseCoords.push_back(_vm->_bubbleBox->_bounds);
 		_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + 11;
 	}
diff --git a/engines/access/scripts.h b/engines/access/scripts.h
index a9f8bec..905137d 100644
--- a/engines/access/scripts.h
+++ b/engines/access/scripts.h
@@ -66,7 +66,8 @@ protected:
 	void cmdJumpUse();
 	void cmdJumpTalk();
 	void cmdNull();
-	void cmdPrint();
+	void cmdPrint_v1();
+	void cmdPrint_v2();
 	void cmdAnim();
 	void cmdSetFlag();
 	void cmdCheckFlag();


Commit: c810ee9a5af2bdd8e27e5b558bb6838d3521541c
    https://github.com/scummvm/scummvm/commit/c810ee9a5af2bdd8e27e5b558bb6838d3521541c
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-19T20:53:53+01:00

Commit Message:
ACCESS: MM - Make CharEntry version-dependent

Changed paths:
    engines/access/char.cpp
    engines/access/char.h



diff --git a/engines/access/char.cpp b/engines/access/char.cpp
index 01b3349..c4fb0f2 100644
--- a/engines/access/char.cpp
+++ b/engines/access/char.cpp
@@ -27,11 +27,15 @@
 
 namespace Access {
 
-CharEntry::CharEntry(const byte *data) {
+CharEntry::CharEntry(const byte *data, int gameType) {
 	Common::MemoryReadStream s(data, 999);
 
 	_charFlag = s.readByte();
-	_estabIndex = s.readSint16LE();
+	if (gameType == GType_MartianMemorandum)
+		_estabIndex = -1;
+	else
+		_estabIndex = s.readSint16LE();
+
 	_screenFile.load(s);
 	_paletteFile.load(s);
 	_startColor = s.readUint16LE();
@@ -73,16 +77,16 @@ CharManager::CharManager(AccessEngine *vm) : Manager(vm) {
 		// Setup character list
 		if (_vm->isDemo()) {
 			for (int i = 0; i < 27; ++i)
-				_charTable.push_back(CharEntry(Amazon::CHARTBL_DEMO[i]));
+				_charTable.push_back(CharEntry(Amazon::CHARTBL_DEMO[i], vm->getGameID()));
 		} else {
 			for (int i = 0; i < 37; ++i)
-				_charTable.push_back(CharEntry(Amazon::CHARTBL[i]));
+				_charTable.push_back(CharEntry(Amazon::CHARTBL[i], vm->getGameID()));
 		}
 		break;
 
 	case GType_MartianMemorandum:
 		for (int i = 0; i < 27; ++i)
-			_charTable.push_back(CharEntry(Martian::CHARTBL_MM[i]));
+			_charTable.push_back(CharEntry(Martian::CHARTBL_MM[i], vm->getGameID()));
 		break;
 
 	default:
diff --git a/engines/access/char.h b/engines/access/char.h
index e89cdae..827d4d6 100644
--- a/engines/access/char.h
+++ b/engines/access/char.h
@@ -41,7 +41,7 @@ public:
 	FileIdent _scriptFile;
 	Common::Array<ExtraCell> _extraCells;
 public:
-	CharEntry(const byte *data);
+	CharEntry(const byte *data, int gameType);
 
 	CharEntry();
 };


Commit: f60a4d3e71e2de6a5159f0044874755671933d55
    https://github.com/scummvm/scummvm/commit/f60a4d3e71e2de6a5159f0044874755671933d55
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-21T00:26:11+01:00

Commit Message:
ACCESS: MM - Fix the "android" watch dialog and animation

Changed paths:
    engines/access/char.cpp
    engines/access/char.h



diff --git a/engines/access/char.cpp b/engines/access/char.cpp
index c4fb0f2..d2b1aa6 100644
--- a/engines/access/char.cpp
+++ b/engines/access/char.cpp
@@ -27,19 +27,30 @@
 
 namespace Access {
 
-CharEntry::CharEntry(const byte *data, int gameType) {
+CharEntry::CharEntry(const byte *data, AccessEngine *vm) {
 	Common::MemoryReadStream s(data, 999);
 
 	_charFlag = s.readByte();
-	if (gameType == GType_MartianMemorandum)
+	if (vm->getGameID() == GType_MartianMemorandum)
 		_estabIndex = -1;
 	else
 		_estabIndex = s.readSint16LE();
 
 	_screenFile.load(s);
+
+	if (vm->getGameID() == GType_MartianMemorandum) {
+		int idx = s.readSint16LE();
+		if (idx != -1)
+			warning("TODO: more CharEntry");
+	}
+
 	_paletteFile.load(s);
 	_startColor = s.readUint16LE();
-	_numColors = s.readUint16LE();
+	if (vm->getGameID() == GType_MartianMemorandum) {
+		int lastColor = s.readUint16LE();
+		_numColors = lastColor - _startColor;
+	} else 
+		_numColors = s.readUint16LE();
 
 	// Load cells
 	for (byte cell = s.readByte(); cell != 0xff; cell = s.readByte()) {
@@ -77,16 +88,16 @@ CharManager::CharManager(AccessEngine *vm) : Manager(vm) {
 		// Setup character list
 		if (_vm->isDemo()) {
 			for (int i = 0; i < 27; ++i)
-				_charTable.push_back(CharEntry(Amazon::CHARTBL_DEMO[i], vm->getGameID()));
+				_charTable.push_back(CharEntry(Amazon::CHARTBL_DEMO[i], vm));
 		} else {
 			for (int i = 0; i < 37; ++i)
-				_charTable.push_back(CharEntry(Amazon::CHARTBL[i], vm->getGameID()));
+				_charTable.push_back(CharEntry(Amazon::CHARTBL[i], vm));
 		}
 		break;
 
 	case GType_MartianMemorandum:
 		for (int i = 0; i < 27; ++i)
-			_charTable.push_back(CharEntry(Martian::CHARTBL_MM[i], vm->getGameID()));
+			_charTable.push_back(CharEntry(Martian::CHARTBL_MM[i], vm));
 		break;
 
 	default:
diff --git a/engines/access/char.h b/engines/access/char.h
index 827d4d6..e64e900 100644
--- a/engines/access/char.h
+++ b/engines/access/char.h
@@ -41,7 +41,7 @@ public:
 	FileIdent _scriptFile;
 	Common::Array<ExtraCell> _extraCells;
 public:
-	CharEntry(const byte *data, int gameType);
+	CharEntry(const byte *data, AccessEngine *vm);
 
 	CharEntry();
 };


Commit: d7f37d213c37a8f0f92ac672a49fc77333b1036b
    https://github.com/scummvm/scummvm/commit/d7f37d213c37a8f0f92ac672a49fc77333b1036b
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-21T01:10:37+01:00

Commit Message:
ACCESS: MM - Implement printWatch and clearWatch

Changed paths:
    engines/access/scripts.cpp
    engines/access/scripts.h



diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 4e19659..cc8eb61 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -172,8 +172,49 @@ void Scripts::charLoop() {
 	_endFlag = endFlag;
 }
 
+void Scripts::clearWatch() {
+	_vm->_events->hideCursor();
+	_vm->_screen->_orgX1 = 128;
+	_vm->_screen->_orgY1 = 57;
+	_vm->_screen->_orgX2 = 228;
+	_vm->_screen->_orgY2 = 106;
+	_vm->_screen->_lColor = 0;
+	_vm->_screen->drawRect();
+
+	_vm->_events->showCursor();
+}
+
 void Scripts::printWatch() {
-	error("TODO: printWatch");
+	_vm->_fonts._charSet._lo = 8;
+	_vm->_fonts._charSet._hi = 2;
+	_vm->_fonts._charFor._lo = 2;
+	_vm->_fonts._charFor._hi = 255;
+
+	_vm->_screen->_maxChars = 19;
+	_vm->_screen->_printOrg = Common::Point(128, 58);
+	_vm->_screen->_printStart = Common::Point(128, 58);
+	clearWatch();
+
+	Common::String msg = readString();
+	Common::String line = "";
+	int width = 0;
+	bool lastLine;
+	do {
+		lastLine = _vm->_fonts._font2.getLine(msg, _vm->_screen->_maxChars * 6, line, width);
+		warning("TODO: use printString");
+		// Draw the text
+		_vm->_fonts._font2.drawString(_vm->_screen, line, _vm->_screen->_printOrg);
+
+		_vm->_screen->_printOrg.y += 6;
+		_vm->_screen->_printOrg.x = _vm->_screen->_printStart.x;
+
+		if (_vm->_screen->_printOrg.y == 106) {
+			_vm->_events->waitKeyMouse();
+			clearWatch();
+			_vm->_screen->_printOrg.y = _vm->_screen->_printStart.y;
+		}
+	} while (!lastLine);
+	_vm->_events->waitKeyMouse();
 }
 
 void Scripts::findNull() {
diff --git a/engines/access/scripts.h b/engines/access/scripts.h
index 905137d..b1a4120 100644
--- a/engines/access/scripts.h
+++ b/engines/access/scripts.h
@@ -43,6 +43,7 @@ private:
 	int _specialFunction;
 
 	void charLoop();
+	void clearWatch();
 	void printWatch();
 
 protected:


Commit: 290ea5dfa272a8139440db8aca4839c35e759bae
    https://github.com/scummvm/scummvm/commit/290ea5dfa272a8139440db8aca4839c35e759bae
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-21T07:54:11+01:00

Commit Message:
ACCESS: MM - Implement loading of cells00 in intro, some renaming

Changed paths:
    engines/access/martian/martian_game.cpp



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index 3ad9b65..07d0939 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -133,15 +133,19 @@ void MartianEngine::doSpecial5(int param1) {
 	_events->showCursor();
 	_screen->setIconPalette();
 	_screen->forceFadeIn();
-	warning("TODO: LoadCells");
+
+	Resource *cellsRes = _files->loadFile("CELLS00.LZ");
+	_objectsTable[0] = new SpriteResource(this, cellsRes);
+	delete cellsRes;
+
 	_timers[20]._timer = _timers[20]._initTm = 30;
-	Resource *_notesRes = _files->loadFile("NOTES.DAT");
-	_notesRes->_stream->skip(param1 * 2);
-	int pos = _notesRes->_stream->readUint16LE();
-	_notesRes->_stream->seek(pos);
+	Resource *notesRes = _files->loadFile("NOTES.DAT");
+	notesRes->_stream->skip(param1 * 2);
+	int pos = notesRes->_stream->readUint16LE();
+	notesRes->_stream->seek(pos);
 	Common::String msg = "";
 	byte c;
-	while ((c = (char)_notesRes->_stream->readByte()) != '\0')
+	while ((c = (char)notesRes->_stream->readByte()) != '\0')
 		msg += c;
 
 	displayNote(msg);


Commit: eed5116fef9aee79c879c567aecf39d5285ea19d
    https://github.com/scummvm/scummvm/commit/eed5116fef9aee79c879c567aecf39d5285ea19d
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-21T22:26:23+01:00

Commit Message:
ACCESS: MM - Fix the travel box

Changed paths:
    engines/access/bubble_box.cpp
    engines/access/scripts.cpp



diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index da3ae66..0fb39c9 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -649,7 +649,7 @@ int BubbleBox::doBox_v1(int item, int box, int &btnSelected) {
 		if (!_vm->_events->_leftButton)
 			continue;
 
-		if ((_type != TYPE_1) && (_vm->_timers[2]._flag == 0)) {
+		if (((_type == TYPE_1) || (_type != TYPE_3)) && (_vm->_timers[2]._flag == 0)) {
 			++_vm->_timers[2]._flag;
 			if (_btnUpPos.contains(_vm->_events->_mousePos)) {
 				if (_vm->BCNT) {
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index cc8eb61..60791bb 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -685,6 +685,8 @@ void Scripts::cmdDoTravel() {
 				continue;
 			}
 			if (_vm->_player->_roomNumber != idx) {
+				_vm->_player->_roomNumber = idx;
+				_vm->_room->_function = FN_CLEAR1;
 				if (Martian::TRAVEL_POS[idx][0] == -1) {
 					_vm->_player->_roomNumber = idx;
 					_vm->_room->_conFlag = true;


Commit: 1d100589ab1a6957b92fae09676ccc0974853d43
    https://github.com/scummvm/scummvm/commit/1d100589ab1a6957b92fae09676ccc0974853d43
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-21T23:43:45+01:00

Commit Message:
ACCESS: MM - Implement cmdDispAbout, initialize some variables

Changed paths:
    engines/access/access.h
    engines/access/martian/martian_game.cpp
    engines/access/scripts.cpp



diff --git a/engines/access/access.h b/engines/access/access.h
index 176fb64..844b824 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -211,7 +211,7 @@ public:
 	// Fields used by MM
 	// TODO: Refactor
 	int TRAVEL[60];
-	int ASK[33];
+	int ASK[40];
 	int STARTTRAVELITEM;
 	int STARTTRAVELBOX;
 	int _startAboutItem;
diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index 07d0939..fce115f 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -73,7 +73,13 @@ void MartianEngine::initVariables() {
 	_events->setNormalCursor(CURSOR_CROSSHAIRS);
 	_mouseMode = 0;
 	_numAnimTimers = 0;
+
+	for (int i = 0; i < 60; i++)
+		TRAVEL[i] = 0;
 	TRAVEL[7] = 1;
+
+	for (int i = 0; i < 40; i++)
+		ASK[i] = 0;
 	ASK[33] = 1;
 }
 
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 60791bb..ecf3cf7 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -984,7 +984,19 @@ void Scripts::cmdPrintWatch() {
 }
 
 void Scripts::cmdDispAbout() {
-	error("TODO: DEMO - cmdDispAbout");
+	_vm->_travelBox->getList(Martian::ASKTBL, _vm->ASK);
+	int btnSelected = 0;
+	int boxX = _vm->_aboutBox->doBox_v1(_vm->_startAboutItem, _vm->_startAboutBox, btnSelected);
+	_vm->_startAboutItem = _vm->BOXDATASTART;
+	_vm->_startAboutBox = _vm->BOXSELECTY;
+
+	if (boxX == -1)
+		btnSelected = 2;
+
+	if (btnSelected == 2)
+		_vm->_useItem = -1;
+	else
+		_vm->_useItem = _vm->_travelBox->_tempListIdx[boxX];		
 }
 
 void Scripts::cmdPushLocation() {


Commit: e4710aedfa2ffc08151b49e148d55ffb6344e792
    https://github.com/scummvm/scummvm/commit/e4710aedfa2ffc08151b49e148d55ffb6344e792
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-25T01:36:18+01:00

Commit Message:
ACCESS: MM - Fix the coordinates of the last menu icon

Changed paths:
    engines/access/martian/martian_resources.cpp



diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index 5e07cd7..72156ec 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -806,7 +806,7 @@ const byte ICON_DATA[] = {
 
 const int RMOUSE[10][2] = {
 	{ 7, 36 },    { 38, 68 },   { 70, 99 },   { 102, 125 }, { 128, 152 },
-	{ 155, 185 }, { 188, 216 }, { 219, 260 }, { 263, 293 }, { 295, 214 }
+	{ 155, 185 }, { 188, 216 }, { 219, 260 }, { 263, 293 }, { 295, 314 }
 };
 
 const char *const TRAVDATA[] = {


Commit: b6b5a520d4f899c5317140dbaf8d5d7b8381908b
    https://github.com/scummvm/scummvm/commit/b6b5a520d4f899c5317140dbaf8d5d7b8381908b
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-25T01:37:37+01:00

Commit Message:
ACCESS: MM - Add menu case 8

Changed paths:
    engines/access/room.cpp



diff --git a/engines/access/room.cpp b/engines/access/room.cpp
index 669ee26..5ad576e 100644
--- a/engines/access/room.cpp
+++ b/engines/access/room.cpp
@@ -557,11 +557,28 @@ void Room::executeCommand(int commandId) {
 				}
 
 				_vm->_boxSelect = true;
+				return;
 			}
 			break;
 		case 7:
 			walkCursor();
 			return;
+		case 8: {
+			EventsManager &events = *_vm->_events;
+
+			events.forceSetCursor(CURSOR_CROSSHAIRS);
+			_vm->_scripts->_sequence = 10000;
+			_vm->_scripts->searchForSequence();
+
+			_conFlag = true;
+			while (_conFlag && !_vm->shouldQuitOrRestart()) {
+				_conFlag = false;
+				_vm->_scripts->executeScript();
+			}
+
+			_vm->_boxSelect = true;
+			return;
+			}
 		default:
 			// No set cursor in MM. Forcing to CROSSHAIRS
 			events.setCursor(CURSOR_CROSSHAIRS);
@@ -602,8 +619,6 @@ void Room::executeCommand(int commandId) {
 			break;
 		}
 	}
-	// Draw the default toolbar menu at the bottom of the screen
-	roomMenu();
 	_vm->_screen->saveScreen();
 	_vm->_screen->setDisplayScan();
 


Commit: ca0bef9595f60d6478b0da89cdd330254ee8a2ef
    https://github.com/scummvm/scummvm/commit/ca0bef9595f60d6478b0da89cdd330254ee8a2ef
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-25T22:05:10+01:00

Commit Message:
ACCESS: MM - Split cmdHelp for MM

Changed paths:
    engines/access/amazon/amazon_scripts.cpp
    engines/access/amazon/amazon_scripts.h
    engines/access/scripts.cpp
    engines/access/scripts.h



diff --git a/engines/access/amazon/amazon_scripts.cpp b/engines/access/amazon/amazon_scripts.cpp
index d7ca408..1977754 100644
--- a/engines/access/amazon/amazon_scripts.cpp
+++ b/engines/access/amazon/amazon_scripts.cpp
@@ -381,7 +381,7 @@ typedef void(AmazonScripts::*AmazonScriptMethodPtr)();
 
 void AmazonScripts::executeCommand(int commandIndex) {
 	static const AmazonScriptMethodPtr COMMAND_LIST[] = {
-		&AmazonScripts::cmdHelp, &AmazonScripts::cmdCycleBack,
+		&AmazonScripts::cmdHelp_v2, &AmazonScripts::cmdCycleBack,
 		&AmazonScripts::cmdChapter, &AmazonScripts::cmdSetHelp,
 		&AmazonScripts::cmdCenterPanel, &AmazonScripts::cmdMainPanel,
 		&AmazonScripts::CMDRETFLASH
@@ -393,7 +393,7 @@ void AmazonScripts::executeCommand(int commandIndex) {
 		Scripts::executeCommand(commandIndex);
 }
 
-void AmazonScripts::cmdHelp() {
+void AmazonScripts::cmdHelp_v2() {
 	Common::String helpMessage = readString();
 
 	if (_game->_helpLevel == 0) {
diff --git a/engines/access/amazon/amazon_scripts.h b/engines/access/amazon/amazon_scripts.h
index e10eefb..6d99266 100644
--- a/engines/access/amazon/amazon_scripts.h
+++ b/engines/access/amazon/amazon_scripts.h
@@ -49,7 +49,7 @@ protected:
 	void setInactive();
 	void boatWalls(int param1, int param2);
 
-	void cmdHelp();
+	void cmdHelp_v2();
 	void cmdCycleBack();
 	void cmdChapter();
 	void cmdSetHelp();
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index ecf3cf7..d15f293 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -118,6 +118,7 @@ void Scripts::setOpcodes() {
 	COMMAND_LIST[70] = &Scripts::cmdDead;
 	COMMAND_LIST[71] = &Scripts::cmdFadeOut;
 	COMMAND_LIST[72] = &Scripts::cmdEndVideo;
+	COMMAND_LIST[73] = &Scripts::cmdHelp_v1;
 }
 
 void Scripts::setOpcodes_v2() {
@@ -318,11 +319,13 @@ void Scripts::cmdPrint_v1() {
 }
 
 void Scripts::printString(const Common::String &msg) {
-	_vm->_screen->_printOrg = Common::Point(20, 42);
-	_vm->_screen->_printStart = Common::Point(20, 42);
-	_vm->_timers[PRINT_TIMER]._timer = 50;
-	_vm->_timers[PRINT_TIMER]._initTm = 50;
-	++_vm->_timers[PRINT_TIMER]._flag;
+	if (_vm->getGameID() != GType_MartianMemorandum) {
+		_vm->_screen->_printOrg = Common::Point(20, 42);
+		_vm->_screen->_printStart = Common::Point(20, 42);
+		_vm->_timers[PRINT_TIMER]._timer = 50;
+		_vm->_timers[PRINT_TIMER]._initTm = 50;
+		++_vm->_timers[PRINT_TIMER]._flag;
+	}
 
 	// Display the text in a bubble, and wait for a keypress or mouse click
 	_vm->_bubbleBox->placeBubble(msg);
@@ -706,6 +709,34 @@ void Scripts::cmdDoTravel() {
 	}
 }
 
+void Scripts::cmdHelp_v1() {
+	int idx = 0;
+	for (int i = 0; i < 40; i++) {
+		byte c = _data->readByte();
+		if (c != 0xFF) {
+			Common::String tmpStr = c + readString();
+			if (Martian::HELP[i]) {
+				_vm->_helpBox->_tempList[idx] = tmpStr;
+				_vm->_helpBox->_tempListIdx[idx] = i;
+				++idx;
+			}
+		} else
+			break;
+	}
+	_vm->_helpBox->_tempList[idx] = "";
+
+	int btnSelected = 0;
+	int boxX = _vm->_helpBox->doBox_v1(0, 0, btnSelected);
+
+	if (boxX == -1)
+		btnSelected = 2;
+
+	if (btnSelected != 2)
+		_vm->_useItem = _vm->_helpBox->_tempListIdx[boxX];
+	else
+		_vm->_useItem = -1;
+}
+
 void Scripts::cmdCheckAbout() {
 	int idx = _data->readSint16LE();
 	int val = _data->readSint16LE();
diff --git a/engines/access/scripts.h b/engines/access/scripts.h
index b1a4120..a035087 100644
--- a/engines/access/scripts.h
+++ b/engines/access/scripts.h
@@ -135,7 +135,8 @@ protected:
 	void cmdDead();
 	void cmdFadeOut();
 	void cmdEndVideo();
-	void cmdHelp();
+	void cmdHelp_v1();
+	void cmdHelp_v2();
 	void cmdCycleBack();
 	void cmdSetHelp();
 public:


Commit: 587aad7d46443abe69c9b36743f827bfc9249014
    https://github.com/scummvm/scummvm/commit/587aad7d46443abe69c9b36743f827bfc9249014
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2015-01-25T17:19:19-05:00

Commit Message:
ACCESS: Fix moonwalking in MM

Changed paths:
    engines/access/amazon/amazon_player.cpp
    engines/access/amazon/amazon_resources.cpp
    engines/access/amazon/amazon_resources.h
    engines/access/martian/martian_player.cpp
    engines/access/martian/martian_resources.h
    engines/access/player.cpp
    engines/access/player.h
    engines/access/resources.cpp
    engines/access/resources.h



diff --git a/engines/access/amazon/amazon_player.cpp b/engines/access/amazon/amazon_player.cpp
index 2f32db1..903da6c 100644
--- a/engines/access/amazon/amazon_player.cpp
+++ b/engines/access/amazon/amazon_player.cpp
@@ -78,6 +78,22 @@ void AmazonPlayer::load() {
 		_diagDownWalkMin = 0;
 		_diagDownWalkMax = 5;
 		_game->_guard->setPosition(Common::Point(56, 190));
+	} else {
+		for (int i = 0; i < _vm->_playerDataCount; ++i) {
+			_walkOffRight[i] = SIDEOFFR[i];
+			_walkOffLeft[i] = SIDEOFFL[i];
+			_walkOffUp[i] = SIDEOFFU[i];
+			_walkOffDown[i] = SIDEOFFD[i];
+
+			_walkOffUR[i].x = DIAGOFFURX[i];
+			_walkOffUR[i].y = DIAGOFFURY[i];
+			_walkOffDR[i].x = DIAGOFFDRX[i];
+			_walkOffDR[i].y = DIAGOFFDRY[i];
+			_walkOffUL[i].x = DIAGOFFULX[i];
+			_walkOffUL[i].y = DIAGOFFULY[i];
+			_walkOffDL[i].x = DIAGOFFDLX[i];
+			_walkOffDL[i].y = DIAGOFFDLY[i];
+		}
 	}
 }
 
diff --git a/engines/access/amazon/amazon_resources.cpp b/engines/access/amazon/amazon_resources.cpp
index 2b36ca9..5ffb91d 100644
--- a/engines/access/amazon/amazon_resources.cpp
+++ b/engines/access/amazon/amazon_resources.cpp
@@ -72,6 +72,19 @@ const char *const FILENAMES_DEMO[] = {
 	"CHAPTER.AP", "MUSIC.AP", "SOUND.AP", "INV.AP"
 };
 
+const int SIDEOFFR[] = { 5, 5, 5, 5, 5, 5, 5, 5, 0 };
+const int SIDEOFFL[] = { 5, 5, 5, 5, 5, 5, 5, 5, 0 };
+const int SIDEOFFU[] = { 2, 2, 2, 2, 2, 2, 2, 2, 0 };
+const int SIDEOFFD[] = { 2, 2, 2, 2, 2, 2, 2, 2, 0 };
+const int DIAGOFFURX[] = { 4, 5, 2, 2, 3, 4, 2, 2, 0 };
+const int DIAGOFFURY[] = { 2, 3, 2, 2, 2, 3, 1, 1, 0 };
+const int DIAGOFFDRX[] = { 4, 5, 4, 3, 5, 4, 5, 1, 0 };
+const int DIAGOFFDRY[] = { 3, 2, 1, 2, 2, 1, 2, 1, 0 };
+const int DIAGOFFULX[] = { 4, 5, 4, 3, 3, 2, 2, 2, 0 };
+const int DIAGOFFULY[] = { 3, 3, 1, 2, 2, 1, 1, 1, 0 };
+const int DIAGOFFDLX[] = { 4, 5, 3, 3, 5, 4, 6, 1, 0 };
+const int DIAGOFFDLY[] = { 2, 2, 1, 2, 3, 1, 2, 1, 0 };
+
 const byte MOUSE0[] = {
 	// hotspot x and y, uint16 LE
 	0, 0, 0, 0,
diff --git a/engines/access/amazon/amazon_resources.h b/engines/access/amazon/amazon_resources.h
index 190424b..9801fd9 100644
--- a/engines/access/amazon/amazon_resources.h
+++ b/engines/access/amazon/amazon_resources.h
@@ -45,6 +45,19 @@ struct RiverStruct {
 extern const char *const FILENAMES[];
 extern const char *const FILENAMES_DEMO[];
 
+extern const int SIDEOFFR[];
+extern const int SIDEOFFL[];
+extern const int SIDEOFFU[];
+extern const int SIDEOFFD[];
+extern const int DIAGOFFURX[];
+extern const int DIAGOFFURY[];
+extern const int DIAGOFFDRX[];
+extern const int DIAGOFFDRY[];
+extern const int DIAGOFFULX[];
+extern const int DIAGOFFULY[];
+extern const int DIAGOFFDLX[];
+extern const int DIAGOFFDLY[];
+
 extern const byte *const CURSORS[10];
 
 extern const int TRAVEL_POS[][2];
diff --git a/engines/access/martian/martian_player.cpp b/engines/access/martian/martian_player.cpp
index f461751..598664a 100644
--- a/engines/access/martian/martian_player.cpp
+++ b/engines/access/martian/martian_player.cpp
@@ -47,6 +47,13 @@ void MartianPlayer::load() {
 	_downDelta = -5;
 	_scrollConst = 5;
 
+	for (int i = 0; i < _vm->_playerDataCount; ++i) {
+		_walkOffRight[i] = SIDEOFFR[i];
+		_walkOffLeft[i] = SIDEOFFL[i];
+		_walkOffUp[i] = SIDEOFFU[i];
+		_walkOffDown[i] = SIDEOFFD[i];
+	}
+
 	_sideWalkMin = 0;
 	_sideWalkMax = 7;
 	_upWalkMin = 8;
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index fb147ac..cf74cbb 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -31,6 +31,11 @@ namespace Martian {
 
 extern const char *const FILENAMES[];
 
+extern const int SIDEOFFR[];
+extern const int SIDEOFFL[];
+extern const int SIDEOFFU[];
+extern const int SIDEOFFD[];
+
 extern const byte *const CURSORS[4];
 
 extern const int TRAVEL_POS[][2];
diff --git a/engines/access/player.cpp b/engines/access/player.cpp
index fe555ec..e7a7b3f 100644
--- a/engines/access/player.cpp
+++ b/engines/access/player.cpp
@@ -112,21 +112,6 @@ void Player::load() {
 	_downDelta = -10;
 	_scrollConst = 5;
 
-	for (int i = 0; i < dataCount; ++i) {
-		_walkOffRight[i] = SIDEOFFR[i];
-		_walkOffLeft[i] = SIDEOFFL[i];
-		_walkOffUp[i] = SIDEOFFU[i];
-		_walkOffDown[i] = SIDEOFFD[i];
-		_walkOffUR[i].x = DIAGOFFURX[i];
-		_walkOffUR[i].y = DIAGOFFURY[i];
-		_walkOffDR[i].x = DIAGOFFDRX[i];
-		_walkOffDR[i].y = DIAGOFFDRY[i];
-		_walkOffUL[i].x = DIAGOFFULX[i];
-		_walkOffUL[i].y = DIAGOFFULY[i];
-		_walkOffDL[i].x = DIAGOFFDLX[i];
-		_walkOffDL[i].y = DIAGOFFDLY[i];
-	}
-
 	_sideWalkMin = 0;
 	_sideWalkMax = 7;
 	_upWalkMin = 16;
@@ -394,7 +379,7 @@ void Player::walkRight() {
 		if (_frame > _sideWalkMax)
 			_frame = _sideWalkMin;
 
-		plotCom(0);
+		plotCom0();
 	}
 }
 
@@ -671,15 +656,19 @@ void Player::checkMove() {
 }
 
 void Player::plotCom(int flags) {
-	_flags &= ~2;
-	_flags &= ~8;
+	_flags &= ~IMGFLAG_BACKWARDS;
+	_flags &= ~IMGFLAG_UNSCALED;
 	_flags |= flags;
 
 	plotCom3();
 }
 
+void Player::plotCom0() {
+	plotCom(_vm->getGameID() == GType_Amazon ? 0 : IMGFLAG_BACKWARDS);
+}
+
 void Player::plotCom1() {
-	plotCom(2);
+	plotCom(_vm->getGameID() == GType_Amazon ? IMGFLAG_BACKWARDS : 0);
 }
 
 void Player::plotCom2() {
diff --git a/engines/access/player.h b/engines/access/player.h
index db88892..8cecb67 100644
--- a/engines/access/player.h
+++ b/engines/access/player.h
@@ -60,6 +60,7 @@ protected:
 	int _inactiveYOff;
 
 	void plotCom(int v1);
+	void plotCom0();
 	void plotCom1();
 	void plotCom2();
 	void plotCom3();
diff --git a/engines/access/resources.cpp b/engines/access/resources.cpp
index 118e887..b1cc648 100644
--- a/engines/access/resources.cpp
+++ b/engines/access/resources.cpp
@@ -46,19 +46,6 @@ const byte INITIAL_PALETTE[18 * 3] = {
 	0x00, 0x00, 0x00
 };
 
-const int SIDEOFFR[] = { 5, 5, 5, 5, 5, 5, 5, 5, 0 };
-const int SIDEOFFL[] = { 5, 5, 5, 5, 5, 5, 5, 5, 0 };
-const int SIDEOFFU[] = { 2, 2, 2, 2, 2, 2, 2, 2, 0 };
-const int SIDEOFFD[] = { 2, 2, 2, 2, 2, 2, 2, 2, 0 };
-const int DIAGOFFURX[] = { 4, 5, 2, 2, 3, 4, 2, 2, 0 };
-const int DIAGOFFURY[] = { 2, 3, 2, 2, 2, 3, 1, 1, 0 };
-const int DIAGOFFDRX[] = { 4, 5, 4, 3, 5, 4, 5, 1, 0 };
-const int DIAGOFFDRY[] = { 3, 2, 1, 2, 2, 1, 2, 1, 0 };
-const int DIAGOFFULX[] = { 4, 5, 4, 3, 3, 2, 2, 2, 0 };
-const int DIAGOFFULY[] = { 3, 3, 1, 2, 2, 1, 1, 1, 0 };
-const int DIAGOFFDLX[] = { 4, 5, 3, 3, 5, 4, 6, 1, 0 };
-const int DIAGOFFDLY[] = { 2, 2, 1, 2, 3, 1, 2, 1, 0 };
-
 const char *const LOOK_MESSAGE = "LOOKING THERE REVEALS NOTHING OF INTEREST.";
 const char *const GET_MESSAGE  = "YOU CAN'T TAKE THAT.";
 const char *const OPEN_MESSAGE = "THAT DOESN'T OPEN.";
diff --git a/engines/access/resources.h b/engines/access/resources.h
index 2ef931b..07b8e5a 100644
--- a/engines/access/resources.h
+++ b/engines/access/resources.h
@@ -29,19 +29,6 @@ namespace Access {
 
 extern const byte INITIAL_PALETTE[18 * 3];
 
-extern const int SIDEOFFR[];
-extern const int SIDEOFFL[];
-extern const int SIDEOFFU[];
-extern const int SIDEOFFD[];
-extern const int DIAGOFFURX[];
-extern const int DIAGOFFURY[];
-extern const int DIAGOFFDRX[];
-extern const int DIAGOFFDRY[];
-extern const int DIAGOFFULX[];
-extern const int DIAGOFFULY[];
-extern const int DIAGOFFDLX[];
-extern const int DIAGOFFDLY[];
-
 extern const char *const GENERAL_MESSAGES[];
 
 extern const int INVCOORDS[][4];


Commit: ed4a3565a1b2997360ca0eaec1473c9ea5581976
    https://github.com/scummvm/scummvm/commit/ed4a3565a1b2997360ca0eaec1473c9ea5581976
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-25T23:30:04+01:00

Commit Message:
ACCESS: MM - Rename cmdSpecial5, implement cmdSpecial3

Changed paths:
    engines/access/martian/martian_scripts.cpp
    engines/access/martian/martian_scripts.h



diff --git a/engines/access/martian/martian_scripts.cpp b/engines/access/martian/martian_scripts.cpp
index 8d936ba..bb8230e 100644
--- a/engines/access/martian/martian_scripts.cpp
+++ b/engines/access/martian/martian_scripts.cpp
@@ -34,7 +34,18 @@ MartianScripts::MartianScripts(AccessEngine *vm) : Scripts(vm) {
 	_game = (MartianEngine *)_vm;
 }
 
-void MartianScripts::cmdSpecial5(int param1) {
+void MartianScripts::cmdSpecial3() {
+	_vm->_screen->forceFadeOut();
+	_vm->_events->hideCursor();
+	_vm->_files->loadScreen(57, 3);
+	_vm->_buffer2.copyFrom(*_vm->_screen);
+
+	_vm->_screen->setIconPalette();
+	_vm->_events->showCursor();
+	_vm->_screen->forceFadeIn();
+}
+
+void MartianScripts::doIntro(int param1) {
 	_game->doSpecial5(param1);
 }
 
@@ -50,13 +61,13 @@ void MartianScripts::executeSpecial(int commandIndex, int param1, int param2) {
 		warning("TODO: cmdSpecial2");
 		break;
 	case 3:
-		warning("TODO: cmdSpecial3");
+		cmdSpecial3();
 		break;
 	case 4:
 		warning("TODO: cmdSpecial4");
 		break;
 	case 5:
-		cmdSpecial5(param1);
+		doIntro(param1);
 		break;
 	case 6:
 		warning("TODO: cmdSpecial6");
diff --git a/engines/access/martian/martian_scripts.h b/engines/access/martian/martian_scripts.h
index 125f1e4..9e9c3b6 100644
--- a/engines/access/martian/martian_scripts.h
+++ b/engines/access/martian/martian_scripts.h
@@ -36,7 +36,8 @@ class MartianScripts : public Scripts {
 private:
 	MartianEngine *_game;
 
-	void cmdSpecial5(int param1);
+	void cmdSpecial3();
+	void doIntro(int param1);
 
 protected:
 	virtual void executeSpecial(int commandIndex, int param1, int param2);


Commit: e85788ffdce741c90ac8a6cfc9b1bee298c4c269
    https://github.com/scummvm/scummvm/commit/e85788ffdce741c90ac8a6cfc9b1bee298c4c269
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-26T07:58:59+01:00

Commit Message:
ACCESS: MM - Some work on bubble_box

Changed paths:
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h
    engines/access/scripts.cpp



diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index 0fb39c9..3d1eacb 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -90,10 +90,7 @@ void BubbleBox::placeBubble1(const Common::String &msg) {
 	Common::Rect r = _bubbles[0];
 	r.translate(-2, 0);
 	_vm->_screen->saveBlock(r);
-	if (_vm->getGameID() == GType_MartianMemorandum)
-		printBubble_v1(msg);
-	else
-		printBubble_v2(msg);
+	printBubble(msg);
 }
 
 void BubbleBox::calcBubble(const Common::String &msg) {
@@ -152,6 +149,13 @@ void BubbleBox::calcBubble(const Common::String &msg) {
 	_vm->_screen->_printStart = printStart;
 }
 
+void BubbleBox::printBubble(const Common::String &msg) {
+	if (_vm->getGameID() == GType_MartianMemorandum)
+		printBubble_v1(msg);
+	else
+		printBubble_v2(msg);
+}
+
 void BubbleBox::printBubble_v1(const Common::String &msg) {
 	drawBubble(_bubbles.size() - 1);
 	
@@ -333,10 +337,8 @@ void BubbleBox::PRINTSTR(Common::String msg) {
 void BubbleBox::displayBoxData() {
 	_vm->BOXDATAEND = false;
 	_rowOff = 2;
-	_vm->_fonts._charSet._lo = 7;  // 0xF7
-	_vm->_fonts._charSet._hi = 15;
-	_vm->_fonts._charFor._lo = 15; // 0xFF
-	_vm->_fonts._charFor._hi = 15;
+	_vm->_fonts._charFor._lo = 0xF7;
+	_vm->_fonts._charFor._hi = 0xFF;
 
 	if (_tempList[0].size() == 0)
 		return;
@@ -582,13 +584,9 @@ int BubbleBox::doBox_v1(int item, int box, int &btnSelected) {
 	_rowOff = bp;
 	retval_ = BOXPSTARTY = newY;
 
-	
-	// setcursorpos
-	_vm->_screen->_printOrg.y = _vm->_screen->_printStart.y = (newY << 3) + _rowOff;
-	_vm->_screen->_printOrg.x = _vm->_screen->_printStart.x = (newX << 3);
-	//
+	SETCURSORPOS(newX, newY);
 
-	_vm->_fonts._charFor._lo = -1;
+	_vm->_fonts._charFor._lo = 0xFF;
 	_vm->_fonts._font1.drawString(_vm->_screen, _bubbleDisplStr, _vm->_screen->_printOrg);
 
 	if (_type == TYPE_2) {
@@ -727,7 +725,7 @@ int BubbleBox::doBox_v1(int item, int box, int &btnSelected) {
 			if ((_vm->_events->_mousePos.y < tmpY) || (_vm->_events->_mousePos.y > tmpY + 8))
 				continue;
 
-			warning("TODO: sub175B5");
+			warning("TODO: sub175B5 - List of files");
 		}
 	}
 
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index 26cda6c..d279ed1 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -50,6 +50,11 @@ private:
 
 	void displayBoxData();
 	void drawSelectBox();
+	/**
+	 * Prints a text bubble and it's contents
+	 */
+	void printBubble_v1(const Common::String &msg);
+	void printBubble_v2(const Common::String &msg);
 
 public:
 	BoxType _type;
@@ -87,8 +92,7 @@ public:
 	/**
 	 * Prints a text bubble and it's contents
 	 */
-	void printBubble_v1(const Common::String &msg);
-	void printBubble_v2(const Common::String &msg);
+	void printBubble(const Common::String &msg);
 
 	/*
 	 * Draws the background for a text bubble
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index d15f293..7d21c0e 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -813,19 +813,30 @@ void Scripts::cmdTexSpeak() {
 
 #define BTN_COUNT 6
 void Scripts::cmdTexChoice() {
-	static const int BTN_RANGES[BTN_COUNT][2] = {
-		{ 0, 76 }, { 77, 154 }, { 155, 232 }, { 233, 276 }, { 0, 0 },
-		{ 277, 319 }
+	// MM is defining 2 times the last range in the original.
+	static const int BTN_RANGES_v1[BTN_COUNT][2] = {
+		{ 0, 60 }, { 64, 124 }, { 129, 192 }, { 194, 227 }, { 233, 292 }, { 297, 319 }
 	};
 
+	static const int BTN_RANGES_v2[BTN_COUNT][2] = {
+		{ 0, 76 }, { 77, 154 }, { 155, 232 }, { 233, 276 }, { 0, 0 }, { 277, 319 }
+	};
+
+
 	_vm->_oldRects.clear();
 	_choiceStart = _data->pos() - 1;
 	_vm->_fonts._charSet._lo = 1;
 	_vm->_fonts._charSet._hi = 8;
-	_vm->_fonts._charFor._lo = 55;
 	_vm->_fonts._charFor._hi = 255;
+	
+	if (_vm->getGameID() == GType_MartianMemorandum) {
+		_vm->_fonts._charFor._lo = 247;
+		_vm->_screen->_maxChars = 23;
+	} else {
+		_vm->_fonts._charFor._lo = 55;
+		_vm->_screen->_maxChars = 20;
+	}
 
-	_vm->_screen->_maxChars = 20;
 	_vm->_screen->_printOrg = _texsOrg;
 	_vm->_screen->_printStart = _texsOrg;
 
@@ -838,11 +849,11 @@ void Scripts::cmdTexChoice() {
 		tmpStr += (char)v;
 
 	_vm->_bubbleBox->calcBubble(tmpStr);
-	_vm->_bubbleBox->printBubble_v2(tmpStr);
+	_vm->_bubbleBox->printBubble(tmpStr);
 
 	Common::Array<Common::Rect> responseCoords;
 	responseCoords.push_back(_vm->_bubbleBox->_bounds);
-	_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + 11;
+	_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + (_vm->getGameID() == GType_MartianMemorandum) ? 20 : 11;
 
 	findNull();
 
@@ -853,9 +864,9 @@ void Scripts::cmdTexChoice() {
 	if (tmpStr.size() != 0) {
 		_vm->_bubbleBox->_bubbleDisplStr = Common::String("RESPONSE 2");
 		_vm->_bubbleBox->calcBubble(tmpStr);
-		_vm->_bubbleBox->printBubble_v2(tmpStr);
+		_vm->_bubbleBox->printBubble(tmpStr);
 		responseCoords.push_back(_vm->_bubbleBox->_bounds);
-		_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + 11;
+		_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + (_vm->getGameID() == GType_MartianMemorandum) ? 20 : 11;
 	}
 
 	findNull();
@@ -868,9 +879,9 @@ void Scripts::cmdTexChoice() {
 	if (tmpStr.size() != 0) {
 		_vm->_bubbleBox->_bubbleDisplStr = Common::String("RESPONSE 3");
 		_vm->_bubbleBox->calcBubble(tmpStr);
-		_vm->_bubbleBox->printBubble_v2(tmpStr);
+		_vm->_bubbleBox->printBubble(tmpStr);
 		responseCoords.push_back(_vm->_bubbleBox->_bounds);
-		_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + 11;
+		_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + (_vm->getGameID() == GType_MartianMemorandum) ? 20 : 11;
 	}
 
 	findNull();
@@ -885,11 +896,13 @@ void Scripts::cmdTexChoice() {
 
 		_vm->_bubbleBox->_bubbleDisplStr = _vm->_bubbleBox->_bubbleTitle;
 		if (_vm->_events->_leftButton) {
-			if (_vm->_events->_mouseRow >= 22) {
+			if (_vm->_events->_mouseRow >= (_vm->getGameID() == GType_MartianMemorandum) ? 23 : 22) {
 				_vm->_events->debounceLeft();
 				int x = _vm->_events->_mousePos.x;
 				for (int i = 0; i < BTN_COUNT; i++) {
-					if ((x >= BTN_RANGES[i][0]) && (x < BTN_RANGES[i][1])) {
+					if (((_vm->getGameID() == GType_MartianMemorandum) && (x >= BTN_RANGES_v1[i][0]) && (x < BTN_RANGES_v1[i][1])) 
+					||  ((_vm->getGameID() == GType_Amazon) && (x >= BTN_RANGES_v2[i][0]) && (x < BTN_RANGES_v2[i][1]))) {
+
 						choice = i;
 						break;
 					}


Commit: 817730c360b174bffe7e49f2e5d00ac19bc820bb
    https://github.com/scummvm/scummvm/commit/817730c360b174bffe7e49f2e5d00ac19bc820bb
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-30T07:10:54+01:00

Commit Message:
ACCESS: MM - Implement missing bits of CharEntry

Changed paths:
    engines/access/char.cpp



diff --git a/engines/access/char.cpp b/engines/access/char.cpp
index d2b1aa6..b3b026b 100644
--- a/engines/access/char.cpp
+++ b/engines/access/char.cpp
@@ -31,17 +31,12 @@ CharEntry::CharEntry(const byte *data, AccessEngine *vm) {
 	Common::MemoryReadStream s(data, 999);
 
 	_charFlag = s.readByte();
-	if (vm->getGameID() == GType_MartianMemorandum)
-		_estabIndex = -1;
-	else
-		_estabIndex = s.readSint16LE();
-
-	_screenFile.load(s);
-
 	if (vm->getGameID() == GType_MartianMemorandum) {
-		int idx = s.readSint16LE();
-		if (idx != -1)
-			warning("TODO: more CharEntry");
+		_screenFile.load(s);
+		_estabIndex = s.readSint16LE();
+	} else {
+		_estabIndex = s.readSint16LE();
+		_screenFile.load(s);
 	}
 
 	_paletteFile.load(s);


Commit: 417660171846b6ce9686d5aed474499350e2c59e
    https://github.com/scummvm/scummvm/commit/417660171846b6ce9686d5aed474499350e2c59e
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-30T07:11:55+01:00

Commit Message:
ACCESS: MM - Add MM specific code in doEstablish

Changed paths:
    engines/access/amazon/amazon_game.cpp



diff --git a/engines/access/amazon/amazon_game.cpp b/engines/access/amazon/amazon_game.cpp
index 933a98a..ac3a932 100644
--- a/engines/access/amazon/amazon_game.cpp
+++ b/engines/access/amazon/amazon_game.cpp
@@ -253,13 +253,24 @@ void AmazonEngine::doEstablish(int screenId, int estabIndex) {
 	_screen->setIconPalette();
 	_screen->forceFadeIn();
 
-	_fonts._charSet._lo = 1;
-	_fonts._charSet._hi = 10;
-	_fonts._charFor._lo = 29;
-	_fonts._charFor._hi = 32;
+	if (getGameID() == GType_MartianMemorandum) {
+		_fonts._charSet._lo = 1;
+		_fonts._charSet._hi = 10;
+		_fonts._charFor._lo = 0xF7;
+		_fonts._charFor._hi = 0xFF;
+
+		_screen->_maxChars = 50;
+		_screen->_printOrg = _screen->_printStart = Common::Point(24, 18);
+	} else {
+		_fonts._charSet._lo = 1;
+		_fonts._charSet._hi = 10;
+		_fonts._charFor._lo = 29;
+		_fonts._charFor._hi = 32;
+
+		_screen->_maxChars = 37;
+		_screen->_printOrg = _screen->_printStart = Common::Point(48, 35);
+	}
 
-	_screen->_maxChars = 37;
-	_screen->_printOrg = _screen->_printStart = Common::Point(48, 35);
 	loadEstablish(estabIndex);
 	_et = estabIndex;
 	uint16 msgOffset;


Commit: 49d06c139867b3776832270002f1bfb07ceebd30
    https://github.com/scummvm/scummvm/commit/49d06c139867b3776832270002f1bfb07ceebd30
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-30T07:15:14+01:00

Commit Message:
ACCESS: Silent a MSVC warning

Changed paths:
    engines/access/scripts.cpp



diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 7d21c0e..ce11092 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -896,7 +896,7 @@ void Scripts::cmdTexChoice() {
 
 		_vm->_bubbleBox->_bubbleDisplStr = _vm->_bubbleBox->_bubbleTitle;
 		if (_vm->_events->_leftButton) {
-			if (_vm->_events->_mouseRow >= (_vm->getGameID() == GType_MartianMemorandum) ? 23 : 22) {
+			if (_vm->_events->_mouseRow >= ((_vm->getGameID() == GType_MartianMemorandum) ? 23 : 22)) {
 				_vm->_events->debounceLeft();
 				int x = _vm->_events->_mousePos.x;
 				for (int i = 0; i < BTN_COUNT; i++) {


Commit: 576ad394f33a3ce923057007f51b7abfa5c8e277
    https://github.com/scummvm/scummvm/commit/576ad394f33a3ce923057007f51b7abfa5c8e277
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-30T07:15:46+01:00

Commit Message:
ACCESS: Remove a useless variable

Changed paths:
    engines/access/access.h
    engines/access/amazon/amazon_game.cpp



diff --git a/engines/access/access.h b/engines/access/access.h
index 844b824..2a2d48e 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -194,7 +194,6 @@ public:
 	bool _canSaveLoad;
 
 	Resource *_establish;
-	int _et;
 	int _printEnd;
 	int _txtPages;
 	int _narateFile;
diff --git a/engines/access/amazon/amazon_game.cpp b/engines/access/amazon/amazon_game.cpp
index ac3a932..b469cf5 100644
--- a/engines/access/amazon/amazon_game.cpp
+++ b/engines/access/amazon/amazon_game.cpp
@@ -272,7 +272,6 @@ void AmazonEngine::doEstablish(int screenId, int estabIndex) {
 	}
 
 	loadEstablish(estabIndex);
-	_et = estabIndex;
 	uint16 msgOffset;
 	if (!isCD())
 		msgOffset = READ_LE_UINT16(_establish->data() + (estabIndex * 2));


Commit: 38f7aba41464d2c7b623f1ce4616d89c4243352a
    https://github.com/scummvm/scummvm/commit/38f7aba41464d2c7b623f1ce4616d89c4243352a
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-30T07:24:22+01:00

Commit Message:
ACCESS: MM - Remove a couple of useless variables

Changed paths:
    engines/access/bubble_box.cpp



diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index 3d1eacb..d3254d4 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -604,10 +604,8 @@ int BubbleBox::doBox_v1(int item, int box, int &btnSelected) {
 	int ICON1Y = 0;
 	int ICON2T = 0;
 	int ICON2X = 0;
-	int ICON2Y = 0;
 	int ICON3T = 0;
 	int ICON3X = 0;
-	int ICON3Y = 0;
 	if (_btnId1) {
 		ICON1T = _btnId1;
 		ICON1X = BICONSTARTX + _btnX1;
@@ -617,14 +615,12 @@ int BubbleBox::doBox_v1(int item, int box, int &btnSelected) {
 		if (_btnId2) {
 			ICON2T = _btnId2;
 			ICON2X = BICONSTARTX + _btnX2;
-			ICON2Y = BICONSTARTY;
-			_vm->_screen->plotImage(icons, ICON2T + 10, Common::Point(ICON2X, ICON2Y));
+			_vm->_screen->plotImage(icons, ICON2T + 10, Common::Point(ICON2X, BICONSTARTY));
 
 			if (_btnId3) {
 				ICON3T = _btnId3;
 				ICON3X = BICONSTARTX + _btnX3;
-				ICON3Y = BICONSTARTY;
-				_vm->_screen->plotImage(icons, ICON3T + 10, Common::Point(ICON3X, ICON3Y));
+				_vm->_screen->plotImage(icons, ICON3T + 10, Common::Point(ICON3X, BICONSTARTY));
 			}
 		}
 	}


Commit: 5159a3851b801229dd16bfcc1c4a6662f8d21ad0
    https://github.com/scummvm/scummvm/commit/5159a3851b801229dd16bfcc1c4a6662f8d21ad0
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-30T07:26:39+01:00

Commit Message:
ACCESS: Clarify calculation precedence for '+' and '?'

Changed paths:
    engines/access/scripts.cpp



diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index ce11092..53d219d 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -853,7 +853,7 @@ void Scripts::cmdTexChoice() {
 
 	Common::Array<Common::Rect> responseCoords;
 	responseCoords.push_back(_vm->_bubbleBox->_bounds);
-	_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + (_vm->getGameID() == GType_MartianMemorandum) ? 20 : 11;
+	_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + ((_vm->getGameID() == GType_MartianMemorandum) ? 20 : 11);
 
 	findNull();
 
@@ -866,7 +866,7 @@ void Scripts::cmdTexChoice() {
 		_vm->_bubbleBox->calcBubble(tmpStr);
 		_vm->_bubbleBox->printBubble(tmpStr);
 		responseCoords.push_back(_vm->_bubbleBox->_bounds);
-		_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + (_vm->getGameID() == GType_MartianMemorandum) ? 20 : 11;
+		_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + ((_vm->getGameID() == GType_MartianMemorandum) ? 20 : 11);
 	}
 
 	findNull();
@@ -881,7 +881,7 @@ void Scripts::cmdTexChoice() {
 		_vm->_bubbleBox->calcBubble(tmpStr);
 		_vm->_bubbleBox->printBubble(tmpStr);
 		responseCoords.push_back(_vm->_bubbleBox->_bounds);
-		_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + (_vm->getGameID() == GType_MartianMemorandum) ? 20 : 11;
+		_vm->_screen->_printOrg.y = _vm->_bubbleBox->_bounds.bottom + ((_vm->getGameID() == GType_MartianMemorandum) ? 20 : 11);
 	}
 
 	findNull();


Commit: 490eb341fa2ad0a13f599862dab565a1b3612677
    https://github.com/scummvm/scummvm/commit/490eb341fa2ad0a13f599862dab565a1b3612677
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-30T07:28:57+01:00

Commit Message:
ACCESS: MM - Reduce the scope of a variable, some renaming

Changed paths:
    engines/access/martian/martian_game.cpp



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index fce115f..c386c54 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -209,27 +209,26 @@ bool MartianEngine::showCredits() {
 	_screen->clearScreen();
 	_destIn = _screen;
 
-	int val1 = _creditsStream->readSint16LE();
-	int val2 = 0;
-	int val3 = 0;
+	int posX = _creditsStream->readSint16LE();
+	int posY = 0;
 
-	while(val1 != -1) {
-		val2 = _creditsStream->readSint16LE();
-		val3 = _creditsStream->readSint16LE();
-		_screen->plotImage(_introObjects, val3, Common::Point(val1, val2));
+	while(posX != -1) {
+		posY = _creditsStream->readSint16LE();
+		int frameNum = _creditsStream->readSint16LE();
+		_screen->plotImage(_introObjects, frameNum, Common::Point(posX, posY));
 
-		val1 = _creditsStream->readSint16LE();
+		posX = _creditsStream->readSint16LE();
 	}
 
-	val2 = _creditsStream->readSint16LE();
-	if (val2 == -1) {
+	posY = _creditsStream->readSint16LE();
+	if (posY == -1) {
 		_events->showCursor();
 		_screen->forceFadeOut();
 		return true;
 	}
 
 	_screen->forceFadeIn();
-	_timers[3]._timer = _timers[3]._initTm = val2;
+	_timers[3]._timer = _timers[3]._initTm = posY;
 
 	while (!shouldQuit() && !_events->isKeyMousePressed() && _timers[3]._timer) {
 		_events->pollEventsAndWait();


Commit: 4cd155c9a867ae55f390f0207a2896da2898bb13
    https://github.com/scummvm/scummvm/commit/4cd155c9a867ae55f390f0207a2896da2898bb13
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-31T22:37:16+01:00

Commit Message:
ACCESS: MM - Implement cmdSpecial1

Changed paths:
    engines/access/martian/martian_scripts.cpp
    engines/access/martian/martian_scripts.h



diff --git a/engines/access/martian/martian_scripts.cpp b/engines/access/martian/martian_scripts.cpp
index bb8230e..3907e5c 100644
--- a/engines/access/martian/martian_scripts.cpp
+++ b/engines/access/martian/martian_scripts.cpp
@@ -34,6 +34,19 @@ MartianScripts::MartianScripts(AccessEngine *vm) : Scripts(vm) {
 	_game = (MartianEngine *)_vm;
 }
 
+void MartianScripts::cmdSpecial1(int param1) {
+	_vm->_events->hideCursor();
+	
+	if (param1 != -1) {
+		_vm->_files->loadScreen(49, param1);
+		_vm->_buffer2.copyBuffer(_vm->_screen);
+	}
+
+	_vm->_screen->setIconPalette();
+	_vm->_screen->forceFadeIn();
+	_vm->_events->showCursor();
+}
+
 void MartianScripts::cmdSpecial3() {
 	_vm->_screen->forceFadeOut();
 	_vm->_events->hideCursor();
@@ -55,7 +68,7 @@ void MartianScripts::executeSpecial(int commandIndex, int param1, int param2) {
 		warning("TODO: cmdSpecial0");
 		break;
 	case 1:
-		warning("TODO: cmdSpecial1");
+		cmdSpecial1(param1);
 		break;
 	case 2:
 		warning("TODO: cmdSpecial2");
@@ -72,6 +85,9 @@ void MartianScripts::executeSpecial(int commandIndex, int param1, int param2) {
 	case 6:
 		warning("TODO: cmdSpecial6");
 		break;
+	case 7:
+		warning("TODO: cmdSpecial7");
+		break;
 	default:
 		warning("Unexpected Special code %d - Skipped", commandIndex);
 	}
diff --git a/engines/access/martian/martian_scripts.h b/engines/access/martian/martian_scripts.h
index 9e9c3b6..64b888f 100644
--- a/engines/access/martian/martian_scripts.h
+++ b/engines/access/martian/martian_scripts.h
@@ -36,6 +36,7 @@ class MartianScripts : public Scripts {
 private:
 	MartianEngine *_game;
 
+	void cmdSpecial1(int param1);
 	void cmdSpecial3();
 	void doIntro(int param1);
 


Commit: e0a9c92ccd1d9fb531f9c1c5ad8281aa1339f2fd
    https://github.com/scummvm/scummvm/commit/e0a9c92ccd1d9fb531f9c1c5ad8281aa1339f2fd
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-01-31T22:42:46+01:00

Commit Message:
ACCESS: Split setVideo into 2 functions to allow the loading of files out of a container

Changed paths:
    engines/access/video.cpp
    engines/access/video.h



diff --git a/engines/access/video.cpp b/engines/access/video.cpp
index b7d5652..70d6ac6 100644
--- a/engines/access/video.cpp
+++ b/engines/access/video.cpp
@@ -37,17 +37,13 @@ VideoPlayer::~VideoPlayer() {
 	closeVideo();
 }
 
-
-void VideoPlayer::setVideo(ASurface *vidSurface, const Common::Point &pt, const FileIdent &videoFile, int rate) {
+void VideoPlayer::setVideo(ASurface *vidSurface, const Common::Point &pt, int rate) {
 	_vidSurface = vidSurface;
 	vidSurface->_orgX1 = pt.x;
 	vidSurface->_orgY1 = pt.y;
 	_vm->_timers[31]._timer = rate;
 	_vm->_timers[31]._initTm = rate;
 
-	// Open up video stream
-	_videoData = _vm->_files->loadFile(videoFile);
-
 	// Load in header
 	_header._frameCount = _videoData->_stream->readUint16LE();
 	_header._width = _videoData->_stream->readUint16LE();
@@ -80,6 +76,20 @@ void VideoPlayer::setVideo(ASurface *vidSurface, const Common::Point &pt, const
 	_videoEnd = false;
 }
 
+void VideoPlayer::setVideo(ASurface *vidSurface, const Common::Point &pt, const Common::String filename, int rate) {
+	// Open up video stream
+	_videoData = _vm->_files->loadFile(filename);
+
+	setVideo(vidSurface, pt, rate);
+}
+
+void VideoPlayer::setVideo(ASurface *vidSurface, const Common::Point &pt, const FileIdent &videoFile, int rate) {
+	// Open up video stream
+	_videoData = _vm->_files->loadFile(videoFile);
+	
+	setVideo(vidSurface, pt, rate);
+}
+
 void VideoPlayer::closeVideo() {
 	delete _videoData;
 	_videoData = nullptr;
diff --git a/engines/access/video.h b/engines/access/video.h
index 17825db..83c8995 100644
--- a/engines/access/video.h
+++ b/engines/access/video.h
@@ -51,6 +51,7 @@ private:
 	Common::Rect _videoBounds;
 
 	void getFrame();
+	void setVideo(ASurface *vidSurface, const Common::Point &pt, int rate);
 public:
 	int _videoFrame;
 	bool _soundFlag;
@@ -64,6 +65,7 @@ public:
 	 * Start up a video
 	 */
 	void setVideo(ASurface *vidSurface, const Common::Point &pt, const FileIdent &videoFile, int rate);
+	void setVideo(ASurface *vidSurface, const Common::Point &pt, const Common::String filename, int rate);
 
 	/**
 	 * Decodes a frame of the video


Commit: 631277e486f1903a6f233cb8bfaacad84d8362bb
    https://github.com/scummvm/scummvm/commit/631277e486f1903a6f233cb8bfaacad84d8362bb
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-01T07:31:34+01:00

Commit Message:
ACCESS: MM - Implement cmdSpecial6

Changed paths:
    engines/access/martian/martian_scripts.cpp
    engines/access/martian/martian_scripts.h



diff --git a/engines/access/martian/martian_scripts.cpp b/engines/access/martian/martian_scripts.cpp
index 3907e5c..2d1a483 100644
--- a/engines/access/martian/martian_scripts.cpp
+++ b/engines/access/martian/martian_scripts.cpp
@@ -62,6 +62,71 @@ void MartianScripts::doIntro(int param1) {
 	_game->doSpecial5(param1);
 }
 
+void MartianScripts::sub13D10(Common::String msg) {
+	warning("TODO: Rename sub13d10");
+	Common::String line = "";
+	int width = 0;
+	bool lastLine;
+	do {
+		lastLine = _vm->_fonts._font2.getLine(msg, _vm->_screen->_maxChars * 6, line, width);
+		warning("TODO: use printString");
+		// Draw the text
+		_vm->_fonts._font2.drawString(_vm->_screen, line, _vm->_screen->_printOrg);
+
+		_vm->_screen->_printOrg.y += 6;
+		_vm->_screen->_printOrg.x = _vm->_screen->_printStart.x;
+
+		if (_vm->_screen->_printOrg.y == 180) {
+			_vm->_events->waitKeyMouse();
+			_vm->_screen->copyBuffer(&_vm->_buffer2);
+			_vm->_screen->_printOrg.y = _vm->_screen->_printStart.y;
+		}
+	} while (!lastLine);
+	_vm->_events->waitKeyMouse();
+}
+
+void MartianScripts::cmdSpecial6() {
+	_vm->_midi->stopSong();
+	_vm->_screen->setDisplayScan();
+	_vm->_events->clearEvents();
+	_vm->_screen->forceFadeOut();
+	_vm->_events->hideCursor();
+	_vm->_files->loadScreen(49, 9);
+	_vm->_events->showCursor();
+	_vm->_screen->setIconPalette();
+	_vm->_screen->forceFadeIn();
+
+	Resource *cellsRes = _vm->_files->loadFile("CELLS00.LZ");
+	_vm->_objectsTable[0] = new SpriteResource(_vm, cellsRes);
+	delete cellsRes;
+
+	_vm->_timers[20]._timer = _vm->_timers[20]._initTm = 30;
+	_vm->_fonts._charSet._lo = 1;
+	_vm->_fonts._charSet._hi = 10;
+	_vm->_fonts._charFor._lo = 1;
+	_vm->_fonts._charFor._hi = 255;
+
+	_vm->_screen->_maxChars = 50;
+	_vm->_screen->_printOrg = _vm->_screen->_printStart = Common::Point(24, 18);
+
+	Resource *notesRes = _vm->_files->loadFile("ETEXT.DAT");
+	notesRes->_stream->seek(72);
+
+	// Read the message
+	Common::String msg = "";
+	byte c;
+	while ((c = (char)notesRes->_stream->readByte()) != '\0')
+		msg += c;
+
+	//display the message
+	sub13D10(msg);
+
+	delete notesRes;
+	delete _vm->_objectsTable[0];
+	_vm->_objectsTable[0] = nullptr;
+	_vm->_midi->stopSong();
+}
+
 void MartianScripts::executeSpecial(int commandIndex, int param1, int param2) {
 	switch (commandIndex) {
 	case 0:
diff --git a/engines/access/martian/martian_scripts.h b/engines/access/martian/martian_scripts.h
index 64b888f..365c0ec 100644
--- a/engines/access/martian/martian_scripts.h
+++ b/engines/access/martian/martian_scripts.h
@@ -36,9 +36,12 @@ class MartianScripts : public Scripts {
 private:
 	MartianEngine *_game;
 
+	void sub13D10(Common::String msg);
+
 	void cmdSpecial1(int param1);
 	void cmdSpecial3();
 	void doIntro(int param1);
+	void cmdSpecial6();
 
 protected:
 	virtual void executeSpecial(int commandIndex, int param1, int param2);


Commit: 26d86017c7cf44e81758634893c8168bda1c9f9d
    https://github.com/scummvm/scummvm/commit/26d86017c7cf44e81758634893c8168bda1c9f9d
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-01T07:59:18+01:00

Commit Message:
ACCESS: MM - Implement dead function

Changed paths:
    engines/access/martian/martian_game.cpp
    engines/access/martian/martian_game.h
    engines/access/martian/martian_scripts.cpp
    engines/access/martian/martian_scripts.h



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index c386c54..5ec1ede 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -278,6 +278,12 @@ void MartianEngine::doCredits() {
 }
 
 void MartianEngine::setupGame() {
+	// Load death list
+	_deaths.resize(20);
+	for (int i = 0; i < 20; ++i) {
+		_deaths[i]._screenId = Martian::DEATH_SCREENS[i];
+		_deaths[i]._msg = Martian::DEATHMESSAGE[i];
+	}
 
 	// Setup timers
 	const int TIMER_DEFAULTS[] = { 4, 10, 8, 1, 1, 1, 1, 2 };
@@ -304,6 +310,60 @@ void MartianEngine::drawHelp() {
 	error("TODO: drawHelp");
 }
 
+void MartianEngine::sub13D10(Common::String msg) {
+	warning("TODO: Rename sub13d10");
+	Common::String line = "";
+	int width = 0;
+	bool lastLine;
+	do {
+		lastLine = _fonts._font2.getLine(msg, _screen->_maxChars * 6, line, width);
+		warning("TODO: use printString");
+		// Draw the text
+		_fonts._font2.drawString(_screen, line, _screen->_printOrg);
+
+		_screen->_printOrg.y += 6;
+		_screen->_printOrg.x = _screen->_printStart.x;
+
+		if (_screen->_printOrg.y == 180) {
+			_events->waitKeyMouse();
+			_screen->copyBuffer(&_buffer2);
+			_screen->_printOrg.y = _screen->_printStart.y;
+		}
+	} while (!lastLine);
+	_events->waitKeyMouse();
+}
+
+void MartianEngine::dead(int deathId) {
+	// Load and display death screen
+	_events->hideCursor();
+	_screen->forceFadeOut();
+	_files->loadScreen(48, _deaths[deathId]._screenId);
+	_screen->setIconPalette();
+	_buffer2.copyBuffer(_screen);
+	_screen->forceFadeIn();
+	_events->showCursor();
+
+	// Setup fonts
+	_fonts._charSet._hi = 10;
+	_fonts._charSet._lo = 1;
+	_fonts._charFor._lo = 247;
+	_fonts._charFor._hi = 255;
+	_screen->_maxChars = 50;
+	_screen->_printOrg = Common::Point(24, 18);
+	_screen->_printStart = Common::Point(24, 18);
+	
+	// Display death message
+	sub13D10(_deaths[deathId]._msg);
+	
+	_screen->forceFadeOut();
+	_room->clearRoom();
+	freeChar();
+
+	// The original was jumping to the restart label in main
+	_restartFl = true;
+	_events->pollEvents();
+}
+
 } // End of namespace Martian
 
 } // End of namespace Access
diff --git a/engines/access/martian/martian_game.h b/engines/access/martian/martian_game.h
index 155642a..7954948 100644
--- a/engines/access/martian/martian_game.h
+++ b/engines/access/martian/martian_game.h
@@ -55,7 +55,7 @@ protected:
 	 */
 	virtual void playGame();
 
-	virtual void dead(int deathId) {}
+	virtual void dead(int deathId);
 
 	void setNoteParams();
 	void displayNote(const Common::String &msg);
@@ -65,6 +65,7 @@ public:
 
 	void doSpecial5(int param1);
 	void drawHelp();
+	void sub13D10(Common::String msg);
 	virtual void establish(int esatabIndex, int sub) {};
 };
 
diff --git a/engines/access/martian/martian_scripts.cpp b/engines/access/martian/martian_scripts.cpp
index 2d1a483..01016b5 100644
--- a/engines/access/martian/martian_scripts.cpp
+++ b/engines/access/martian/martian_scripts.cpp
@@ -62,29 +62,6 @@ void MartianScripts::doIntro(int param1) {
 	_game->doSpecial5(param1);
 }
 
-void MartianScripts::sub13D10(Common::String msg) {
-	warning("TODO: Rename sub13d10");
-	Common::String line = "";
-	int width = 0;
-	bool lastLine;
-	do {
-		lastLine = _vm->_fonts._font2.getLine(msg, _vm->_screen->_maxChars * 6, line, width);
-		warning("TODO: use printString");
-		// Draw the text
-		_vm->_fonts._font2.drawString(_vm->_screen, line, _vm->_screen->_printOrg);
-
-		_vm->_screen->_printOrg.y += 6;
-		_vm->_screen->_printOrg.x = _vm->_screen->_printStart.x;
-
-		if (_vm->_screen->_printOrg.y == 180) {
-			_vm->_events->waitKeyMouse();
-			_vm->_screen->copyBuffer(&_vm->_buffer2);
-			_vm->_screen->_printOrg.y = _vm->_screen->_printStart.y;
-		}
-	} while (!lastLine);
-	_vm->_events->waitKeyMouse();
-}
-
 void MartianScripts::cmdSpecial6() {
 	_vm->_midi->stopSong();
 	_vm->_screen->setDisplayScan();
@@ -119,7 +96,7 @@ void MartianScripts::cmdSpecial6() {
 		msg += c;
 
 	//display the message
-	sub13D10(msg);
+	_game->sub13D10(msg);
 
 	delete notesRes;
 	delete _vm->_objectsTable[0];
diff --git a/engines/access/martian/martian_scripts.h b/engines/access/martian/martian_scripts.h
index 365c0ec..9a80558 100644
--- a/engines/access/martian/martian_scripts.h
+++ b/engines/access/martian/martian_scripts.h
@@ -36,8 +36,6 @@ class MartianScripts : public Scripts {
 private:
 	MartianEngine *_game;
 
-	void sub13D10(Common::String msg);
-
 	void cmdSpecial1(int param1);
 	void cmdSpecial3();
 	void doIntro(int param1);


Commit: 798733c15a4bffb12d3f048ca221b57f4a083353
    https://github.com/scummvm/scummvm/commit/798733c15a4bffb12d3f048ca221b57f4a083353
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-03T07:00:32+01:00

Commit Message:
ACCESS: MM - Remove a useless function, rename showDeathText

Changed paths:
    engines/access/martian/martian_game.cpp
    engines/access/martian/martian_game.h



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index 5ec1ede..e3784e2 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -306,12 +306,7 @@ void MartianEngine::setupGame() {
 	_player->_playerY = _player->_rawPlayer.y = TRAVEL_POS[_player->_roomNumber][1];
 }
 
-void MartianEngine::drawHelp() {
-	error("TODO: drawHelp");
-}
-
-void MartianEngine::sub13D10(Common::String msg) {
-	warning("TODO: Rename sub13d10");
+void MartianEngine::showDeathText(Common::String msg) {
 	Common::String line = "";
 	int width = 0;
 	bool lastLine;
@@ -353,7 +348,7 @@ void MartianEngine::dead(int deathId) {
 	_screen->_printStart = Common::Point(24, 18);
 	
 	// Display death message
-	sub13D10(_deaths[deathId]._msg);
+	showDeathText(_deaths[deathId]._msg);
 	
 	_screen->forceFadeOut();
 	_room->clearRoom();
diff --git a/engines/access/martian/martian_game.h b/engines/access/martian/martian_game.h
index 7954948..c324ef5 100644
--- a/engines/access/martian/martian_game.h
+++ b/engines/access/martian/martian_game.h
@@ -64,8 +64,7 @@ public:
 	virtual ~MartianEngine();
 
 	void doSpecial5(int param1);
-	void drawHelp();
-	void sub13D10(Common::String msg);
+	void showDeathText(Common::String msg);
 	virtual void establish(int esatabIndex, int sub) {};
 };
 


Commit: 4ab79fa060c3a621c63ce35def837e6d5217cb53
    https://github.com/scummvm/scummvm/commit/4ab79fa060c3a621c63ce35def837e6d5217cb53
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-03T07:05:14+01:00

Commit Message:
ACCESS: MM - Hook cmdSpecial6

Changed paths:
    engines/access/martian/martian_scripts.cpp



diff --git a/engines/access/martian/martian_scripts.cpp b/engines/access/martian/martian_scripts.cpp
index 01016b5..1fb5991 100644
--- a/engines/access/martian/martian_scripts.cpp
+++ b/engines/access/martian/martian_scripts.cpp
@@ -125,7 +125,7 @@ void MartianScripts::executeSpecial(int commandIndex, int param1, int param2) {
 		doIntro(param1);
 		break;
 	case 6:
-		warning("TODO: cmdSpecial6");
+		cmdSpecial6();
 		break;
 	case 7:
 		warning("TODO: cmdSpecial7");


Commit: af664130da2f08c7f71073284a4a91bbefbfbdb6
    https://github.com/scummvm/scummvm/commit/af664130da2f08c7f71073284a4a91bbefbfbdb6
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-03T07:32:43+01:00

Commit Message:
ACCESS: MM - Remove combine item feature and table

Changed paths:
    engines/access/inventory.cpp
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h



diff --git a/engines/access/inventory.cpp b/engines/access/inventory.cpp
index 1d78839..28a5cc2 100644
--- a/engines/access/inventory.cpp
+++ b/engines/access/inventory.cpp
@@ -31,10 +31,17 @@ namespace Access {
 void InventoryEntry::load(const Common::String &name, const int *data) {
 	_value = ITEM_NOT_FOUND;
 	_name = name;
-	_otherItem1 = *data++;
-	_newItem1 = *data++;
-	_otherItem2 = *data++;
-	_newItem2 = *data;
+	if (data) {
+		_otherItem1 = *data++;
+		_newItem1 = *data++;
+		_otherItem2 = *data++;
+		_newItem2 = *data;
+	} else {
+		_otherItem1 = -1;
+		_newItem1 = -1;
+		_otherItem2 = -1;
+		_newItem2 = -1;
+	}
 }
 
 int InventoryEntry::checkItem(int itemId) {
@@ -69,16 +76,15 @@ InventoryManager::InventoryManager(AccessEngine *vm) : Manager(vm) {
 		break;
 	case GType_MartianMemorandum:
 		names = Martian::INVENTORY_NAMES;
-		combineP = &Martian::COMBO_TABLE[0][0];
+		combineP = nullptr;
 		_inv.resize(55);
 		break;
 	default:
 		error("Unknown game");
 	}
 
-	for (uint i = 0; i < _inv.size(); ++i, combineP += 4) {
+	for (uint i = 0; i < _inv.size(); ++i, combineP += 4)
 		_inv[i].load(names[i], combineP);
-	}
 
 	for (uint i = 0; i < 26; ++i) {
 		const int *r = INVCOORDS[i];
diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index 72156ec..9196395 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -712,64 +712,6 @@ const byte *const CHARTBL_MM[] = {
 	MMCHAR_25, MMCHAR_26, MMCHAR_27
 };
 
-// TODO: Fix that array
-const int COMBO_TABLE[54][4] = {
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 },
-	{ -1, -1, -1, -1 }
-};
-
 const int SIDEOFFR[] = {  4, 0, 7, 10,  3, 1, 2, 13, 0, 0, 0, 0 };
 const int SIDEOFFL[] = { 11, 6, 1,  4, 10, 6, 1,  4, 0, 0, 0, 0 };
 const int SIDEOFFU[] = {  1, 2, 0,  2,  2, 1, 1,  0, 0, 0, 0, 0 };
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index cf74cbb..f416cff 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -49,8 +49,6 @@ extern const int ROOM_NUMB;
 
 extern const byte *const CHARTBL_MM[];
 
-extern const int COMBO_TABLE[54][4];
-
 extern const int SIDEOFFR[];
 extern const int SIDEOFFL[];
 extern const int SIDEOFFU[];


Commit: dd4028db050eff52602bc44e59dfce6e883dbf39
    https://github.com/scummvm/scummvm/commit/dd4028db050eff52602bc44e59dfce6e883dbf39
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-03T07:33:35+01:00

Commit Message:
ACCESS: MM - Hook displayInv

Changed paths:
    engines/access/scripts.cpp



diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 53d219d..1e055e4 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -526,7 +526,7 @@ void Scripts::cmdSetAnim() {
 }
 
 void Scripts::cmdDispInv_v1() {
-	error("TODO: cmdDisplInv_v1");
+	_vm->_inventory->displayInv();
 }
 
 void Scripts::cmdDispInv_v2() {


Commit: bb640a85a5d0f0634d78a59dc94573844113f40c
    https://github.com/scummvm/scummvm/commit/bb640a85a5d0f0634d78a59dc94573844113f40c
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-04T07:36:24+01:00

Commit Message:
ACCESS: MM - Fix compilation

Changed paths:
    engines/access/martian/martian_scripts.cpp



diff --git a/engines/access/martian/martian_scripts.cpp b/engines/access/martian/martian_scripts.cpp
index 1fb5991..5962cd9 100644
--- a/engines/access/martian/martian_scripts.cpp
+++ b/engines/access/martian/martian_scripts.cpp
@@ -96,7 +96,7 @@ void MartianScripts::cmdSpecial6() {
 		msg += c;
 
 	//display the message
-	_game->sub13D10(msg);
+	_game->showDeathText(msg);
 
 	delete notesRes;
 	delete _vm->_objectsTable[0];


Commit: 452c5e59c5e7c61bbf4135ac7430798fd3a97031
    https://github.com/scummvm/scummvm/commit/452c5e59c5e7c61bbf4135ac7430798fd3a97031
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-04T22:22:50+01:00

Commit Message:
ACCESS: Tex2 - Start implementing takePicture()

Changed paths:
    engines/access/access.cpp
    engines/access/access.h
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h
    engines/access/room.cpp
    engines/access/room.h
    engines/access/scripts.cpp
    engines/access/scripts.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index 8e9d52f..7c21b42 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -106,6 +106,7 @@ AccessEngine::AccessEngine(OSystem *syst, const AccessGameDescription *gameDesc)
 	BOXSELECTYOLD = -1;
 	NUMBLINES = 0;
 	TEMPLIST = nullptr;
+	_pictureTaken = 0;
 
 	_vidEnd = false;
 }
diff --git a/engines/access/access.h b/engines/access/access.h
index 2a2d48e..e649088 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -223,6 +223,7 @@ public:
 	byte _byte26CB5;
 	int BCNT;
 	byte *TEMPLIST;
+	int _pictureTaken;
 	//
 
 	bool _vidEnd;
diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index 9196395..7ffb256 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -819,5 +819,16 @@ const byte _byte1EEB5[] = {
 	1
 };
 
+const int PICTURERANGE[][2] = {
+// { min X, max X}, {min Y, max Y}
+	{ 20, 30 },  { 82, 87 },
+	{ 20, 30 },  { 105, 110 },
+	{ 0, 8 },    { 92, 100 },
+	{ 42, 46 },  { 92, 100 },
+	{ 9, 41 },   { 88, 104 },
+	{ 9, 41 },   { 117, 133 },
+	{ -1, -1 }
+};
+
 } // End of namespace Martian
 } // End of namespace Access
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index f416cff..7503ae4 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -67,6 +67,7 @@ extern const byte DEATH_SCREENS[];
 extern const char *const DEATHMESSAGE[];
 
 extern const byte _byte1EEB5[];
+extern const int PICTURERANGE[][2];
 
 } // End of namespace Martian
 } // End of namespace Access
diff --git a/engines/access/room.cpp b/engines/access/room.cpp
index 5ad576e..0767bf1 100644
--- a/engines/access/room.cpp
+++ b/engines/access/room.cpp
@@ -72,8 +72,91 @@ void Room::freeTileData() {
 	_tile = nullptr;
 }
 
+void Room::clearCamera() {
+	_vm->_player->_scrollFlag = true;
+	_vm->_events->hideCursor();
+
+	_vm->_screen->_orgX1 = 48;
+	_vm->_screen->_orgY1 = 24;
+	_vm->_screen->_orgX2 = 274;
+	_vm->_screen->_orgY2 = 152;
+	_vm->_screen->_lColor = 0;
+	_vm->_screen->drawRect();
+
+	_vm->_events->showCursor();
+
+	_vm->_events->_vbCount = 4;
+	while (!_vm->shouldQuit() && _vm->_events->_vbCount > 0)
+		_vm->_events->pollEventsAndWait();
+}
+
 void Room::takePicture() {
-	warning("TODO: takePicture");
+	_vm->_events->pollEvents();
+	if (!_vm->_events->_leftButton)
+		return;
+
+	Common::Array<Common::Rect> pictureCoords;
+	for (int i = 0; Martian::PICTURERANGE[i][0] != -1; i += 2) {
+		pictureCoords.push_back(Common::Rect(Martian::PICTURERANGE[i][0], Martian::PICTURERANGE[i + 1][0],
+			                                 Martian::PICTURERANGE[i][1], Martian::PICTURERANGE[i + 1][1]));
+	}
+
+	int result = _vm->_events->checkMouseBox1(pictureCoords);
+
+	if (result == 4) {
+		warning("TODO case 4");
+		_vm->_events->debounceLeft();
+		if (_vm->_inventory->_inv[44]._value != ITEM_IN_INVENTORY) {
+			Common::String msg = "YOU HAVE NO MORE FILM.";
+			_vm->_scripts->doCmdPrint_v1(msg);
+			return;
+		}
+
+		// TODO: simplify the second part of the test when tested
+		if ((_vm->_scrollCol < 35) || ((_vm->_scrollRow >= 10) && (_vm->_scrollRow >= 20))){
+			Common::String msg = "THAT ISN'T INTERESTING ENOUGH TO WASTE FILM ON.";
+			_vm->_scripts->doCmdPrint_v1(msg);
+			return;
+		}
+
+		if (_vm->_inventory->_inv[26]._value != ITEM_USED) {
+			Common::String msg = "ALTHOUGH IT WOULD MAKE A NICE PICTURE, YOU MAY FIND SOMETHING MORE INTERESTING TO USE YOUR FILM ON.";
+			_vm->_scripts->doCmdPrint_v1(msg);
+			return;
+		}
+
+		Common::String msg = "THAT PHOTO MAY COME IN HANDY SOME DAY.";
+		_vm->_scripts->doCmdPrint_v1(msg);
+		_vm->_inventory->_inv[8]._value = ITEM_IN_INVENTORY;
+		_vm->_pictureTaken++;
+		if (_vm->_pictureTaken == 16)
+			_vm->_inventory->_inv[44]._value = ITEM_USED;
+
+		_vm->_events->debounceLeft();
+		_vm->_sound->playSound(0);
+		clearCamera();
+		return;
+	} else if (result == 5) {
+		if (_vm->_flags[26] != 2) {
+			_vm->_video->closeVideo();
+			_vm->_video->_videoEnd = true;
+		}
+		_vm->_player->_roomNumber = 7;
+		_vm->_room->_function = FN_CLEAR1;
+		return;
+	} else if (result >= 0) 
+		_vm->_player->_move = (Direction)(result + 1);
+
+	_vm->_player->_scrollFlag = false;
+	if (_vm->_player->_move == UP)
+		warning("TODO: loc_163E9 2");
+	else if (_vm->_player->_move == DOWN)
+		warning("TODO: loc_1644A 2");
+	else if (_vm->_player->_move == LEFT)
+		warning("TODO: loc_1631E 2");
+	else if (_vm->_player->_move == RIGHT)
+		warning("TODO: loc_1637F 2");
+	else return;
 }
 
 void Room::doRoom() {
diff --git a/engines/access/room.h b/engines/access/room.h
index 2ecc1e8..022d940 100644
--- a/engines/access/room.h
+++ b/engines/access/room.h
@@ -105,6 +105,8 @@ protected:
 	 */
 	void executeCommand(int commandId);
 
+	void clearCamera();
+
 	virtual void reloadRoom() = 0;
 
 	virtual void reloadRoom1() = 0;
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 1e055e4..c1f2168 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -306,10 +306,9 @@ void Scripts::cmdPrint_v2() {
 	printString(msg);
 }
 
-void Scripts::cmdPrint_v1() {
+void Scripts::doCmdPrint_v1(Common::String msg) {
 	_vm->_screen->_printOrg = Common::Point(20, 42);
 	_vm->_screen->_printStart = Common::Point(20, 32);
-	Common::String msg = readString();
 	_vm->_bubbleBox->placeBubble(msg);
 	_vm->_events->waitKeyMouse();
 	_vm->_events->hideCursor();
@@ -318,6 +317,11 @@ void Scripts::cmdPrint_v1() {
 	findNull();
 }
 
+void Scripts::cmdPrint_v1() {
+	Common::String msg = readString();
+	doCmdPrint_v1(msg);
+}
+
 void Scripts::printString(const Common::String &msg) {
 	if (_vm->getGameID() != GType_MartianMemorandum) {
 		_vm->_screen->_printOrg = Common::Point(20, 42);
diff --git a/engines/access/scripts.h b/engines/access/scripts.h
index a035087..f157e73 100644
--- a/engines/access/scripts.h
+++ b/engines/access/scripts.h
@@ -165,6 +165,7 @@ public:
 	int executeScript();
 
 	void findNull();
+	void doCmdPrint_v1(Common::String msg);
 
 	/**
 	 * Print a given message to the screen in a bubble box


Commit: 852a6b3e81fb1dbfc010b15aff3f237df75f9992
    https://github.com/scummvm/scummvm/commit/852a6b3e81fb1dbfc010b15aff3f237df75f9992
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-05T06:42:58+01:00

Commit Message:
ACCESS: MM - Hook scroll functions in takePicture

Changed paths:
    engines/access/player.h
    engines/access/room.cpp



diff --git a/engines/access/player.h b/engines/access/player.h
index 8cecb67..62c5e27 100644
--- a/engines/access/player.h
+++ b/engines/access/player.h
@@ -74,10 +74,6 @@ protected:
 	void walkUpRight();
 	void walkDownRight();
 	void checkScrollUp();
-	bool scrollUp();
-	bool scrollDown();
-	bool scrollLeft();
-	bool scrollRight();
 public:
 	Direction _playerDirection;
 	SpriteResource *_playerSprites;
@@ -139,6 +135,10 @@ public:
 
 	void calcPlayer();
 
+	bool scrollUp();
+	bool scrollDown();
+	bool scrollLeft();
+	bool scrollRight();
 	void checkScroll();
 
 	void checkMove();
diff --git a/engines/access/room.cpp b/engines/access/room.cpp
index 0767bf1..3960277 100644
--- a/engines/access/room.cpp
+++ b/engines/access/room.cpp
@@ -104,7 +104,6 @@ void Room::takePicture() {
 	int result = _vm->_events->checkMouseBox1(pictureCoords);
 
 	if (result == 4) {
-		warning("TODO case 4");
 		_vm->_events->debounceLeft();
 		if (_vm->_inventory->_inv[44]._value != ITEM_IN_INVENTORY) {
 			Common::String msg = "YOU HAVE NO MORE FILM.";
@@ -149,14 +148,13 @@ void Room::takePicture() {
 
 	_vm->_player->_scrollFlag = false;
 	if (_vm->_player->_move == UP)
-		warning("TODO: loc_163E9 2");
+		_vm->_player->scrollDown();
 	else if (_vm->_player->_move == DOWN)
-		warning("TODO: loc_1644A 2");
+		_vm->_player->scrollUp();
 	else if (_vm->_player->_move == LEFT)
-		warning("TODO: loc_1631E 2");
+		_vm->_player->scrollRight();
 	else if (_vm->_player->_move == RIGHT)
-		warning("TODO: loc_1637F 2");
-	else return;
+		_vm->_player->scrollLeft();
 }
 
 void Room::doRoom() {


Commit: fb78a6f46554ee4c4d5e0bd21005daf6bb95e026
    https://github.com/scummvm/scummvm/commit/fb78a6f46554ee4c4d5e0bd21005daf6bb95e026
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-05T06:59:53+01:00

Commit Message:
ACCESS: MM - Add an optional variable to scroll functions

Changed paths:
    engines/access/player.cpp
    engines/access/player.h
    engines/access/room.cpp



diff --git a/engines/access/player.cpp b/engines/access/player.cpp
index e7a7b3f..b4af672 100644
--- a/engines/access/player.cpp
+++ b/engines/access/player.cpp
@@ -735,8 +735,12 @@ void Player::checkScroll() {
 	}
 }
 
-bool Player::scrollUp() {
-	_scrollAmount = -(_vm->_screen->_clipHeight - _playerY - _scrollThreshold);
+bool Player::scrollUp(int forcedAmount) {
+	if (forcedAmount == -1)
+		_scrollAmount = -(_vm->_screen->_clipHeight - _playerY - _scrollThreshold);
+	else
+		_scrollAmount = forcedAmount;
+
 	if ((_vm->_scrollRow + _vm->_screen->_vWindowHeight) >=
 			_vm->_room->_playFieldHeight)
 		return true;
@@ -763,8 +767,12 @@ bool Player::scrollUp() {
 	return false;
 }
 
-bool Player::scrollDown() {
-	_scrollAmount = -(_playerY - _scrollThreshold);
+bool Player::scrollDown(int forcedAmount) {
+	if (forcedAmount == -1)
+		_scrollAmount = -(_playerY - _scrollThreshold);
+	else
+		_scrollAmount = forcedAmount;
+
 	_scrollFlag = true;
 	_vm->_scrollY -= _scrollAmount;
 	if (_vm->_scrollY >= 0)
@@ -788,9 +796,13 @@ bool Player::scrollDown() {
 	return true;
 }
 
-bool Player::scrollLeft() {
+bool Player::scrollLeft(int forcedAmount) {
 	Screen &screen = *_vm->_screen;
-	_scrollAmount = -(_vm->_screen->_clipWidth - _playerX - _scrollThreshold);
+	if (forcedAmount == -1)
+		_scrollAmount = -(_vm->_screen->_clipWidth - _playerX - _scrollThreshold);
+	else
+		_scrollAmount = forcedAmount;
+
 	if ((_vm->_scrollCol + screen._vWindowWidth) == _vm->_room->_playFieldWidth) {
 		_scrollEnd = 2;
 		_vm->_scrollX = 0;
@@ -815,8 +827,12 @@ bool Player::scrollLeft() {
 	}
 }
 
-bool Player::scrollRight() {
-	_scrollAmount = -(_playerX - _scrollThreshold);
+bool Player::scrollRight(int forcedAmount) {
+	if (forcedAmount == -1)
+		_scrollAmount = -(_playerX - _scrollThreshold);
+	else
+		_scrollAmount = forcedAmount;
+
 	_scrollFlag = true;
 	_vm->_scrollX -= _scrollAmount;
 
diff --git a/engines/access/player.h b/engines/access/player.h
index 62c5e27..f3df2d0 100644
--- a/engines/access/player.h
+++ b/engines/access/player.h
@@ -135,10 +135,10 @@ public:
 
 	void calcPlayer();
 
-	bool scrollUp();
-	bool scrollDown();
-	bool scrollLeft();
-	bool scrollRight();
+	bool scrollUp(int forcedAmount = -1);
+	bool scrollDown(int forcedAmount = -1);
+	bool scrollLeft(int forcedAmount = -1);
+	bool scrollRight(int forcedAmount = -1);
 	void checkScroll();
 
 	void checkMove();
diff --git a/engines/access/room.cpp b/engines/access/room.cpp
index 3960277..6e0a4aa 100644
--- a/engines/access/room.cpp
+++ b/engines/access/room.cpp
@@ -148,13 +148,13 @@ void Room::takePicture() {
 
 	_vm->_player->_scrollFlag = false;
 	if (_vm->_player->_move == UP)
-		_vm->_player->scrollDown();
+		_vm->_player->scrollDown(2);
 	else if (_vm->_player->_move == DOWN)
-		_vm->_player->scrollUp();
+		_vm->_player->scrollUp(2);
 	else if (_vm->_player->_move == LEFT)
-		_vm->_player->scrollRight();
+		_vm->_player->scrollRight(2);
 	else if (_vm->_player->_move == RIGHT)
-		_vm->_player->scrollLeft();
+		_vm->_player->scrollLeft(2);
 }
 
 void Room::doRoom() {


Commit: a05e8625ccc0f641c0e886a35166c4233d5140fa
    https://github.com/scummvm/scummvm/commit/a05e8625ccc0f641c0e886a35166c4233d5140fa
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-05T07:36:17+01:00

Commit Message:
ACCESS: Remove an unused function

Changed paths:
    engines/access/access.cpp
    engines/access/access.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index 7c21b42..f680eeb 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -440,10 +440,6 @@ void AccessEngine::playVideo(int videoNum, const Common::Point &pt) {
 	}
 }
 
-void AccessEngine::doLoadSave() {
-	error("TODO: doLoadSave");
-}
-
 void AccessEngine::freeChar() {
 	_scripts->freeScriptData();
 	_animation->clearTimers();
diff --git a/engines/access/access.h b/engines/access/access.h
index e649088..51eb040 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -273,8 +273,6 @@ public:
 
 	void copyBF2Vid();
 
-	void doLoadSave();
-
 	void freeChar();
 
 	/**


Commit: ef9c9b78a3cf4f3392d86593586e076433dd78f8
    https://github.com/scummvm/scummvm/commit/ef9c9b78a3cf4f3392d86593586e076433dd78f8
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-06T08:24:44+01:00

Commit Message:
ACCESS: MM - Fix a crash

Changed paths:
    engines/access/inventory.cpp



diff --git a/engines/access/inventory.cpp b/engines/access/inventory.cpp
index 28a5cc2..cdb50f5 100644
--- a/engines/access/inventory.cpp
+++ b/engines/access/inventory.cpp
@@ -73,19 +73,20 @@ InventoryManager::InventoryManager(AccessEngine *vm) : Manager(vm) {
 		names = Amazon::INVENTORY_NAMES;
 		combineP = &Amazon::COMBO_TABLE[0][0];
 		_inv.resize(85);
+		for (uint i = 0; i < _inv.size(); ++i, combineP += 4)
+			_inv[i].load(names[i], combineP);
 		break;
 	case GType_MartianMemorandum:
 		names = Martian::INVENTORY_NAMES;
 		combineP = nullptr;
 		_inv.resize(55);
+		for (uint i = 0; i < _inv.size(); ++i)
+			_inv[i].load(names[i], nullptr);
 		break;
 	default:
 		error("Unknown game");
 	}
 
-	for (uint i = 0; i < _inv.size(); ++i, combineP += 4)
-		_inv[i].load(names[i], combineP);
-
 	for (uint i = 0; i < 26; ++i) {
 		const int *r = INVCOORDS[i];
 		_invCoords.push_back(Common::Rect(r[0], r[2], r[1], r[3]));


Commit: a81fbda3da5aa6b1960c22baf95359639b3fda20
    https://github.com/scummvm/scummvm/commit/a81fbda3da5aa6b1960c22baf95359639b3fda20
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-06T08:25:22+01:00

Commit Message:
ACCESS: MM - Start implementing PRINTCHR and SPRINTCHR

Changed paths:
    engines/access/access.cpp
    engines/access/access.h



diff --git a/engines/access/access.cpp b/engines/access/access.cpp
index f680eeb..9749706 100644
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@ -592,6 +592,36 @@ void AccessEngine::writeSavegameHeader(Common::OutSaveFile *out, AccessSavegameH
 	out->writeUint32LE(_events->getFrameCounter());
 }
 
+void AccessEngine::SPRINTCHR(char c, int fontNum) {
+	warning("TODO: SPRINTCHR");
+	_fonts._font1.drawChar(_screen, c, _screen->_printOrg);
+}
+
+void AccessEngine::PRINTCHR(Common::String msg, int fontNum) {
+	_events->hideCursor();
+	warning("TODO: PRINTCHR - Handle fontNum");
+
+	for (int i = 0; msg[i]; i++) {
+		if (!(_fonts._charSet._hi & 8)) {
+			_fonts._font1.drawChar(_screen, msg[i], _screen->_printOrg);
+			continue;
+		} else if (_fonts._charSet._hi & 2) {
+			Common::Point oldPos = _screen->_printOrg;
+			int oldFontLo = _fonts._charFor._lo;
+
+			_fonts._charFor._lo = 0;
+			_screen->_printOrg.x++;
+			_screen->_printOrg.y++;
+			SPRINTCHR(msg[i], fontNum);
+
+			_screen->_printOrg = oldPos;
+			_fonts._charFor._lo = oldFontLo;
+		}
+		SPRINTCHR(msg[i], fontNum);
+	}
+	_events->showCursor();
+}
+
 bool AccessEngine::shouldQuitOrRestart() {
 	return shouldQuit() || _restartFl;
 }
diff --git a/engines/access/access.h b/engines/access/access.h
index 51eb040..a53a659 100644
--- a/engines/access/access.h
+++ b/engines/access/access.h
@@ -310,6 +310,9 @@ public:
 	 * Write out a savegame header
 	 */
 	void writeSavegameHeader(Common::OutSaveFile *out, AccessSavegameHeader &header);
+
+	void SPRINTCHR(char c, int fontNum);
+	void PRINTCHR(Common::String msg, int fontNum);
 };
 
 } // End of namespace Access


Commit: bdf3042174d9c91106304f18358421e3ade5ee7b
    https://github.com/scummvm/scummvm/commit/bdf3042174d9c91106304f18358421e3ade5ee7b
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-09T19:34:32+01:00

Commit Message:
ACCESS: MM - Implement cmdSpecial7

Changed paths:
    engines/access/martian/martian_game.cpp
    engines/access/martian/martian_game.h
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h
    engines/access/martian/martian_scripts.cpp
    engines/access/martian/martian_scripts.h
    engines/access/scripts.h



diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index e3784e2..7572d36 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -35,6 +35,7 @@ MartianEngine::MartianEngine(OSystem *syst, const AccessGameDescription *gameDes
 }
 
 MartianEngine::~MartianEngine() {
+	_introObjects = _spec7Objects = nullptr;
 }
 
 void MartianEngine::initObjects() {
diff --git a/engines/access/martian/martian_game.h b/engines/access/martian/martian_game.h
index c324ef5..9ef6c05 100644
--- a/engines/access/martian/martian_game.h
+++ b/engines/access/martian/martian_game.h
@@ -60,6 +60,8 @@ protected:
 	void setNoteParams();
 	void displayNote(const Common::String &msg);
 public:
+	SpriteResource *_spec7Objects;
+
 	MartianEngine(OSystem *syst, const AccessGameDescription *gameDesc);
 	virtual ~MartianEngine();
 
diff --git a/engines/access/martian/martian_resources.cpp b/engines/access/martian/martian_resources.cpp
index 7ffb256..2ae6114 100644
--- a/engines/access/martian/martian_resources.cpp
+++ b/engines/access/martian/martian_resources.cpp
@@ -810,6 +810,16 @@ const char *const DEATHMESSAGE[] = {
 	"ONCE DANGERFIELD GETS OUT OF HIS CHAMBER, HE PULLS OUT A WEAPON AND LETS YOU HAVE IT."
 };
 
+const char *const SPEC7MESSAGE = {
+	"THOMAS DANGERFIELD'S MAD EXPERIMENT OF ATTEMPTING TO HARNESS THE STONE'S POWER, ENDED HIS LIFE. DANGERFIELD WAS A DECENT HUMAN " \
+	"BEING ONCE, BUT WAS DRIVEN INSANE BY HIS QUEST FOR THE ULTIMATE POWER. ALEXIS AND I DECIDE THAT DEACON HAWKE IS THE ONLY " \
+	"LOGICAL CHOICE FOR THE STONE. WE ARRIVE AT THE TEMPLE WHERE SHE IS WAITING FOR US. SHE TURNS AND WHISPERS; 'YOU HAVE RETURNED " \
+	"THE STONE TO THE MISTRESS OF THE LIGHT. YOU HAVE SURELY SAVED THE WORLD FROM ANNIHILATION BUT YOU MUST CONTINUE TO BE DILIGENT. " \
+	"MANKIND MAY YET PROVE TO BE THE AUTHOR OF HIS OWN DEMISE. REVERENCE LIFE. PROTECT THE LIVING THINGS AND RECYCLE. AND NOW FOR " \
+	"THE SAFETY OF MANKIND, I MUST TAKE THE STONE. PERHAPS SOMEDAY, WHEN THE HUMAN RACE IS READY, IT WILL BE RETURNED. UNTIL THEN "\
+	"FAREWELL...'"
+};
+
 const byte _byte1EEB5[] = {
 	0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
 	0, 0, 0, 0, 0, 0, 0, 1, 1, 1,
diff --git a/engines/access/martian/martian_resources.h b/engines/access/martian/martian_resources.h
index 7503ae4..4ffc4de 100644
--- a/engines/access/martian/martian_resources.h
+++ b/engines/access/martian/martian_resources.h
@@ -65,6 +65,7 @@ extern const char *const TRAVDATA[];
 
 extern const byte DEATH_SCREENS[];
 extern const char *const DEATHMESSAGE[];
+extern const char *const SPEC7MESSAGE;
 
 extern const byte _byte1EEB5[];
 extern const int PICTURERANGE[][2];
diff --git a/engines/access/martian/martian_scripts.cpp b/engines/access/martian/martian_scripts.cpp
index 5962cd9..e8eedde 100644
--- a/engines/access/martian/martian_scripts.cpp
+++ b/engines/access/martian/martian_scripts.cpp
@@ -104,6 +104,160 @@ void MartianScripts::cmdSpecial6() {
 	_vm->_midi->stopSong();
 }
 
+void MartianScripts::cmdSpecial7() {
+	_vm->_room->clearRoom();
+	_vm->_midi->loadMusic(47, 8);
+
+	_vm->_sound->freeSounds();
+	Resource *sound = _vm->_sound->loadSound(46, 14);
+	_vm->_sound->_soundTable.push_back(SoundEntry(sound, 1));
+
+	_vm->_screen->setDisplayScan();
+	_vm->_screen->forceFadeOut();
+	_vm->_events->hideCursor();
+
+	_vm->_files->loadScreen(40, 3);
+	_vm->_buffer1.copyBuffer(_vm->_screen);
+	_vm->_buffer2.copyBuffer(_vm->_screen);
+
+	_vm->_events->showCursor();
+	_vm->_screen->setIconPalette();
+	_vm->_screen->forceFadeIn();
+
+	// Load objects specific to this special scene
+	Resource *data = _vm->_files->loadFile(40, 2);
+	_game->_spec7Objects = new SpriteResource(_vm, data);
+	delete data;
+
+	// Load animation data
+	_vm->_animation->freeAnimationData();
+	Resource *animResource = _vm->_files->loadFile(40, 1);
+	_vm->_animation->loadAnimations(animResource);
+	delete animResource;
+
+	// Load script
+	Resource *newScript = _vm->_files->loadFile(40, 0);
+	_vm->_scripts->setScript(newScript);
+
+	_vm->_images.clear();
+	_vm->_oldRects.clear();
+	_vm->_scripts->_sequence = 0;
+
+	_vm->_sound->playSound(0);
+	
+	do {
+		charLoop();
+	} while (_vm->_flags[134] != 1);
+
+	do {
+		_vm->_events->pollEvents();
+	} while (!_vm->shouldQuit() && _vm->_sound->_playingSound);
+
+	_game->_numAnimTimers = 0;
+	_vm->_animation->freeAnimationData();
+	_vm->_scripts->freeScriptData();
+	_vm->_sound->freeSounds();
+
+	_vm->_screen->forceFadeOut();
+	_vm->_midi->midiPlay();
+	_vm->_midi->setLoop(true);
+	_vm->_events->hideCursor();
+
+	_vm->_files->loadScreen(40, 4);
+	_vm->_buffer1.copyBuffer(_vm->_screen);
+	_vm->_buffer2.copyBuffer(_vm->_screen);
+
+	_vm->_events->showCursor();
+	_vm->_screen->setIconPalette();
+	_vm->_screen->forceFadeIn();
+
+	// Setup fonts
+	_vm->_fonts._charSet._hi = 10;
+	_vm->_fonts._charSet._lo = 1;
+	_vm->_fonts._charFor._lo = 247;
+	_vm->_fonts._charFor._hi = 255;
+	_vm->_screen->_maxChars = 50;
+	_vm->_screen->_printOrg = Common::Point(24, 18);
+	_vm->_screen->_printStart = Common::Point(24, 18);
+
+	// Display death message
+	_game->showDeathText(Common::String(SPEC7MESSAGE));
+
+	_vm->_events->showCursor();
+	_vm->_screen->copyBuffer(&_vm->_buffer1);
+	_vm->_events->hideCursor();
+
+	_vm->_video->setVideo(_vm->_screen, Common::Point(120, 16), FileIdent(40, 5), 10);
+	
+	while (!_vm->shouldQuit() && !_vm->_video->_videoEnd) {
+		_vm->_video->playVideo();
+		_vm->_events->pollEventsAndWait();
+	}
+
+	_vm->_sound->freeSounds();
+	sound = _vm->_sound->loadSound(40, 8);
+	_vm->_sound->_soundTable.push_back(SoundEntry(sound, 1));
+	sound = _vm->_sound->loadSound(40, 9);
+	_vm->_sound->_soundTable.push_back(SoundEntry(sound, 1));
+	sound = _vm->_sound->loadSound(40, 10);
+	_vm->_sound->_soundTable.push_back(SoundEntry(sound, 1));
+
+	_vm->_screen->forceFadeOut();
+	_vm->_files->loadScreen(40, 7);
+	_vm->_destIn = _vm->_screen;
+	
+	_vm->_screen->plotImage(_game->_spec7Objects, 8, Common::Point(104, 176));
+	_vm->_screen->plotImage(_game->_spec7Objects, 7, Common::Point(102, 160));
+	_vm->_events->showCursor();
+	_vm->_screen->forceFadeIn();
+
+	_vm->_events->_vbCount = 100;
+	while (!_vm->shouldQuit() && _vm->_events->_vbCount > 0)
+		_vm->_events->pollEventsAndWait();
+
+	_vm->_sound->playSound(0);
+	do {
+		_vm->_events->pollEvents();
+	} while (!_vm->shouldQuit() && _vm->_sound->_playingSound);
+
+	_vm->_events->_vbCount = 80;
+	while (!_vm->shouldQuit() && _vm->_events->_vbCount > 0)
+		_vm->_events->pollEventsAndWait();
+
+	_vm->_sound->playSound(1);
+	do {
+		_vm->_events->pollEvents();
+	} while (!_vm->shouldQuit() && _vm->_sound->_playingSound);
+
+	_vm->_events->_vbCount = 80;
+	while (!_vm->shouldQuit() && _vm->_events->_vbCount > 0)
+		_vm->_events->pollEventsAndWait();
+	
+	_vm->_sound->playSound(2);
+	do {
+		_vm->_events->pollEvents();
+	} while (!_vm->shouldQuit() && _vm->_sound->_playingSound);
+
+	_vm->_sound->freeSounds();
+
+	delete _game->_spec7Objects;
+	_game->_spec7Objects = nullptr;
+
+	_vm->_events->hideCursor();
+	_vm->_screen->forceFadeOut();
+	_vm->_files->loadScreen(40, 6);
+	_vm->_events->showCursor();
+	_vm->_screen->forceFadeIn();
+
+	_vm->_events->waitKeyMouse();
+	_vm->_midi->stopSong();
+	_vm->_midi->freeMusic();
+
+	// The original was jumping to the restart label in main
+	_vm->_restartFl = true;
+	_vm->_events->pollEvents();
+}
+
 void MartianScripts::executeSpecial(int commandIndex, int param1, int param2) {
 	switch (commandIndex) {
 	case 0:
@@ -128,7 +282,7 @@ void MartianScripts::executeSpecial(int commandIndex, int param1, int param2) {
 		cmdSpecial6();
 		break;
 	case 7:
-		warning("TODO: cmdSpecial7");
+		cmdSpecial7();
 		break;
 	default:
 		warning("Unexpected Special code %d - Skipped", commandIndex);
diff --git a/engines/access/martian/martian_scripts.h b/engines/access/martian/martian_scripts.h
index 9a80558..fb553fe 100644
--- a/engines/access/martian/martian_scripts.h
+++ b/engines/access/martian/martian_scripts.h
@@ -40,6 +40,7 @@ private:
 	void cmdSpecial3();
 	void doIntro(int param1);
 	void cmdSpecial6();
+	void cmdSpecial7();
 
 protected:
 	virtual void executeSpecial(int commandIndex, int param1, int param2);
diff --git a/engines/access/scripts.h b/engines/access/scripts.h
index f157e73..07fd6ac 100644
--- a/engines/access/scripts.h
+++ b/engines/access/scripts.h
@@ -42,7 +42,6 @@ private:
 	Resource *_resource;
 	int _specialFunction;
 
-	void charLoop();
 	void clearWatch();
 	void printWatch();
 
@@ -53,6 +52,8 @@ protected:
 	virtual void executeSpecial(int commandIndex, int param1, int param2) = 0;
 	virtual void executeCommand(int commandIndex);
 
+	void charLoop();
+
 	/**
 	 * Read a null terminated string from the script
 	 */


Commit: a54bb5e3515d4fb3630fd6ae1a9727ddc1230e19
    https://github.com/scummvm/scummvm/commit/a54bb5e3515d4fb3630fd6ae1a9727ddc1230e19
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-10T07:53:31+01:00

Commit Message:
ACCESS: MM - Implement cmdSpecial0

Changed paths:
    engines/access/martian/martian_scripts.cpp
    engines/access/martian/martian_scripts.h
    engines/access/screen.cpp
    engines/access/screen.h



diff --git a/engines/access/martian/martian_scripts.cpp b/engines/access/martian/martian_scripts.cpp
index e8eedde..a9b5de5 100644
--- a/engines/access/martian/martian_scripts.cpp
+++ b/engines/access/martian/martian_scripts.cpp
@@ -34,6 +34,47 @@ MartianScripts::MartianScripts(AccessEngine *vm) : Scripts(vm) {
 	_game = (MartianEngine *)_vm;
 }
 
+void MartianScripts::cmdSpecial0() {
+	_vm->_sound->stopSound();
+	_vm->_midi->stopSong();
+
+	_vm->_midi->loadMusic(47, 1);
+	_vm->_midi->midiPlay();
+	_vm->_midi->setLoop(true);
+
+	_vm->_events->_vbCount = 300;
+	while (!_vm->shouldQuit() && _vm->_events->_vbCount > 0)
+		_vm->_events->pollEventsAndWait();
+
+	_vm->_screen->forceFadeOut();
+	_vm->_files->loadScreen("HOUSE.SC");
+
+	_vm->_video->setVideo(_vm->_screen, Common::Point(46, 30), "HVID.VID", 20);
+	
+	do {
+		_vm->_video->playVideo();
+		if (_vm->_video->_videoFrame == 4) {
+			_vm->_screen->flashPalette(16);
+			_vm->_sound->playSound(4);
+			do {
+				_vm->_events->pollEvents();
+			} while (!_vm->shouldQuit() && _vm->_sound->_playingSound);
+			_vm->_timers[31]._timer = _vm->_timers[31]._initTm = 40;
+		}
+	} while (!_vm->_video->_videoEnd && !_vm->shouldQuit());
+
+	if (_vm->_video->_videoEnd) {
+		_vm->_screen->flashPalette(12);
+		_vm->_sound->playSound(4);
+		do {
+			_vm->_events->pollEvents();
+		} while (!_vm->shouldQuit() && _vm->_sound->_playingSound);
+		_vm->_midi->stopSong();
+		_vm->_midi->freeMusic();
+		warning("TODO: Pop Midi");
+	}
+}
+
 void MartianScripts::cmdSpecial1(int param1) {
 	_vm->_events->hideCursor();
 	
@@ -261,7 +302,7 @@ void MartianScripts::cmdSpecial7() {
 void MartianScripts::executeSpecial(int commandIndex, int param1, int param2) {
 	switch (commandIndex) {
 	case 0:
-		warning("TODO: cmdSpecial0");
+		cmdSpecial0();
 		break;
 	case 1:
 		cmdSpecial1(param1);
diff --git a/engines/access/martian/martian_scripts.h b/engines/access/martian/martian_scripts.h
index fb553fe..9c21412 100644
--- a/engines/access/martian/martian_scripts.h
+++ b/engines/access/martian/martian_scripts.h
@@ -36,6 +36,7 @@ class MartianScripts : public Scripts {
 private:
 	MartianEngine *_game;
 
+	void cmdSpecial0();
 	void cmdSpecial1(int param1);
 	void cmdSpecial3();
 	void doIntro(int param1);
diff --git a/engines/access/screen.cpp b/engines/access/screen.cpp
index 2b535b6..5130d8e 100644
--- a/engines/access/screen.cpp
+++ b/engines/access/screen.cpp
@@ -336,6 +336,10 @@ void Screen::cyclePaletteBackwards() {
 	}
 }
 
+void Screen::flashPalette(int count) {
+	warning("TODO: Implement flashPalette");
+}
+
 void Screen::addDirtyRect(const Common::Rect &r) {
 	_dirtyRects.push_back(r);
 	assert(r.isValidRect() && r.width() > 0 && r.height() > 0);
diff --git a/engines/access/screen.h b/engines/access/screen.h
index a5431bc..97ec59d 100644
--- a/engines/access/screen.h
+++ b/engines/access/screen.h
@@ -158,6 +158,8 @@ public:
 
 	void getPalette(byte *pal);
 
+	void flashPalette(int count);
+
 	/**
 	 * Copy a buffer to the screen
 	 */


Commit: 232775c5b35c7b386859f7d43120ea213249b489
    https://github.com/scummvm/scummvm/commit/232775c5b35c7b386859f7d43120ea213249b489
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-11T07:23:30+01:00

Commit Message:
ACCESS: MM - Implement cmdPushLocation

Changed paths:
    engines/access/inventory.cpp
    engines/access/scripts.cpp



diff --git a/engines/access/inventory.cpp b/engines/access/inventory.cpp
index cdb50f5..48add68 100644
--- a/engines/access/inventory.cpp
+++ b/engines/access/inventory.cpp
@@ -216,7 +216,6 @@ int InventoryManager::newDisplayInv() {
 }
 
 int InventoryManager::displayInv() {
-	warning("TODO: displayInv");
 	int *inv = (int *) malloc (Martian::INVENTORY_SIZE * sizeof(int));
 
 	for (int i = 0; i < Martian::INVENTORY_SIZE; i++)
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index c1f2168..8bb68e5 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -1048,7 +1048,7 @@ void Scripts::cmdDispAbout() {
 }
 
 void Scripts::cmdPushLocation() {
-	error("TODO cmdPushLocation");
+	_choiceStart = _data->pos() - 1;
 }
 
 void Scripts::cmdCheckTravel() {
@@ -1062,7 +1062,11 @@ void Scripts::cmdCheckTravel() {
 }
 
 void Scripts::cmdBlock() {
-	error("TODO: DEMO - cmdBlock");
+	error("TODO: cmdBlock");
+	int val1 = _data->readSint16LE();
+	int val2 = _data->readUint16LE();
+	int val3 = _data->readSint16LE();
+	int val4 = _data->readUint16LE();
 }
 
 void Scripts::cmdPlayerOff() {


Commit: 2fe58fac489ecc21f062b0d10a1b388fc7abd1eb
    https://github.com/scummvm/scummvm/commit/2fe58fac489ecc21f062b0d10a1b388fc7abd1eb
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-13T07:20:31+01:00

Commit Message:
ACCESS: MM - Fix a bug in doBox_v1, implement some TYPE_3 code

Changed paths:
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h



diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index d3254d4..43333c9 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -507,13 +507,24 @@ int BubbleBox::doBox_v1(int item, int box, int &btnSelected) {
 		tmpY = BOXENDY = _vm->_screen->_orgY1;
 
 		if (_type == TYPE_3)
-			BICONSTARTY = tmpY - 7;
+			BICONSTARTY = tmpY + 9;
 		else
 			BICONSTARTY = tmpY + 1;
 
-		if (_type == TYPE_3)
-			warning("TODO: Implement more of TYPE_3");
-
+		if (_type == TYPE_3) {
+			_fileStart = Common::Point((tmpX + 2) >> 3, (tmpY + 2) >> 3);
+			int rowOff = tmpY - (_fileStart.y << 3) + 1;
+			if (rowOff == 8) {
+				rowOff = 0;
+				++_fileStart.y;
+			}
+			_fileOff.y = _rowOff = rowOff;
+			SETCURSORPOS(_fileStart.x, _fileStart.y);
+			_vm->_fonts._charFor._lo = 0xF7;
+			_vm->_fonts._charFor._hi = 0;
+			PRINTSTR("FILE:           ");
+			_vm->_fonts._charFor._hi = 0xFF;
+		}
 		_vm->_screen->_orgY1 = oldY;
 	}
 
diff --git a/engines/access/bubble_box.h b/engines/access/bubble_box.h
index d279ed1..35b7ca2 100644
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@ -43,6 +43,7 @@ private:
 	int _startItem, _startBox;
 	int _charCol, _rowOff;
 	Common::Point _fileStart;
+	Common::Point _fileOff;
 	int BOXSTARTX, BOXSTARTY;
 	int BOXENDX, BOXENDY;
 	int BICONSTARTX, BICONSTARTY;


Commit: 5ec05f6b647c5ea41418be7ed19ad381f97cabd8
    https://github.com/scummvm/scummvm/commit/5ec05f6b647c5ea41418be7ed19ad381f97cabd8
Author: Strangerke (strangerke at scummvm.org)
Date: 2015-02-14T15:19:40+01:00

Commit Message:
ACCESS: MM - use PRINTSTR in several places, remove related TODOs

Changed paths:
    engines/access/bubble_box.cpp
    engines/access/martian/martian_game.cpp
    engines/access/scripts.cpp



diff --git a/engines/access/bubble_box.cpp b/engines/access/bubble_box.cpp
index 43333c9..c9097bb 100644
--- a/engines/access/bubble_box.cpp
+++ b/engines/access/bubble_box.cpp
@@ -169,7 +169,7 @@ void BubbleBox::printBubble_v1(const Common::String &msg) {
 		Font &font2 = _vm->_fonts._font2;
 		lastLine = font2.getLine(s, _vm->_screen->_maxChars * 6, line, width);
 		// Draw the text
-		font2.drawString(_vm->_screen, line, _vm->_screen->_printOrg);
+		PRINTSTR(line);
 
 		// Move print position
 		_vm->_screen->_printOrg.y += 6;
diff --git a/engines/access/martian/martian_game.cpp b/engines/access/martian/martian_game.cpp
index 7572d36..69ca4d3 100644
--- a/engines/access/martian/martian_game.cpp
+++ b/engines/access/martian/martian_game.cpp
@@ -114,7 +114,7 @@ void MartianEngine::displayNote(const Common::String &msg) {
 	bool lastLine = false;
 	do {
 		lastLine = _fonts._font1.getLine(lines, _screen->_maxChars * 6, line, width);
-		_fonts._font1.drawString(_screen, line, _screen->_printOrg);
+		_bubbleBox->PRINTSTR(line);
 		_screen->_printOrg = Common::Point(_screen->_printStart.x, _screen->_printOrg.y + 6);
 
 		if (_screen->_printOrg.y == 196) {
@@ -313,9 +313,8 @@ void MartianEngine::showDeathText(Common::String msg) {
 	bool lastLine;
 	do {
 		lastLine = _fonts._font2.getLine(msg, _screen->_maxChars * 6, line, width);
-		warning("TODO: use printString");
 		// Draw the text
-		_fonts._font2.drawString(_screen, line, _screen->_printOrg);
+		_bubbleBox->PRINTSTR(line);
 
 		_screen->_printOrg.y += 6;
 		_screen->_printOrg.x = _screen->_printStart.x;
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 8bb68e5..db90530 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -202,9 +202,8 @@ void Scripts::printWatch() {
 	bool lastLine;
 	do {
 		lastLine = _vm->_fonts._font2.getLine(msg, _vm->_screen->_maxChars * 6, line, width);
-		warning("TODO: use printString");
 		// Draw the text
-		_vm->_fonts._font2.drawString(_vm->_screen, line, _vm->_screen->_printOrg);
+		_vm->_bubbleBox->PRINTSTR(line);
 
 		_vm->_screen->_printOrg.y += 6;
 		_vm->_screen->_printOrg.x = _vm->_screen->_printStart.x;
@@ -688,7 +687,7 @@ void Scripts::cmdDoTravel() {
 			int idx = _vm->_travelBox->_tempListIdx[boxX];
 			if (Martian::_byte1EEB5[idx] != _vm->_byte26CB5) {
 				_vm->_bubbleBox->_bubbleTitle = "TRAVEL";
-				_vm->_scripts->printString("YOU CAN'T GET THERE FROM HERE.");
+				_vm->_bubbleBox->PRINTSTR("YOU CAN'T GET THERE FROM HERE.");
 				continue;
 			}
 			if (_vm->_player->_roomNumber != idx) {


Commit: 6ec9c81b575f13b2c4b30aeac592ebf2557b5890
    https://github.com/scummvm/scummvm/commit/6ec9c81b575f13b2c4b30aeac592ebf2557b5890
Author: Willem Jan Palenstijn (wjp at usecode.org)
Date: 2015-07-22T22:43:42+02:00

Commit Message:
Merge branch 'master' into mm

Conflicts:
	engines/access/access.cpp
	engines/access/asurface.h
	engines/access/bubble_box.cpp
	engines/access/bubble_box.h
	engines/access/martian/martian_game.cpp
	engines/access/player.cpp
	engines/access/player.h
	engines/access/resources.cpp
	engines/access/screen.cpp
	engines/access/screen.h
	engines/access/sound.cpp
	engines/access/sound.h

Changed paths:
  A audio/adlib.cpp
  A audio/alsa_opl.cpp
  A audio/decoders/3do.cpp
  A audio/decoders/3do.h
  A audio/miles.h
  A audio/miles_adlib.cpp
  A audio/miles_mt32.cpp
  A audio/softsynth/mt32/Analog.cpp
  A audio/softsynth/mt32/Analog.h
  A audio/softsynth/mt32/MemoryRegion.h
  A audio/softsynth/mt32/MidiEventQueue.h
  A audio/softsynth/mt32/Types.h
  A audio/softsynth/mt32/internals.h
  A backends/platform/sdl/sdl-window.cpp
  A backends/platform/sdl/sdl-window.h
  A backends/platform/sdl/win32/win32-window.cpp
  A backends/platform/sdl/win32/win32-window.h
  A backends/platform/symbian/mmp/scummvm_access.mmp.in
  A backends/platform/symbian/mmp/scummvm_prince.mmp.in
  A dists/android/custom_rules.xml
  A dists/android/jni/Android.mk
  A dists/android/project.properties
  A doc/de/Spieletitel Original-Deutsch Deutsch-Original
  A engines/agos/drivers/accolade/adlib.cpp
  A engines/agos/drivers/accolade/driverfile.cpp
  A engines/agos/drivers/accolade/mididriver.h
  A engines/agos/drivers/accolade/mt32.cpp
  A engines/mads/phantom/globals_phantom.cpp
  A engines/mads/phantom/globals_phantom.h
  A engines/mads/phantom/phantom_scenes1.cpp
  A engines/mads/phantom/phantom_scenes1.h
  A engines/queen/midiadlib.h
  A engines/sherlock/animation.cpp
  A engines/sherlock/animation.h
  A engines/sherlock/configure.engine
  A engines/sherlock/debugger.cpp
  A engines/sherlock/debugger.h
  A engines/sherlock/decompress.cpp
  A engines/sherlock/detection.cpp
  A engines/sherlock/detection_tables.h
  A engines/sherlock/events.cpp
  A engines/sherlock/events.h
  A engines/sherlock/fixed_text.cpp
  A engines/sherlock/fixed_text.h
  A engines/sherlock/fonts.cpp
  A engines/sherlock/fonts.h
  A engines/sherlock/image_file.cpp
  A engines/sherlock/image_file.h
  A engines/sherlock/inventory.cpp
  A engines/sherlock/inventory.h
  A engines/sherlock/journal.cpp
  A engines/sherlock/journal.h
  A engines/sherlock/map.cpp
  A engines/sherlock/map.h
  A engines/sherlock/module.mk
  A engines/sherlock/music.cpp
  A engines/sherlock/music.h
  A engines/sherlock/objects.cpp
  A engines/sherlock/objects.h
  A engines/sherlock/people.cpp
  A engines/sherlock/people.h
  A engines/sherlock/resources.cpp
  A engines/sherlock/resources.h
  A engines/sherlock/saveload.cpp
  A engines/sherlock/saveload.h
  A engines/sherlock/scalpel/3do/movie_decoder.cpp
  A engines/sherlock/scalpel/3do/movie_decoder.h
  A engines/sherlock/scalpel/darts.cpp
  A engines/sherlock/scalpel/darts.h
  A engines/sherlock/scalpel/drivers/adlib.cpp
  A engines/sherlock/scalpel/drivers/mididriver.h
  A engines/sherlock/scalpel/drivers/mt32.cpp
  A engines/sherlock/scalpel/scalpel.cpp
  A engines/sherlock/scalpel/scalpel.h
  A engines/sherlock/scalpel/scalpel_debugger.cpp
  A engines/sherlock/scalpel/scalpel_debugger.h
  A engines/sherlock/scalpel/scalpel_fixed_text.cpp
  A engines/sherlock/scalpel/scalpel_fixed_text.h
  A engines/sherlock/scalpel/scalpel_inventory.cpp
  A engines/sherlock/scalpel/scalpel_inventory.h
  A engines/sherlock/scalpel/scalpel_journal.cpp
  A engines/sherlock/scalpel/scalpel_journal.h
  A engines/sherlock/scalpel/scalpel_map.cpp
  A engines/sherlock/scalpel/scalpel_map.h
  A engines/sherlock/scalpel/scalpel_people.cpp
  A engines/sherlock/scalpel/scalpel_people.h
  A engines/sherlock/scalpel/scalpel_saveload.cpp
  A engines/sherlock/scalpel/scalpel_saveload.h
  A engines/sherlock/scalpel/scalpel_scene.cpp
  A engines/sherlock/scalpel/scalpel_scene.h
  A engines/sherlock/scalpel/scalpel_screen.cpp
  A engines/sherlock/scalpel/scalpel_screen.h
  A engines/sherlock/scalpel/scalpel_talk.cpp
  A engines/sherlock/scalpel/scalpel_talk.h
  A engines/sherlock/scalpel/scalpel_user_interface.cpp
  A engines/sherlock/scalpel/scalpel_user_interface.h
  A engines/sherlock/scalpel/settings.cpp
  A engines/sherlock/scalpel/settings.h
  A engines/sherlock/scalpel/tsage/logo.cpp
  A engines/sherlock/scalpel/tsage/logo.h
  A engines/sherlock/scalpel/tsage/resources.cpp
  A engines/sherlock/scalpel/tsage/resources.h
  A engines/sherlock/scene.cpp
  A engines/sherlock/scene.h
  A engines/sherlock/screen.cpp
  A engines/sherlock/screen.h
  A engines/sherlock/sherlock.cpp
  A engines/sherlock/sherlock.h
  A engines/sherlock/sound.cpp
  A engines/sherlock/sound.h
  A engines/sherlock/surface.cpp
  A engines/sherlock/surface.h
  A engines/sherlock/talk.cpp
  A engines/sherlock/talk.h
  A engines/sherlock/tattoo/tattoo.cpp
  A engines/sherlock/tattoo/tattoo.h
  A engines/sherlock/tattoo/tattoo_darts.cpp
  A engines/sherlock/tattoo/tattoo_darts.h
  A engines/sherlock/tattoo/tattoo_debugger.cpp
  A engines/sherlock/tattoo/tattoo_debugger.h
  A engines/sherlock/tattoo/tattoo_fixed_text.cpp
  A engines/sherlock/tattoo/tattoo_fixed_text.h
  A engines/sherlock/tattoo/tattoo_inventory.cpp
  A engines/sherlock/tattoo/tattoo_inventory.h
  A engines/sherlock/tattoo/tattoo_journal.cpp
  A engines/sherlock/tattoo/tattoo_journal.h
  A engines/sherlock/tattoo/tattoo_map.cpp
  A engines/sherlock/tattoo/tattoo_map.h
  A engines/sherlock/tattoo/tattoo_people.cpp
  A engines/sherlock/tattoo/tattoo_people.h
  A engines/sherlock/tattoo/tattoo_resources.cpp
  A engines/sherlock/tattoo/tattoo_resources.h
  A engines/sherlock/tattoo/tattoo_scene.cpp
  A engines/sherlock/tattoo/tattoo_scene.h
  A engines/sherlock/tattoo/tattoo_talk.cpp
  A engines/sherlock/tattoo/tattoo_talk.h
  A engines/sherlock/tattoo/tattoo_user_interface.cpp
  A engines/sherlock/tattoo/tattoo_user_interface.h
  A engines/sherlock/tattoo/widget_base.cpp
  A engines/sherlock/tattoo/widget_base.h
  A engines/sherlock/tattoo/widget_inventory.cpp
  A engines/sherlock/tattoo/widget_inventory.h
  A engines/sherlock/tattoo/widget_lab.cpp
  A engines/sherlock/tattoo/widget_lab.h
  A engines/sherlock/tattoo/widget_talk.cpp
  A engines/sherlock/tattoo/widget_talk.h
  A engines/sherlock/tattoo/widget_text.cpp
  A engines/sherlock/tattoo/widget_text.h
  A engines/sherlock/tattoo/widget_tooltip.cpp
  A engines/sherlock/tattoo/widget_tooltip.h
  A engines/sherlock/tattoo/widget_verbs.cpp
  A engines/sherlock/tattoo/widget_verbs.h
  A engines/sherlock/user_interface.cpp
  A engines/sherlock/user_interface.h
  A engines/sword25/util/double_serialization.cpp
  A engines/sword25/util/double_serialization.h
  A engines/sword25/util/lua_persist.cpp
  A engines/sword25/util/lua_persistence.h
  A engines/sword25/util/lua_persistence_util.cpp
  A engines/sword25/util/lua_persistence_util.h
  A engines/sword25/util/lua_unpersist.cpp
  A engines/tsage/sherlock/sherlock_logo.cpp
  A engines/tsage/sherlock/sherlock_logo.h
  A engines/zvision/detection_tables.h
  A engines/zvision/file/save_manager.cpp
  A engines/zvision/file/save_manager.h
  A engines/zvision/graphics/graphics_effect.h
  A engines/zvision/scripting/effects/animation_effect.cpp
  A engines/zvision/scripting/effects/animation_effect.h
  A engines/zvision/scripting/effects/distort_effect.cpp
  A engines/zvision/scripting/effects/distort_effect.h
  A engines/zvision/scripting/effects/music_effect.cpp
  A engines/zvision/scripting/effects/music_effect.h
  A engines/zvision/scripting/effects/region_effect.cpp
  A engines/zvision/scripting/effects/region_effect.h
  A engines/zvision/scripting/effects/syncsound_effect.cpp
  A engines/zvision/scripting/effects/syncsound_effect.h
  A engines/zvision/scripting/effects/timer_effect.cpp
  A engines/zvision/scripting/effects/timer_effect.h
  A engines/zvision/scripting/effects/ttytext_effect.cpp
  A engines/zvision/scripting/effects/ttytext_effect.h
  A engines/zvision/scripting/menu.cpp
  A engines/zvision/scripting/menu.h
  A engines/zvision/scripting/scripting_effect.h
  A engines/zvision/text/subtitles.cpp
  A engines/zvision/text/subtitles.h
  A engines/zvision/text/truetype_font.cpp
  A engines/zvision/text/truetype_font.h
  A image/codecs/cinepak_tables.h
  A video/mpegps_decoder.cpp
  A video/mpegps_decoder.h
  R audio/softsynth/adlib.cpp
  R backends/platform/android/org/scummvm/scummvm/PluginProvider.java
  R backends/platform/android/org/scummvm/scummvm/ScummVMApplication.java
  R backends/platform/android/org/scummvm/scummvm/Unpacker.java
  R dists/android/mkplugin.sh
  R dists/android/plugin-manifest.xml
  R dists/android/plugin-manifest.xml.in
  R dists/android/plugin-strings.xml
  R dists/android/res/drawable/gradient.xml
  R dists/android/res/layout/splash.xml
  R dists/iphone/readme.txt
  R dists/iphone/scummvm.xcodeproj/project.pbxproj
  R engines/sword25/util/pluto/CHANGELOG
  R engines/sword25/util/pluto/FILEFORMAT
  R engines/sword25/util/pluto/README
  R engines/sword25/util/pluto/THANKS
  R engines/sword25/util/pluto/pdep.cpp
  R engines/sword25/util/pluto/pdep/README
  R engines/sword25/util/pluto/pdep/lzio.h
  R engines/sword25/util/pluto/pdep/pdep.h
  R engines/sword25/util/pluto/pluto.cpp
  R engines/sword25/util/pluto/pluto.h
  R engines/sword25/util/pluto/plzio.cpp
  R engines/zvision/core/menu.cpp
  R engines/zvision/core/menu.h
  R engines/zvision/core/save_manager.cpp
  R engines/zvision/core/save_manager.h
  R engines/zvision/detection.h
  R engines/zvision/graphics/effect.h
  R engines/zvision/graphics/subtitles.cpp
  R engines/zvision/graphics/subtitles.h
  R engines/zvision/graphics/truetype_font.cpp
  R engines/zvision/graphics/truetype_font.h
  R engines/zvision/scripting/sidefx.h
  R engines/zvision/scripting/sidefx/animation_node.cpp
  R engines/zvision/scripting/sidefx/animation_node.h
  R engines/zvision/scripting/sidefx/distort_node.cpp
  R engines/zvision/scripting/sidefx/distort_node.h
  R engines/zvision/scripting/sidefx/music_node.cpp
  R engines/zvision/scripting/sidefx/music_node.h
  R engines/zvision/scripting/sidefx/region_node.cpp
  R engines/zvision/scripting/sidefx/region_node.h
  R engines/zvision/scripting/sidefx/syncsound_node.cpp
  R engines/zvision/scripting/sidefx/syncsound_node.h
  R engines/zvision/scripting/sidefx/timer_node.cpp
  R engines/zvision/scripting/sidefx/timer_node.h
  R engines/zvision/scripting/sidefx/ttytext_node.cpp
  R engines/zvision/scripting/sidefx/ttytext_node.h
    AUTHORS
    COPYRIGHT
    Makefile
    NEWS
    README
    audio/decoders/aiff.cpp
    audio/decoders/aiff.h
    audio/decoders/mp3.cpp
    audio/decoders/quicktime.cpp
    audio/decoders/wave.h
    audio/fmopl.cpp
    audio/fmopl.h
    audio/midiparser.h
    audio/midiparser_xmidi.cpp
    audio/mods/protracker.cpp
    audio/module.mk
    audio/softsynth/mt32/BReverbModel.cpp
    audio/softsynth/mt32/BReverbModel.h
    audio/softsynth/mt32/LA32FloatWaveGenerator.cpp
    audio/softsynth/mt32/LA32Ramp.cpp
    audio/softsynth/mt32/LA32WaveGenerator.cpp
    audio/softsynth/mt32/Part.cpp
    audio/softsynth/mt32/Partial.cpp
    audio/softsynth/mt32/PartialManager.cpp
    audio/softsynth/mt32/Poly.cpp
    audio/softsynth/mt32/Poly.h
    audio/softsynth/mt32/ROMInfo.cpp
    audio/softsynth/mt32/ROMInfo.h
    audio/softsynth/mt32/Structures.h
    audio/softsynth/mt32/Synth.cpp
    audio/softsynth/mt32/Synth.h
    audio/softsynth/mt32/TVA.cpp
    audio/softsynth/mt32/TVF.cpp
    audio/softsynth/mt32/TVP.cpp
    audio/softsynth/mt32/Tables.cpp
    audio/softsynth/mt32/Tables.h
    audio/softsynth/mt32/module.mk
    audio/softsynth/mt32/mt32emu.h
    audio/softsynth/opl/dosbox.cpp
    audio/softsynth/opl/dosbox.h
    audio/softsynth/opl/mame.cpp
    audio/softsynth/opl/mame.h
    audio/timestamp.cpp
    backends/audiocd/sdl/sdl-audiocd.cpp
    backends/audiocd/sdl/sdl-audiocd.h
    backends/events/sdl/sdl-events.cpp
    backends/events/sdl/sdl-events.h
    backends/events/symbiansdl/symbiansdl-events.cpp
    backends/fs/amigaos4/amigaos4-fs.cpp
    backends/graphics/dinguxsdl/dinguxsdl-graphics.cpp
    backends/graphics/dinguxsdl/dinguxsdl-graphics.h
    backends/graphics/gph/gph-graphics.cpp
    backends/graphics/gph/gph-graphics.h
    backends/graphics/linuxmotosdl/linuxmotosdl-graphics.cpp
    backends/graphics/linuxmotosdl/linuxmotosdl-graphics.h
    backends/graphics/maemosdl/maemosdl-graphics.cpp
    backends/graphics/maemosdl/maemosdl-graphics.h
    backends/graphics/opengl/opengl-graphics.cpp
    backends/graphics/opengl/opengl-graphics.h
    backends/graphics/openglsdl/openglsdl-graphics.cpp
    backends/graphics/openglsdl/openglsdl-graphics.h
    backends/graphics/openpandora/op-graphics.cpp
    backends/graphics/openpandora/op-graphics.h
    backends/graphics/samsungtvsdl/samsungtvsdl-graphics.cpp
    backends/graphics/samsungtvsdl/samsungtvsdl-graphics.h
    backends/graphics/sdl/sdl-graphics.cpp
    backends/graphics/sdl/sdl-graphics.h
    backends/graphics/surfacesdl/surfacesdl-graphics.cpp
    backends/graphics/surfacesdl/surfacesdl-graphics.h
    backends/graphics/symbiansdl/symbiansdl-graphics.cpp
    backends/graphics/symbiansdl/symbiansdl-graphics.h
    backends/graphics/wincesdl/wincesdl-graphics.cpp
    backends/graphics/wincesdl/wincesdl-graphics.h
    backends/log/log.cpp
    backends/mixer/doublebuffersdl/doublebuffersdl-mixer.cpp
    backends/mixer/sdl/sdl-mixer.cpp
    backends/module.mk
    backends/platform/android/android.cpp
    backends/platform/android/android.h
    backends/platform/android/android.mk
    backends/platform/android/jni.cpp
    backends/platform/android/jni.h
    backends/platform/android/org/scummvm/scummvm/ScummVM.java
    backends/platform/android/org/scummvm/scummvm/ScummVMActivity.java
    backends/platform/dingux/dingux.cpp
    backends/platform/gph/gph-backend.cpp
    backends/platform/linuxmoto/linuxmoto-sdl.cpp
    backends/platform/maemo/maemo.cpp
    backends/platform/maemo/maemo.h
    backends/platform/openpandora/op-backend.cpp
    backends/platform/samsungtv/samsungtv.cpp
    backends/platform/sdl/macosx/macosx.cpp
    backends/platform/sdl/macosx/macosx.h
    backends/platform/sdl/module.mk
    backends/platform/sdl/sdl-sys.h
    backends/platform/sdl/sdl.cpp
    backends/platform/sdl/sdl.h
    backends/platform/sdl/win32/win32-main.cpp
    backends/platform/sdl/win32/win32.cpp
    backends/platform/sdl/win32/win32.h
    backends/platform/symbian/AdaptAllMMPs.pl
    backends/platform/symbian/BuildPackageUpload_LocalSettings.pl
    backends/platform/symbian/README
    backends/platform/symbian/S60/ScummVM_S60.mmp.in
    backends/platform/symbian/S60/ScummVM_S60_App.mmp
    backends/platform/symbian/S60v3/ScummVM_A0000658_S60v3.mmp.in
    backends/platform/symbian/S60v3/ScummVM_S60v3.mmp.in
    backends/platform/symbian/S80/ScummVM_S80.mmp.in
    backends/platform/symbian/S80/ScummVM_S80_App.mmp
    backends/platform/symbian/S90/Scummvm_S90.mmp.in
    backends/platform/symbian/S90/Scummvm_S90_App.mmp
    backends/platform/symbian/UIQ2/ScummVM.rss
    backends/platform/symbian/UIQ3/ScummVM.rss
    backends/platform/symbian/UIQ3/ScummVM_A0000658.rss
    backends/platform/symbian/UIQ3/ScummVM_A0000658_UIQ3.mmp.in
    backends/platform/symbian/UIQ3/ScummVM_UIQ3.mmp.in
    backends/platform/symbian/UIQ3/scummvm_A0000658_loc.rss
    backends/platform/symbian/help/ScummVM.rtf
    backends/platform/symbian/mmp/config.mmh
    backends/platform/symbian/mmp/scummvm_agi.mmp.in
    backends/platform/symbian/mmp/scummvm_agos.mmp.in
    backends/platform/symbian/mmp/scummvm_avalanche.mmp.in
    backends/platform/symbian/mmp/scummvm_base.mmp.in
    backends/platform/symbian/mmp/scummvm_bbvs.mmp.in
    backends/platform/symbian/mmp/scummvm_cge.mmp.in
    backends/platform/symbian/mmp/scummvm_cge2.mmp.in
    backends/platform/symbian/mmp/scummvm_cine.mmp.in
    backends/platform/symbian/mmp/scummvm_composer.mmp.in
    backends/platform/symbian/mmp/scummvm_cruise.mmp.in
    backends/platform/symbian/mmp/scummvm_draci.mmp.in
    backends/platform/symbian/mmp/scummvm_drascula.mmp.in
    backends/platform/symbian/mmp/scummvm_dreamweb.mmp.in
    backends/platform/symbian/mmp/scummvm_fullpipe.mmp.in
    backends/platform/symbian/mmp/scummvm_gob.mmp.in
    backends/platform/symbian/mmp/scummvm_groovie.mmp.in
    backends/platform/symbian/mmp/scummvm_hopkins.mmp.in
    backends/platform/symbian/mmp/scummvm_hugo.mmp.in
    backends/platform/symbian/mmp/scummvm_kyra.mmp.in
    backends/platform/symbian/mmp/scummvm_lastexpress.mmp.in
    backends/platform/symbian/mmp/scummvm_lure.mmp.in
    backends/platform/symbian/mmp/scummvm_m4.mmp.in
    backends/platform/symbian/mmp/scummvm_made.mmp.in
    backends/platform/symbian/mmp/scummvm_mads.mmp.in
    backends/platform/symbian/mmp/scummvm_mohawk.mmp.in
    backends/platform/symbian/mmp/scummvm_mortevielle.mmp.in
    backends/platform/symbian/mmp/scummvm_neverhood.mmp.in
    backends/platform/symbian/mmp/scummvm_parallaction.mmp.in
    backends/platform/symbian/mmp/scummvm_pegasus.mmp.in
    backends/platform/symbian/mmp/scummvm_queen.mmp.in
    backends/platform/symbian/mmp/scummvm_saga.mmp.in
    backends/platform/symbian/mmp/scummvm_sci.mmp.in
    backends/platform/symbian/mmp/scummvm_scumm.mmp.in
    backends/platform/symbian/mmp/scummvm_sky.mmp.in
    backends/platform/symbian/mmp/scummvm_sword1.mmp.in
    backends/platform/symbian/mmp/scummvm_sword2.mmp.in
    backends/platform/symbian/mmp/scummvm_sword25.mmp.in
    backends/platform/symbian/mmp/scummvm_teenagent.mmp.in
    backends/platform/symbian/mmp/scummvm_testbed.mmp.in
    backends/platform/symbian/mmp/scummvm_tinsel.mmp.in
    backends/platform/symbian/mmp/scummvm_toltecs.mmp.in
    backends/platform/symbian/mmp/scummvm_tony.mmp.in
    backends/platform/symbian/mmp/scummvm_toon.mmp.in
    backends/platform/symbian/mmp/scummvm_touche.mmp.in
    backends/platform/symbian/mmp/scummvm_tsage.mmp.in
    backends/platform/symbian/mmp/scummvm_tucker.mmp.in
    backends/platform/symbian/mmp/scummvm_voyeur.mmp.in
    backends/platform/symbian/mmp/scummvm_wintermute.mmp.in
    backends/platform/symbian/mmp/scummvm_zvision.mmp.in
    backends/platform/symbian/res/ScummVmAif.rss
    backends/platform/symbian/res/scummvm.rss
    backends/platform/symbian/res/scummvm_A0000658.rss
    backends/platform/symbian/src/ScummVm.hrh
    backends/platform/symbian/src/SymbianOS.cpp
    backends/platform/symbian/src/SymbianOS.h
    backends/platform/wince/wince-sdl.cpp
    backends/taskbar/win32/win32-taskbar.cpp
    backends/taskbar/win32/win32-taskbar.h
    base/main.cpp
    common/dcl.cpp
    common/dcl.h
    common/endian.h
    common/fft.cpp
    common/fft.h
    common/stream.h
    configure
    devtools/create_project/create_project.cpp
    devtools/create_project/xcode.cpp
    devtools/create_project/xcode.h
    devtools/credits.pl
    devtools/scumm-md5.txt
    dists/android/AndroidManifest.xml
    dists/android/AndroidManifest.xml.in
    dists/android/res/layout/main.xml
    dists/codeblocks/readme.txt
    dists/debian/copyright
    dists/macosx/Info.plist
    dists/macosx/Info.plist.in
    dists/scummvm.rc
    dists/scummvm.rc.in
    dists/win32/scummvm.nsi
    dists/win32/scummvm.nsi.in
    doc/de/Liesmich
    doc/de/Neues
    engines/access/access.cpp
    engines/access/amazon/amazon_game.cpp
    engines/access/amazon/amazon_logic.cpp
    engines/access/amazon/amazon_logic.h
    engines/access/amazon/amazon_scripts.cpp
    engines/access/animation.cpp
    engines/access/animation.h
    engines/access/asurface.cpp
    engines/access/asurface.h
    engines/access/bubble_box.h
    engines/access/char.cpp
    engines/access/char.h
    engines/access/decompress.cpp
    engines/access/decompress.h
    engines/access/events.cpp
    engines/access/files.cpp
    engines/access/files.h
    engines/access/font.cpp
    engines/access/inventory.cpp
    engines/access/player.cpp
    engines/access/player.h
    engines/access/resources.cpp
    engines/access/room.cpp
    engines/access/room.h
    engines/access/screen.cpp
    engines/access/screen.h
    engines/access/scripts.cpp
    engines/access/sound.cpp
    engines/access/sound.h
    engines/access/video.cpp
    engines/agi/agi.cpp
    engines/agi/agi.h
    engines/agi/detection.cpp
    engines/agi/detection_tables.h
    engines/agi/font.h
    engines/agi/graphics.cpp
    engines/agi/graphics.h
    engines/agi/loader_v2.cpp
    engines/agi/loader_v3.cpp
    engines/agi/preagi.cpp
    engines/agi/preagi_mickey.cpp
    engines/agi/sound_pcjr.cpp
    engines/agi/text.cpp
    engines/agos/agos.cpp
    engines/agos/detection_tables.h
    engines/agos/gfx.cpp
    engines/agos/input.cpp
    engines/agos/midi.cpp
    engines/agos/midi.h
    engines/agos/midiparser_s1d.cpp
    engines/agos/module.mk
    engines/agos/res_snd.cpp
    engines/agos/rooms.cpp
    engines/agos/saveload.cpp
    engines/agos/sound.cpp
    engines/agos/zones.cpp
    engines/bbvs/minigames/bbairguitar.cpp
    engines/bbvs/minigames/bbairguitar.h
    engines/bbvs/sound.h
    engines/cge2/detection.cpp
    engines/cine/detection_tables.h
    engines/cine/sound.cpp
    engines/cruise/sound.cpp
    engines/drascula/actors.cpp
    engines/drascula/detection.cpp
    engines/drascula/talk.cpp
    engines/engine.cpp
    engines/engine.h
    engines/fullpipe/gameloader.cpp
    engines/fullpipe/inventory.cpp
    engines/fullpipe/mgm.cpp
    engines/fullpipe/modal.cpp
    engines/fullpipe/motion.cpp
    engines/fullpipe/scene.cpp
    engines/fullpipe/scenes/scene04.cpp
    engines/fullpipe/scenes/scene16.cpp
    engines/fullpipe/scenes/scene23.cpp
    engines/fullpipe/statics.cpp
    engines/gob/gob.cpp
    engines/gob/sound/adlib.cpp
    engines/gob/sound/adlib.h
    engines/gob/sound/adlplayer.cpp
    engines/gob/sound/adlplayer.h
    engines/gob/sound/musplayer.cpp
    engines/gob/sound/musplayer.h
    engines/gob/sound/sound.cpp
    engines/gob/sound/sound.h
    engines/gob/surface.cpp
    engines/gob/surface.h
    engines/groovie/music.cpp
    engines/groovie/music.h
    engines/hopkins/lines.cpp
    engines/hugo/mouse.cpp
    engines/kyra/sound_adlib.cpp
    engines/lure/res.h
    engines/made/database.cpp
    engines/made/made.cpp
    engines/made/music.cpp
    engines/made/music.h
    engines/made/pmvplayer.cpp
    engines/made/redreader.cpp
    engines/made/resource.cpp
    engines/made/screenfx.cpp
    engines/made/screenfx.h
    engines/made/script.cpp
    engines/made/script.h
    engines/made/scriptfuncs.cpp
    engines/made/sound.cpp
    engines/made/sound.h
    engines/mads/action.cpp
    engines/mads/action.h
    engines/mads/animation.cpp
    engines/mads/animation.h
    engines/mads/assets.cpp
    engines/mads/assets.h
    engines/mads/audio.cpp
    engines/mads/audio.h
    engines/mads/compression.cpp
    engines/mads/compression.h
    engines/mads/debugger.cpp
    engines/mads/debugger.h
    engines/mads/detection.cpp
    engines/mads/detection_tables.h
    engines/mads/dialogs.cpp
    engines/mads/dialogs.h
    engines/mads/dragonsphere/dragonsphere_scenes.cpp
    engines/mads/dragonsphere/dragonsphere_scenes.h
    engines/mads/dragonsphere/game_dragonsphere.cpp
    engines/mads/dragonsphere/game_dragonsphere.h
    engines/mads/events.cpp
    engines/mads/events.h
    engines/mads/font.cpp
    engines/mads/font.h
    engines/mads/game.cpp
    engines/mads/game.h
    engines/mads/game_data.cpp
    engines/mads/game_data.h
    engines/mads/globals.cpp
    engines/mads/globals.h
    engines/mads/hotspots.cpp
    engines/mads/hotspots.h
    engines/mads/inventory.cpp
    engines/mads/inventory.h
    engines/mads/mads.cpp
    engines/mads/mads.h
    engines/mads/menu_views.cpp
    engines/mads/menu_views.h
    engines/mads/messages.cpp
    engines/mads/messages.h
    engines/mads/module.mk
    engines/mads/msurface.cpp
    engines/mads/msurface.h
    engines/mads/nebular/dialogs_nebular.cpp
    engines/mads/nebular/dialogs_nebular.h
    engines/mads/nebular/game_nebular.cpp
    engines/mads/nebular/game_nebular.h
    engines/mads/nebular/globals_nebular.cpp
    engines/mads/nebular/globals_nebular.h
    engines/mads/nebular/menu_nebular.cpp
    engines/mads/nebular/menu_nebular.h
    engines/mads/nebular/nebular_scenes.cpp
    engines/mads/nebular/nebular_scenes.h
    engines/mads/nebular/nebular_scenes1.cpp
    engines/mads/nebular/nebular_scenes1.h
    engines/mads/nebular/nebular_scenes2.cpp
    engines/mads/nebular/nebular_scenes2.h
    engines/mads/nebular/nebular_scenes3.cpp
    engines/mads/nebular/nebular_scenes3.h
    engines/mads/nebular/nebular_scenes4.cpp
    engines/mads/nebular/nebular_scenes4.h
    engines/mads/nebular/nebular_scenes5.cpp
    engines/mads/nebular/nebular_scenes5.h
    engines/mads/nebular/nebular_scenes6.cpp
    engines/mads/nebular/nebular_scenes6.h
    engines/mads/nebular/nebular_scenes7.cpp
    engines/mads/nebular/nebular_scenes7.h
    engines/mads/nebular/nebular_scenes8.cpp
    engines/mads/nebular/nebular_scenes8.h
    engines/mads/nebular/sound_nebular.cpp
    engines/mads/nebular/sound_nebular.h
    engines/mads/palette.cpp
    engines/mads/palette.h
    engines/mads/phantom/game_phantom.cpp
    engines/mads/phantom/game_phantom.h
    engines/mads/phantom/phantom_scenes.cpp
    engines/mads/phantom/phantom_scenes.h
    engines/mads/player.cpp
    engines/mads/player.h
    engines/mads/rails.cpp
    engines/mads/rails.h
    engines/mads/resources.cpp
    engines/mads/resources.h
    engines/mads/scene.cpp
    engines/mads/scene.h
    engines/mads/scene_data.cpp
    engines/mads/scene_data.h
    engines/mads/screen.cpp
    engines/mads/screen.h
    engines/mads/sequence.cpp
    engines/mads/sequence.h
    engines/mads/sound.cpp
    engines/mads/sound.h
    engines/mads/sprites.cpp
    engines/mads/sprites.h
    engines/mads/staticres.cpp
    engines/mads/staticres.h
    engines/mads/user_interface.cpp
    engines/mads/user_interface.h
    engines/mohawk/configure.engine
    engines/mohawk/console.cpp
    engines/mohawk/cursors.cpp
    engines/mohawk/detection_tables.h
    engines/mohawk/livingbooks.cpp
    engines/mohawk/livingbooks_code.cpp
    engines/mohawk/livingbooks_code.h
    engines/mohawk/myst.cpp
    engines/mohawk/myst_areas.cpp
    engines/mohawk/myst_graphics.cpp
    engines/mohawk/myst_graphics.h
    engines/mohawk/myst_stacks/channelwood.cpp
    engines/mohawk/myst_stacks/dni.cpp
    engines/mohawk/myst_stacks/intro.cpp
    engines/mohawk/myst_stacks/mechanical.cpp
    engines/mohawk/myst_stacks/myst.cpp
    engines/mohawk/myst_stacks/stoneship.cpp
    engines/mohawk/riven.cpp
    engines/mohawk/riven_external.cpp
    engines/mohawk/riven_scripts.cpp
    engines/mohawk/video.cpp
    engines/mohawk/video.h
    engines/mortevielle/actions.cpp
    engines/mortevielle/dialogs.cpp
    engines/mortevielle/graphics.cpp
    engines/mortevielle/mortevielle.h
    engines/mortevielle/outtext.cpp
    engines/mortevielle/utils.cpp
    engines/neverhood/menumodule.cpp
    engines/parallaction/adlib.cpp
    engines/pegasus/menu.cpp
    engines/pegasus/sound.cpp
    engines/queen/midiadlib.cpp
    engines/queen/music.cpp
    engines/queen/walk.cpp
    engines/saga/detection_tables.h
    engines/saga/introproc_ihnm.cpp
    engines/saga/introproc_ite.cpp
    engines/saga/music.cpp
    engines/saga/music.h
    engines/saga/saga.cpp
    engines/saga/saga.h
    engines/saga/scene.cpp
    engines/saga/scene.h
    engines/saga/script.cpp
    engines/saga/sndres.cpp
    engines/sci/console.cpp
    engines/sci/console.h
    engines/sci/detection.cpp
    engines/sci/detection_tables.h
    engines/sci/engine/file.cpp
    engines/sci/engine/kernel.cpp
    engines/sci/engine/kernel.h
    engines/sci/engine/kernel_tables.h
    engines/sci/engine/kevent.cpp
    engines/sci/engine/kfile.cpp
    engines/sci/engine/kgraphics.cpp
    engines/sci/engine/kmovement.cpp
    engines/sci/engine/kparse.cpp
    engines/sci/engine/kvideo.cpp
    engines/sci/engine/savegame.cpp
    engines/sci/engine/savegame.h
    engines/sci/engine/script.cpp
    engines/sci/engine/script.h
    engines/sci/engine/script_patches.cpp
    engines/sci/engine/script_patches.h
    engines/sci/engine/state.cpp
    engines/sci/engine/state.h
    engines/sci/engine/vm.cpp
    engines/sci/engine/workarounds.cpp
    engines/sci/engine/workarounds.h
    engines/sci/graphics/paint16.cpp
    engines/sci/graphics/portrait.cpp
    engines/sci/graphics/screen.cpp
    engines/sci/graphics/screen.h
    engines/sci/parser/vocabulary.cpp
    engines/sci/parser/vocabulary.h
    engines/sci/resource.h
    engines/sci/resource_audio.cpp
    engines/sci/sci.cpp
    engines/sci/sci.h
    engines/sci/sound/audio.cpp
    engines/sci/sound/drivers/adlib.cpp
    engines/sci/sound/midiparser_sci.cpp
    engines/sci/sound/music.cpp
    engines/sci/sound/music.h
    engines/sci/sound/soundcmd.cpp
    engines/sci/sound/soundcmd.h
    engines/scumm/debugger.cpp
    engines/scumm/detection_tables.h
    engines/scumm/help.cpp
    engines/scumm/players/player_ad.cpp
    engines/scumm/players/player_ad.h
    engines/scumm/saveload.cpp
    engines/scumm/script_v6.cpp
    engines/scumm/scumm-md5.h
    engines/scumm/scumm.cpp
    engines/scumm/scumm.h
    engines/scumm/smush/smush_player.cpp
    engines/scumm/string.cpp
    engines/sky/music/adlibchannel.cpp
    engines/sky/music/adlibchannel.h
    engines/sky/music/adlibmusic.cpp
    engines/sky/music/adlibmusic.h
    engines/sword25/fmv/movieplayer.cpp
    engines/sword25/kernel/outputpersistenceblock.cpp
    engines/sword25/kernel/outputpersistenceblock.h
    engines/sword25/module.mk
    engines/sword25/script/luascript.cpp
    engines/tinsel/music.cpp
    engines/tinsel/music.h
    engines/tinsel/tinsel.cpp
    engines/toltecs/music.cpp
    engines/toltecs/music.h
    engines/tony/mpal/mpal.cpp
    engines/tony/window.cpp
    engines/toon/anim.cpp
    engines/toon/character.cpp
    engines/toon/font.cpp
    engines/toon/toon.cpp
    engines/toon/toon.h
    engines/tsage/blue_force/blueforce_scenes8.cpp
    engines/tsage/blue_force/blueforce_scenes8.h
    engines/tsage/blue_force/blueforce_scenes9.cpp
    engines/tsage/core.cpp
    engines/tsage/detection.cpp
    engines/tsage/detection_tables.h
    engines/tsage/globals.cpp
    engines/tsage/graphics.cpp
    engines/tsage/graphics.h
    engines/tsage/module.mk
    engines/tsage/resources.h
    engines/tsage/ringworld/ringworld_scenes3.cpp
    engines/tsage/ringworld/ringworld_scenes3.h
    engines/tsage/sound.cpp
    engines/tsage/sound.h
    engines/tsage/tsage.cpp
    engines/tsage/tsage.h
    engines/voyeur/events.cpp
    engines/voyeur/files_threads.cpp
    engines/wintermute/base/base_file_manager.cpp
    engines/wintermute/base/base_keyboard_state.cpp
    engines/wintermute/base/base_keyboard_state.h
    engines/wintermute/base/base_script_holder.cpp
    engines/wintermute/debugger.cpp
    engines/zvision/configure.engine
    engines/zvision/core/clock.h
    engines/zvision/core/console.cpp
    engines/zvision/core/console.h
    engines/zvision/core/events.cpp
    engines/zvision/detection.cpp
    engines/zvision/file/lzss_read_stream.cpp
    engines/zvision/file/search_manager.cpp
    engines/zvision/file/search_manager.h
    engines/zvision/graphics/cursors/cursor.cpp
    engines/zvision/graphics/cursors/cursor.h
    engines/zvision/graphics/cursors/cursor_manager.cpp
    engines/zvision/graphics/cursors/cursor_manager.h
    engines/zvision/graphics/effects/fog.cpp
    engines/zvision/graphics/effects/fog.h
    engines/zvision/graphics/effects/light.cpp
    engines/zvision/graphics/effects/light.h
    engines/zvision/graphics/effects/wave.cpp
    engines/zvision/graphics/effects/wave.h
    engines/zvision/graphics/render_manager.cpp
    engines/zvision/graphics/render_manager.h
    engines/zvision/graphics/render_table.cpp
    engines/zvision/module.mk
    engines/zvision/scripting/actions.cpp
    engines/zvision/scripting/actions.h
    engines/zvision/scripting/control.cpp
    engines/zvision/scripting/control.h
    engines/zvision/scripting/controls/fist_control.cpp
    engines/zvision/scripting/controls/fist_control.h
    engines/zvision/scripting/controls/hotmov_control.cpp
    engines/zvision/scripting/controls/hotmov_control.h
    engines/zvision/scripting/controls/input_control.cpp
    engines/zvision/scripting/controls/input_control.h
    engines/zvision/scripting/controls/lever_control.cpp
    engines/zvision/scripting/controls/lever_control.h
    engines/zvision/scripting/controls/paint_control.cpp
    engines/zvision/scripting/controls/paint_control.h
    engines/zvision/scripting/controls/safe_control.cpp
    engines/zvision/scripting/controls/safe_control.h
    engines/zvision/scripting/controls/save_control.cpp
    engines/zvision/scripting/controls/titler_control.cpp
    engines/zvision/scripting/controls/titler_control.h
    engines/zvision/scripting/scr_file_handling.cpp
    engines/zvision/scripting/script_manager.cpp
    engines/zvision/scripting/script_manager.h
    engines/zvision/sound/zork_raw.cpp
    engines/zvision/sound/zork_raw.h
    engines/zvision/text/string_manager.cpp
    engines/zvision/text/string_manager.h
    engines/zvision/text/text.cpp
    engines/zvision/text/text.h
    engines/zvision/video/rlf_decoder.cpp
    engines/zvision/video/rlf_decoder.h
    engines/zvision/video/video.cpp
    engines/zvision/video/zork_avi_decoder.cpp
    engines/zvision/zvision.cpp
    engines/zvision/zvision.h
    graphics/fonts/ttf.cpp
    gui/Tooltip.cpp
    gui/Tooltip.h
    gui/about.cpp
    gui/credits.h
    gui/debugger.cpp
    gui/dialog.cpp
    gui/launcher.cpp
    gui/options.cpp
    gui/saveload-dialog.cpp
    gui/themes/translations.dat
    icons/scummvm.info
    icons/scummvm_drawer.info
    image/codecs/cinepak.cpp
    image/codecs/cinepak.h
    image/codecs/codec.cpp
    image/codecs/codec.h
    image/codecs/qtrle.cpp
    image/codecs/qtrle.h
    image/codecs/rpza.cpp
    image/codecs/rpza.h
    po/POTFILES
    po/be_BY.po
    po/ca_ES.po
    po/cs_CZ.po
    po/da_DA.po
    po/de_DE.po
    po/es_ES.po
    po/eu.po
    po/fi_FI.po
    po/fr_FR.po
    po/gl_ES.po
    po/hu_HU.po
    po/it_IT.po
    po/nb_NO.po
    po/nl_NL.po
    po/nn_NO.po
    po/pl_PL.po
    po/pt_BR.po
    po/ru_RU.po
    po/scummvm.pot
    po/se_SE.po
    po/uk_UA.po
    ports.mk
    test/audio/timestamp.h
    test/common/endian.h
    test/common/memoryreadstream.h
    test/common/memoryreadstreamendian.h
    test/cxxtest/cxxtestgen.py
    video/avi_decoder.cpp
    video/avi_decoder.h
    video/module.mk
    video/qt_decoder.cpp
    video/qt_decoder.h
    video/theora_decoder.cpp
    video/theora_decoder.h
    video/video_decoder.cpp
    video/video_decoder.h



diff --cc engines/access/access.cpp
index 9749706,0a4e519..3fd5c06
--- a/engines/access/access.cpp
+++ b/engines/access/access.cpp
@@@ -91,24 -93,10 +92,28 @@@ AccessEngine::AccessEngine(OSystem *sys
  	_vidX = _vidY = 0;
  	_cheatFl = false;
  	_restartFl = false;
+ 	_printEnd = 0;
+ 	for (int i = 0; i < 100; i++)
+ 		_objectsTable[i] = nullptr;
+ 	_clearSummaryFlag = false;
 +
 +	for (int i = 0; i < 60; i++)
 +		TRAVEL[i] = 0;
 +	STARTTRAVELITEM = STARTTRAVELBOX = 0;
 +	for (int i = 0; i < 33; i++)
 +		ASK[i];
 +	_startAboutItem = _startAboutBox = 0;
 +	_byte26CB5 = 0;
 +	BCNT = 0;
 +	BOXDATASTART = 0;
 +	BOXDATAEND = false;
 +	BOXSELECTY = 0;
 +	BOXSELECTYOLD = -1;
 +	NUMBLINES = 0;
 +	TEMPLIST = nullptr;
 +	_pictureTaken = 0;
 +
 +	_vidEnd = false;
  }
  
  AccessEngine::~AccessEngine() {
diff --cc engines/access/asurface.h
index 0c656a0,4fb47b9..022e253
--- a/engines/access/asurface.h
+++ b/engines/access/asurface.h
@@@ -95,19 -95,13 +95,19 @@@ public
  
  	virtual void drawRect();
  
 +	virtual void drawLine(int x1, int y1, int x2, int y2, int col);
 +
 +	virtual void drawLine();
 +
 +	virtual void drawBox();
++	
+ 	virtual void transBlitFrom(ASurface *src, const Common::Point &destPos);
  
- 	virtual void transCopyFrom(ASurface *src, const Common::Point &destPos);
+ 	virtual void transBlitFrom(ASurface *src, const Common::Rect &bounds);
  
- 	virtual void transCopyFrom(ASurface *src, const Common::Rect &bounds);
+ 	virtual void transBlitFrom(ASurface &src);
  
- 	virtual void transCopyFrom(ASurface &src);
- 
- 	virtual void copyFrom(Graphics::Surface &src);
+ 	virtual void blitFrom(Graphics::Surface &src);
  
  	virtual void copyBuffer(Graphics::Surface *src);
  
diff --cc engines/access/bubble_box.h
index 35b7ca2,0b3f139..6bf752d
--- a/engines/access/bubble_box.h
+++ b/engines/access/bubble_box.h
@@@ -63,20 -49,10 +63,19 @@@ public
  	Common::StringArray _nameIndex;
  	Common::String _bubbleTitle;
  	Common::String _bubbleDisplStr;
 -
 +	Common::String _tempList[60];
 +	int _tempListIdx[60];
 +	int _btnId1;
 +	int _btnX1;
 +	int _btnId2;
 +	int _btnX2;
 +	int _btnId3;
 +	int _btnX3;
 +	Common::Rect _btnUpPos;
 +	Common::Rect _btnDownPos;
- 
  	Common::Array<Common::Rect> _bubbles;
  public:
 -	BubbleBox(AccessEngine *vm);
 +	BubbleBox(AccessEngine *vm, Access::BoxType type, int x, int y, int w, int h, int val1, int val2, int val3, int val4, Common::String title);
  
  	void load(Common::SeekableReadStream *stream);
  
diff --cc engines/access/player.cpp
index b4af672,5a2b982..ead2402
--- a/engines/access/player.cpp
+++ b/engines/access/player.cpp
@@@ -74,10 -72,12 +73,16 @@@ Player::Player(AccessEngine *vm) : Mana
  	_playerDirection = NONE;
  	_xFlag = _yFlag = 0;
  	_inactiveYOff = 0;
+ 
+ 	_sideWalkMin = _sideWalkMax = 0;
+ 	_upWalkMin = _upWalkMax = 0;
+ 	_downWalkMin = _downWalkMax = 0;
+ 	_diagUpWalkMin = _diagUpWalkMax = 0;
+ 	_diagDownWalkMin = _diagDownWalkMax = 0;
 +	_walkOffRight = _walkOffLeft = nullptr;
 +	_walkOffUp = _walkOffDown = nullptr;
 +	_walkOffUR = _walkOffDR = nullptr;
 +	_walkOffUL = _walkOffDL = nullptr;
  }
  
  Player::~Player() {
diff --cc engines/access/player.h
index f3df2d0,329cc15..3c55455
--- a/engines/access/player.h
+++ b/engines/access/player.h
@@@ -78,16 -84,14 +78,15 @@@ public
  	Direction _playerDirection;
  	SpriteResource *_playerSprites;
  	// Fields in original Player structure
 -	int _walkOffRight[PLAYER_DATA_COUNT];
 -	int _walkOffLeft[PLAYER_DATA_COUNT];
 -	int _walkOffUp[PLAYER_DATA_COUNT];
 -	int _walkOffDown[PLAYER_DATA_COUNT];
 -	Common::Point _walkOffUR[PLAYER_DATA_COUNT];
 -	Common::Point _walkOffDR[PLAYER_DATA_COUNT];
 -	Common::Point _walkOffUL[PLAYER_DATA_COUNT];
 -	Common::Point _walkOffDL[PLAYER_DATA_COUNT];
 +	byte *_manPal1;
- 	byte *_monData;
 +	int *_walkOffRight;
 +	int *_walkOffLeft;
 +	int *_walkOffUp;
 +	int *_walkOffDown;
 +	Common::Point *_walkOffUR;
 +	Common::Point *_walkOffDR;
 +	Common::Point *_walkOffUL;
 +	Common::Point *_walkOffDL;
  	byte _rawTempL;
  	int _rawXTemp;
  	byte _rawYTempL;
diff --cc engines/access/resources.cpp
index b1cc648,0494840..8699a4a
--- a/engines/access/resources.cpp
+++ b/engines/access/resources.cpp
@@@ -46,17 -46,35 +46,17 @@@ const byte INITIAL_PALETTE[18 * 3] = 
  	0x00, 0x00, 0x00
  };
  
- const char *const LOOK_MESSAGE = "LOOKING THERE REVEALS NOTHING OF INTEREST.";
- const char *const GET_MESSAGE  = "YOU CAN'T TAKE THAT.";
- const char *const OPEN_MESSAGE = "THAT DOESN'T OPEN.";
- const char *const MOVE_MESSAGE = "THAT WON'T MOVE.";
- const char *const USE_MESSAGE  = "THAT DOESN'T SEEM TO WORK.";
- const char *const GO_MESSAGE   = "YOU CAN'T CLIMB THAT.";
- const char *const HELP_MESSAGE = "THIS OBJECT REQUIRES NO HINTS";
- const char *const TALK_MESSAGE = "THERE SEEMS TO BE NO RESPONSE.";
 -const int SIDEOFFR[] = { 5, 5, 5, 5, 5, 5, 5, 5, 0 };
 -const int SIDEOFFL[] = { 5, 5, 5, 5, 5, 5, 5, 5, 0 };
 -const int SIDEOFFU[] = { 2, 2, 2, 2, 2, 2, 2, 2, 0 };
 -const int SIDEOFFD[] = { 2, 2, 2, 2, 2, 2, 2, 2, 0 };
 -const int DIAGOFFURX[] = { 4, 5, 2, 2, 3, 4, 2, 2, 0 };
 -const int DIAGOFFURY[] = { 2, 3, 2, 2, 2, 3, 1, 1, 0 };
 -const int DIAGOFFDRX[] = { 4, 5, 4, 3, 5, 4, 5, 1, 0 };
 -const int DIAGOFFDRY[] = { 3, 2, 1, 2, 2, 1, 2, 1, 0 };
 -const int DIAGOFFULX[] = { 4, 5, 4, 3, 3, 2, 2, 2, 0 };
 -const int DIAGOFFULY[] = { 3, 3, 1, 2, 2, 1, 1, 1, 0 };
 -const int DIAGOFFDLX[] = { 4, 5, 3, 3, 5, 4, 6, 1, 0 };
 -const int DIAGOFFDLY[] = { 2, 2, 1, 2, 3, 1, 2, 1, 0 };
 -
 -const int RMOUSE[10][2] = {
 -	{ 0, 35 }, { 0, 0 }, { 36, 70 }, { 71, 106 }, { 107, 141 },
 -	{ 142, 177 }, { 178, 212 }, { 213, 248 }, { 249, 283 }, { 284, 318 }
 -};
 -
  const char *const GENERAL_MESSAGES[] = {
- 	LOOK_MESSAGE, OPEN_MESSAGE, MOVE_MESSAGE, GET_MESSAGE, USE_MESSAGE,
- 	GO_MESSAGE, TALK_MESSAGE, HELP_MESSAGE, HELP_MESSAGE, USE_MESSAGE
+ 	"LOOKING THERE REVEALS NOTHING OF INTEREST.", // LOOK_MESSAGE
+ 	"THAT DOESN'T OPEN.",               // OPEN_MESSAGE
+ 	"THAT WON'T MOVE."                  // MOVE_MESSAGE
+ 	"YOU CAN'T TAKE THAT.",             // GET_MESSAGE
+ 	"THAT DOESN'T SEEM TO WORK.",       // USE_MESSAGE
+ 	"YOU CAN'T CLIMB THAT.",            // GO_MESSAGE
+ 	"THERE SEEMS TO BE NO RESPONSE.",   // TALK_MESSAGE
+ 	"THIS OBJECT REQUIRES NO HINTS",    // HELP_MESSAGE
+ 	"THIS OBJECT REQUIRES NO HINTS",    // HELP_MESSAGE
+ 	"THAT DOESN'T SEEM TO WORK.",       // USE_MESSAGE
  };
  
  const int INVCOORDS[][4] = {
diff --cc engines/access/room.h
index 022d940,eec273e..12e7375
--- a/engines/access/room.h
+++ b/engines/access/room.h
@@@ -128,10 -124,8 +128,9 @@@ public
  	int _playFieldWidth;
  	int _playFieldHeight;
  	byte *_tile;
- 	int _tileSize;
  	int _selectCommand;
  	bool _conFlag;
 +	int _rMouse[10][2];
  public:
  	Room(AccessEngine *vm);
  
diff --cc engines/access/screen.cpp
index 5130d8e,2ecbb4f..9392dec
--- a/engines/access/screen.cpp
+++ b/engines/access/screen.cpp
@@@ -276,24 -267,19 +277,24 @@@ void Screen::drawRect() 
  	ASurface::drawRect();
  }
  
 +void Screen::drawBox() {
 +	addDirtyRect(Common::Rect(_orgX1, _orgY1, _orgX2, _orgY2));
 +	ASurface::drawBox();
 +}
 +
- void Screen::transCopyFrom(ASurface *src, const Common::Point &destPos) {
+ void Screen::transBlitFrom(ASurface *src, const Common::Point &destPos) {
  	addDirtyRect(Common::Rect(destPos.x, destPos.y, destPos.x + src->w, destPos.y + src->h));
- 	ASurface::transCopyFrom(src, destPos);
+ 	ASurface::transBlitFrom(src, destPos);
  }
  
- void Screen::transCopyFrom(ASurface *src, const Common::Rect &bounds) {
+ void Screen::transBlitFrom(ASurface *src, const Common::Rect &bounds) {
  	addDirtyRect(bounds);
- 	ASurface::transCopyFrom(src, bounds);
+ 	ASurface::transBlitFrom(src, bounds);
  }
  
- void Screen::copyFrom(Graphics::Surface &src) {
+ void Screen::blitFrom(Graphics::Surface &src) {
  	addDirtyRect(Common::Rect(0, 0, src.w, src.h));
- 	ASurface::copyFrom(src);
+ 	ASurface::blitFrom(src);
  }
  
  void Screen::copyBuffer(Graphics::Surface *src) {
diff --cc engines/access/screen.h
index 97ec59d,d45a533..52485e5
--- a/engines/access/screen.h
+++ b/engines/access/screen.h
@@@ -92,13 -92,11 +92,13 @@@ public
  
  	virtual void drawRect();
  
 +	virtual void drawBox();
 +
- 	virtual void transCopyFrom(ASurface *src, const Common::Point &destPos);
+ 	virtual void transBlitFrom(ASurface *src, const Common::Point &destPos);
  
- 	virtual void transCopyFrom(ASurface *src, const Common::Rect &bounds);
+ 	virtual void transBlitFrom(ASurface *src, const Common::Rect &bounds);
  
- 	virtual void copyFrom(Graphics::Surface &src);
+ 	virtual void blitFrom(Graphics::Surface &src);
  
  	virtual void copyBuffer(Graphics::Surface *src);
  
diff --cc engines/access/sound.cpp
index 9ade99c,69133d0..f2dc0fd
--- a/engines/access/sound.cpp
+++ b/engines/access/sound.cpp
@@@ -178,19 -199,58 +199,59 @@@ MusicManager::MusicManager(AccessEngin
  	_music = nullptr;
  	_tempMusic = nullptr;
  	_isLooping = false;
+ 	_driver = nullptr;
 +	_byte1F781 = false;
  
+ 	MidiDriver::DeviceHandle dev = MidiDriver::detectDevice(MDT_MIDI | MDT_ADLIB | MDT_PREFER_MT32);
+ 	MusicType musicType = MidiDriver::getMusicType(dev);
+ 
+ 	// Amazon Guardians of Eden uses MIDPAK inside MIDIDRV.AP
+ 	// AdLib patches are inside MIDIDRV.AP too, 2nd resource file
+ 	//
+ 	// Amazon Guardians of Eden (demo) seems to use another type of driver, possibly written by Access themselves
+ 	// Martian Memorandum uses this other type of driver as well, which means it makes sense to reverse engineer it.
+ 	//
+ 	switch (musicType) {
+ 	case MT_ADLIB: {
+ 		Resource   *midiDrvResource = _vm->_files->loadFile(92, 1);
+ 		Common::MemoryReadStream *adLibInstrumentStream = new Common::MemoryReadStream(midiDrvResource->data(), midiDrvResource->_size);
+ 
+ 		_driver = Audio::MidiDriver_Miles_AdLib_create("", "", adLibInstrumentStream);
+ 
+ 		delete midiDrvResource;
+ 		delete adLibInstrumentStream;
+ 		break;
+ 	}
+ 	case MT_MT32:
+ 		_driver = Audio::MidiDriver_Miles_MT32_create("");
+ 		_nativeMT32 = true;
+ 		break;
+ 	case MT_GM:
+ 		if (ConfMan.getBool("native_mt32")) {
+ 			_driver = Audio::MidiDriver_Miles_MT32_create("");
+ 			_nativeMT32 = true;
+ 		}
+ 		break;
+ 
+ 	default:
+ 		break;
+ 	}
+ 
+ #if 0
  	MidiPlayer::createDriver();
  	MidiDriver::detectDevice(MDT_MIDI | MDT_ADLIB | MDT_PREFER_GM);
+ #endif
  
- 	int retValue = _driver->open();
- 	if (retValue == 0) {
- 		if (_nativeMT32)
- 			_driver->sendMT32Reset();
- 		else
- 			_driver->sendGMReset();
+ 	if (_driver) {
+ 		int retValue = _driver->open();
+ 		if (retValue == 0) {
+ 			if (_nativeMT32)
+ 				_driver->sendMT32Reset();
+ 			else
+ 				_driver->sendGMReset();
  
- 		_driver->setTimerCallback(this, &timerCallback);
+ 			_driver->setTimerCallback(this, &timerCallback);
+ 		}
  	}
  }
  
diff --cc engines/access/sound.h
index 6bfdbcd,014c665..e11a6b9
--- a/engines/access/sound.h
+++ b/engines/access/sound.h
@@@ -51,11 -53,9 +53,10 @@@ private
  
  	void clearSounds();
  
- 	void playSound(Resource *res, int priority);
+ 	void playSound(Resource *res, int priority, bool loop);
  public:
  	Common::Array<SoundEntry> _soundTable;
 +	bool _playingSound;
- 	bool _isVoice;
  public:
  	SoundManager(AccessEngine *vm, Audio::Mixer *mixer);
  	~SoundManager();


Commit: b4c15c674d66596e043d28abb0dcfa997d0d8dcb
    https://github.com/scummvm/scummvm/commit/b4c15c674d66596e043d28abb0dcfa997d0d8dcb
Author: Filippos Karapetis (bluegr at gmail.com)
Date: 2015-07-22T22:51:06+02:00

Commit Message:
ACCESS: Comment out unused variables

Changed paths:
    engines/access/scripts.cpp



diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index b201890..207f48d 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -1064,10 +1064,10 @@ void Scripts::cmdCheckTravel() {
 
 void Scripts::cmdBlock() {
 	error("TODO: cmdBlock");
-	int val1 = _data->readSint16LE();
-	int val2 = _data->readUint16LE();
-	int val3 = _data->readSint16LE();
-	int val4 = _data->readUint16LE();
+	/*int val1 = */_data->readSint16LE();
+	/*int val2 = */_data->readUint16LE();
+	/*int val3 = */_data->readSint16LE();
+	/*int val4 = */_data->readUint16LE();
 }
 
 void Scripts::cmdPlayerOff() {


Commit: ad0fc5787f53e4ccb5888ff14f36f0b04bcf9ff3
    https://github.com/scummvm/scummvm/commit/ad0fc5787f53e4ccb5888ff14f36f0b04bcf9ff3
Author: Filippos Karapetis (bluegr at gmail.com)
Date: 2015-07-22T22:51:10+02:00

Commit Message:
ACCESS: MM doesn't use Miles Audio

Changed paths:
    engines/access/sound.cpp



diff --git a/engines/access/sound.cpp b/engines/access/sound.cpp
index f2dc0fd..51ffb88 100644
--- a/engines/access/sound.cpp
+++ b/engines/access/sound.cpp
@@ -213,13 +213,17 @@ MusicManager::MusicManager(AccessEngine *vm) : _vm(vm) {
 	//
 	switch (musicType) {
 	case MT_ADLIB: {
-		Resource   *midiDrvResource = _vm->_files->loadFile(92, 1);
-		Common::MemoryReadStream *adLibInstrumentStream = new Common::MemoryReadStream(midiDrvResource->data(), midiDrvResource->_size);
+		if (_vm->getGameID() == GType_Amazon) {
+			Resource   *midiDrvResource = _vm->_files->loadFile(92, 1);
+			Common::MemoryReadStream *adLibInstrumentStream = new Common::MemoryReadStream(midiDrvResource->data(), midiDrvResource->_size);
 
-		_driver = Audio::MidiDriver_Miles_AdLib_create("", "", adLibInstrumentStream);
+			_driver = Audio::MidiDriver_Miles_AdLib_create("", "", adLibInstrumentStream);
 
-		delete midiDrvResource;
-		delete adLibInstrumentStream;
+			delete midiDrvResource;
+			delete adLibInstrumentStream;
+		} else {
+			MidiPlayer::createDriver();
+		}
 		break;
 	}
 	case MT_MT32:


Commit: 773305498c672ce528eddc8bfd5fb5702d6abb5e
    https://github.com/scummvm/scummvm/commit/773305498c672ce528eddc8bfd5fb5702d6abb5e
Author: Filippos Karapetis (bluegr at gmail.com)
Date: 2015-07-23T21:37:59+03:00

Commit Message:
Merge pull request #602 from bluegr/mm

ACCESS: Work on Martian Memorandum

Changed paths:
  A engines/access/martian/martian_player.cpp
  A engines/access/martian/martian_player.h
    engines/access/access.cpp
    engines/access/access.h
    engines/access/amazon/amazon_game.cpp
    engines/access/amazon/amazon_logic.cpp
    engines/access/amazon/amazon_player.cpp
    engines/access/amazon/amazon_resources.cpp
    engines/access/amazon/amazon_resources.h
    engines/access/amazon/amazon_scripts.cpp
    engines/access/amazon/amazon_scripts.h
    engines/access/asurface.cpp
    engines/access/asurface.h
    engines/access/bubble_box.cpp
    engines/access/bubble_box.h
    engines/access/char.cpp
    engines/access/char.h
    engines/access/detection_tables.h
    engines/access/inventory.cpp
    engines/access/inventory.h
    engines/access/martian/martian_game.cpp
    engines/access/martian/martian_game.h
    engines/access/martian/martian_resources.cpp
    engines/access/martian/martian_resources.h
    engines/access/martian/martian_room.cpp
    engines/access/martian/martian_room.h
    engines/access/martian/martian_scripts.cpp
    engines/access/martian/martian_scripts.h
    engines/access/module.mk
    engines/access/player.cpp
    engines/access/player.h
    engines/access/resources.cpp
    engines/access/resources.h
    engines/access/room.cpp
    engines/access/room.h
    engines/access/screen.cpp
    engines/access/screen.h
    engines/access/scripts.cpp
    engines/access/scripts.h
    engines/access/sound.cpp
    engines/access/sound.h
    engines/access/video.cpp
    engines/access/video.h









More information about the Scummvm-git-logs mailing list