[Scummvm-git-logs] scummvm master -> 8cf46e2f7f38d623f4eca8566a1f93fae99fcc89

bluegr bluegr at gmail.com
Thu Sep 16 06:26:06 UTC 2021


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

Summary:
8cf46e2f7f GROOVIE: Restructure game-specific logic code and video code


Commit: 8cf46e2f7f38d623f4eca8566a1f93fae99fcc89
    https://github.com/scummvm/scummvm/commit/8cf46e2f7f38d623f4eca8566a1f93fae99fcc89
Author: Filippos Karapetis (bluegr at gmail.com)
Date: 2021-09-16T09:25:47+03:00

Commit Message:
GROOVIE: Restructure game-specific logic code and video code

Changed paths:
  A engines/groovie/logic/cell.cpp
  A engines/groovie/logic/cell.h
  A engines/groovie/logic/clangame.cpp
  A engines/groovie/logic/clangame.h
  A engines/groovie/logic/t11hgame.cpp
  A engines/groovie/logic/t11hgame.h
  A engines/groovie/logic/tlcgame.cpp
  A engines/groovie/logic/tlcgame.h
  A engines/groovie/video/player.cpp
  A engines/groovie/video/player.h
  A engines/groovie/video/roq.cpp
  A engines/groovie/video/roq.h
  A engines/groovie/video/vdx.cpp
  A engines/groovie/video/vdx.h
  R engines/groovie/cell.cpp
  R engines/groovie/cell.h
  R engines/groovie/clangame.cpp
  R engines/groovie/clangame.h
  R engines/groovie/player.cpp
  R engines/groovie/player.h
  R engines/groovie/roq.cpp
  R engines/groovie/roq.h
  R engines/groovie/t11hgame.cpp
  R engines/groovie/t11hgame.h
  R engines/groovie/tlcgame.cpp
  R engines/groovie/tlcgame.h
  R engines/groovie/vdx.cpp
  R engines/groovie/vdx.h
    engines/groovie/groovie.cpp
    engines/groovie/module.mk
    engines/groovie/music.cpp
    engines/groovie/script.cpp
    engines/groovie/script.h


diff --git a/engines/groovie/groovie.cpp b/engines/groovie/groovie.cpp
index 64b19510d4..b6c6e58aa8 100644
--- a/engines/groovie/groovie.cpp
+++ b/engines/groovie/groovie.cpp
@@ -27,10 +27,10 @@
 #include "groovie/script.h"
 #include "groovie/music.h"
 #include "groovie/resource.h"
-#include "groovie/vdx.h"
+#include "groovie/video/vdx.h"
 
 #ifdef ENABLE_GROOVIE2
-#include "groovie/roq.h"
+#include "groovie/video/roq.h"
 #endif
 
 #include "common/config-manager.h"
diff --git a/engines/groovie/cell.cpp b/engines/groovie/logic/cell.cpp
similarity index 99%
rename from engines/groovie/cell.cpp
rename to engines/groovie/logic/cell.cpp
index 3177963a38..7bc279969c 100644
--- a/engines/groovie/cell.cpp
+++ b/engines/groovie/logic/cell.cpp
@@ -20,7 +20,7 @@
  *
  */
 
-#include "groovie/cell.h"
+#include "groovie/logic/cell.h"
 
 namespace Groovie {
 
diff --git a/engines/groovie/cell.h b/engines/groovie/logic/cell.h
similarity index 96%
rename from engines/groovie/cell.h
rename to engines/groovie/logic/cell.h
index d6f1ac97dc..1c025201f8 100644
--- a/engines/groovie/cell.h
+++ b/engines/groovie/logic/cell.h
@@ -20,8 +20,8 @@
  *
  */
 
-#ifndef GROOVIE_CELL_H
-#define GROOVIE_CELL_H
+#ifndef GROOVIE_LOGIC_CELL_H
+#define GROOVIE_LOGIC_CELL_H
 
 #include "common/textconsole.h"
 
@@ -94,4 +94,4 @@ private:
 
 } // End of Groovie namespace
 
-#endif // GROOVIE_CELL_H
+#endif // GROOVIE_LOGIC_CELL_H
diff --git a/engines/groovie/clangame.cpp b/engines/groovie/logic/clangame.cpp
similarity index 98%
rename from engines/groovie/clangame.cpp
rename to engines/groovie/logic/clangame.cpp
index 4900e17d6a..c5aaecf5c9 100644
--- a/engines/groovie/clangame.cpp
+++ b/engines/groovie/logic/clangame.cpp
@@ -20,7 +20,7 @@
  *
  */
 
-#include "groovie/clangame.h"
+#include "groovie/logic/clangame.h"
 
 namespace Groovie {
 
diff --git a/engines/groovie/clangame.h b/engines/groovie/logic/clangame.h
similarity index 91%
rename from engines/groovie/clangame.h
rename to engines/groovie/logic/clangame.h
index 1732dcefd8..91b9254cd4 100644
--- a/engines/groovie/clangame.h
+++ b/engines/groovie/logic/clangame.h
@@ -20,8 +20,8 @@
 *
 */
 
-#ifndef GROOVIE_CLANGAME_H
-#define GROOVIE_CLANGAME_H
+#ifndef GROOVIE_LOGIC_CLANGAME_H
+#define GROOVIE_LOGIC_CLANGAME_H
 
 namespace Groovie {
 
@@ -32,4 +32,4 @@ public:
 
 } // namespace Groovie
 
-#endif // GROOVIE_CLANGAME_H
+#endif // GROOVIE_LOGIC_CLANGAME_H
diff --git a/engines/groovie/logic/t11hgame.cpp b/engines/groovie/logic/t11hgame.cpp
new file mode 100644
index 0000000000..27add7b1f9
--- /dev/null
+++ b/engines/groovie/logic/t11hgame.cpp
@@ -0,0 +1,343 @@
+/* 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 "groovie/logic/t11hgame.h"
+#include "groovie/groovie.h"
+
+#include "common/archive.h"
+#include "common/config-manager.h"
+#include "common/debug-channels.h"
+#include "common/events.h"
+#include "common/file.h"
+#include "common/macresman.h"
+#include "common/translation.h"
+
+namespace Groovie {
+
+T11hGame::T11hGame(byte *scriptVariables) :
+	_random("GroovieT11hGame"), _scriptVariables(scriptVariables) {
+}
+
+T11hGame::~T11hGame() {
+}
+
+void T11hGame::handleOp(uint8 op) {
+	switch (op) {
+	case 1:
+		debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): T11H Connect four in the dining room. (tb.grv) TODO", op);
+		break;
+
+	case 2:
+		debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): T11H Beehive Puzzle in the top room (hs.grv) TODO", op);
+		opBeehive();
+		break;
+
+	case 3:
+		debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): T11H Make last move on modern art picture in the gallery (bs.grv) TODO", op);
+		opGallery();
+		break;
+
+	case 4:
+		debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): T11H Triangle in the Chapel (tx.grv)", op);
+		break;
+
+	case 5:
+		debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): T11H Mouse Trap in the lab (al.grv)", op);
+		opMouseTrap();
+		break;
+
+	case 6:
+		debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): T11H Pente (pt.grv)", op);
+		opPente();
+		break;
+
+	case 8:	// used in UHP
+		debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): UHP Othello", op);
+		// TODO: Same as the Clandestiny Othello/Reversi puzzle (opOthello)
+		break;
+
+	default:
+		debugC(1, kDebugScript, "Groovie::Script: Op42 (0x%02X): T11H Invalid -> NOP", op);
+	}
+}
+
+/*
+ * Mouse Trap puzzle in the Lab.
+ *
+ * Stauf's Goal is space 1, counting up as you go north east
+ * towards the north corner which is space 5 and the moveable
+ * space to the left of that is space 4.
+ * South east from Stauf's goal is the next line starting with
+ * space 6, counting up as you go north east where the moveable
+ * space to the right of the north corner is space 10
+ * 
+ * Next line is 11 (unmovable) to 15 (unmoveable), this line
+ * contains the center space which is space 13
+ * Next line is 16 (moveable) to 20 (moveable)
+ * Next line is 21 (unmovable) to 25 (unmovable), with 25 being
+ * the player's goal door
+ *
+ * Space -2 is the next piece, outside of the box
+ */
+void T11hGame::opMouseTrap() {
+	// FIXME: properly implement mouse trap game
+	// variable 24 is the mouse?
+	//_scriptVariables[24] = 2;
+
+	switch (_scriptVariables[2]) {
+	case 0:
+		warning("mouse trap _scriptVariables[2] is 0 not implemented yet");
+		break;
+	case 1: // init board
+		// value of 0 is V, 1 is <, 2 is ^, 3 is >
+		// variable 23 is the outside piece
+		_scriptVariables[23] = _random.getRandomNumber(3);
+		// variable slot is the space number + 25, the left corner
+		// (Stauf's goal) is space 1, above that is space 2, the
+		// center is 13, and the right corner (goal) is space 25
+		for (int i = 27; i <= 49; i++) {
+			_scriptVariables[i] = _random.getRandomNumber(3);
+		}
+		break;
+	case 2: // before player choose move floor, set the banned move
+	{
+		int clicked = int(_scriptVariables[0]) * 5 + int(_scriptVariables[1]) + 1;
+		_scriptVariables[clicked + 50] = 0;
+		break;
+	}
+	case 3: // after player moving floor
+		// a bunch of hardcoded conditionals to copy variables and
+		// set the banned move
+		// this probably also sets a variable to allow the player to
+		// move the mouse, and checks for win/lose
+		break;
+	case 4: // 4 is not in the switch/case according to Ghidra
+		warning("mouse trap _scriptVariables[2] is 4? this shouldn't happen");
+		break;
+	case 5: // maybe player moving mouse
+		break;
+	case 6: // Stauf moving floor?
+		break;
+	case 7: // maybe Stauf moving mouse
+		break;
+	case 8: // Samantha making a move
+		break;
+
+	default:
+		warning("unknown mouse trap op %d", _scriptVariables[2]);
+		break;
+	}
+}
+
+/*
+ * Beehive puzzle
+ *
+ * An infection-style game in which the player must cover more
+ * territory than the computer. It's similar to the microscope puzzle
+ * in the 7th Guest. The playfield is a honeycomb made of 61
+ * hexagons.
+ */
+void T11hGame::opBeehive() {
+	// FIXME: properly implement Beehive game
+	// for now just auto-solve the puzzle so the player can continue
+	_scriptVariables[13] = 5;
+
+	// TODO: Finish logic
+	switch (_scriptVariables[14]) {
+	case 1:	// init board's hexagons
+		break;
+	}
+}
+
+void T11hGame::opPente() {
+	// FIXME: properly implement Pente game (the final puzzle)
+	// for now just auto-solve the puzzle so the player can continue
+	_scriptVariables[5] = 4;
+}
+
+/*
+ * Puzzle in the Gallery.
+ * The aim is to select the last part of the image.
+ * When selecting a part, all surrounding parts are also selected
+ * 
+ * +--------------------+--------------------------------+--------+
+ * |         1/1A       |       2/1B                     |        |
+ * |  +--------------+--+--------------------------+-----+        |
+ * |  |              |                             |              |
+ * +--+     4/1D     |            5/1E             |       3/1C   |
+ * |                 |                             |              |
+ * +-----+--------+--+--------+-----------------+--+--------+     |
+ * |     |        |           |                 |           |     |
+ * |     |        |           |                 |           |     |
+ * |     |        |   8/21    |                 |           |     |
+ * |     |        |           |     +-----------+           |     |
+ * |     |        |           |     |           |           |     |
+ * |     |        +-----------+     |   10/23   |   9/22    |     |
+ * |     |                          |           |           |     |
+ * |     |           7/20           +-----+-----+           +-----+
+ * |     |                          |     |     |           |     |
+ * |     +--------------------------+     |     |           |     |
+ * |              6/1F                    |     |           |     |
+ * +-----------+-----------+-----+--+     | 11  |           | 12  |
+ * |   13/26   |           |     |  |     | /   |           | /   |
+ * |     +-----+-----+     |     |  |     | 24  +-----------+ 25  |
+ * |     |           |     |     |  |     |     |           |     |
+ * +-----+   17/2A   |     |     |16|     |     |           |     |
+ * |     |           |     |     |/ |     |     |           |     |
+ * |     +-----+-----+     |     |29|     |     |           +-----+
+ * |           |           |     |  |     |     |           |     |
+ * |           |           |     |  |     +-----+   18/2B   |     |
+ * |   19/2C   |   14/27   |     |  |           |           |     |
+ * |           |           |     |  +-----------+           |     |
+ * |           |           |     |  |           |           |     |
+ * |           |           |     +--+   15/28   |           |     |
+ * |           |           |                    |           |     |
+ * |           +--------+--+--------------------+-----------+     |
+ * |           | 20/2D  |              21/2E                      |
+ * +-----------+--------+-----------------------------------------+
+ */
+
+// Links between the pieces in the Gallery challenge
+const byte T11hGame::kGalleryLinks[21][10] = {
+	{ 2,  4,  5,  0,  0,  0,  0,  0,  0,  0 },	//  1
+	{ 1,  5,  3,  0,  0,  0,  0,  0,  0,  0 },	//  2
+	{ 2,  5,  9, 12,  0,  0,  0,  0,  0,  0 },	//  3
+	{ 1,  5,  6,  7,  8,  0,  0,  0,  0,  0 },	//  4
+	{ 1,  2,  3,  4,  7,  8,  9,  0,  0,  0 },	//  5
+	{ 4,  7, 10, 11, 13, 14, 15, 16, 18,  0 },	//  6
+	{ 4,  5,  6,  8,  9, 10,  0,  0,  0,  0 },	//  7
+	{ 4,  5,  7,  0,  0,  0,  0,  0,  0,  0 },	//  8
+	{ 3,  5,  7, 10, 11, 12, 18,  0,  0,  0 },	//  9
+	{ 6,  7,  9, 11,  0,  0,  0,  0,  0,  0 },	// 10
+	{ 6,  9, 10, 18,  0,  0,  0,  0,  0,  0 },	// 11
+	{ 3,  9, 18, 21,  0,  0,  0,  0,  0,  0 },	// 12
+	{ 6, 14, 17, 19,  0,  0,  0,  0,  0,  0 },	// 13
+	{ 6, 13, 15, 17, 19, 20, 21,  0,  0,  0 },	// 14
+	{ 6, 14, 16, 18, 21,  0,  0,  0,  0,  0 },	// 15
+	{ 6, 15,  0,  0,  0,  0,  0,  0,  0,  0 },	// 16
+	{13, 14, 19,  0,  0,  0,  0,  0,  0,  0 },	// 17
+	{ 6,  9, 11, 12, 15, 21,  0,  0,  0,  0 },	// 18
+	{13, 14, 17, 20,  0,  0,  0,  0,  0,  0 },	// 19
+	{14, 19, 21,  0,  0,  0,  0,  0,  0,  0 },	// 20
+	{12, 14, 15, 18, 20,  0,  0,  0,  0,  0 }	// 21
+};
+
+void T11hGame::opGallery() {
+
+	byte field1[21];
+	byte field2[21];
+	byte var_18[21];
+	int var_1c, eax, edx, ecx;
+
+	// Copy RegMem to Field1
+	for (int i = 0; i < 21; i++) {
+		field1[i] = _scriptVariables[0x1A + i];
+	}
+
+	var_1c = 0;
+	for (int ebx = 0; ebx < 21; ebx++) {
+		var_18[ebx] = 0;
+		if (field1[ebx] != 0) {
+			memcpy(field2, field1, 21);
+
+			field2[ebx] = 0;
+			edx = kGalleryLinks[0][ebx];
+			eax = 1;
+			ecx = 0;
+			while (edx != 0) {
+				eax++;
+				field2[edx - 1] = ecx;
+				edx = kGalleryLinks[eax - 1][ebx];
+			}
+			var_18[ebx] = opGallerySub(1, field2);
+			if (var_18[ebx] == 1) {
+				var_1c++;
+			}
+		}
+	}
+
+	if (var_1c == 0) {
+		int esi = 0;
+		for (eax = 0; eax < 21; eax++) {
+			if (var_18[eax] > esi) {
+				esi = var_18[eax];
+			}
+		}
+
+		if (esi == 2) {
+			esi = 1;
+		} else {
+			if (esi <= 20) {
+				esi = 2;
+			} else {
+				esi -= 12;
+			}
+		}
+
+		for (eax = 0; eax < 21; eax++) {
+			if (var_18[eax] <= esi) {
+				var_18[eax] = 1;
+				var_1c++;
+			}
+		}
+	}
+
+	int selectedPart;
+
+	// TODO: copy the AI from the game
+	do {
+		selectedPart = _random.getRandomNumber(20) + 1;
+	} while (_scriptVariables[0x19 + selectedPart] != 1);
+
+	setScriptVar(0x2F, selectedPart / 10);
+	setScriptVar(0x30, selectedPart % 10);
+}
+
+byte T11hGame::opGallerySub(int one, byte* field) {
+	// TODO
+	warning("STUB: T11hGame::opGallerySub()");
+	return 0;
+}
+
+// This function is mainly for debugging purposes
+void inline T11hGame::setScriptVar(uint16 var, byte value) {
+	_scriptVariables[var] = value;
+	debugC(5, kDebugTlcGame, "script variable[0x%03X] = %d (0x%04X)", var, value, value);
+}
+
+void inline T11hGame::setScriptVar16(uint16 var, uint16 value) {
+	_scriptVariables[var] = value & 0xFF;
+	_scriptVariables[var + 1] = (value >> 8) & 0xFF;
+	debugC(5, kDebugTlcGame, "script variable[0x%03X, 0x%03X] = %d (0x%02X, 0x%02X)",
+		var, var + 1, value, _scriptVariables[var], _scriptVariables[var + 1]);
+}
+
+uint16 inline T11hGame::getScriptVar16(uint16 var) {
+	uint16 value;
+
+	value = _scriptVariables[var];
+	value += _scriptVariables[var + 1] << 8;
+
+	return value;
+}
+
+} // End of Namespace Groovie
diff --git a/engines/groovie/t11hgame.h b/engines/groovie/logic/t11hgame.h
similarity index 79%
rename from engines/groovie/t11hgame.h
rename to engines/groovie/logic/t11hgame.h
index 9b2053a8c2..a03d506f2e 100644
--- a/engines/groovie/t11hgame.h
+++ b/engines/groovie/logic/t11hgame.h
@@ -20,8 +20,8 @@
 *
 */
 
-#ifndef GROOVIE_T11HGAME_H
-#define GROOVIE_T11HGAME_H
+#ifndef GROOVIE_LOGIC_T11HGAME_H
+#define GROOVIE_LOGIC_T11HGAME_H
 
 #include "common/textconsole.h"
 #include "common/random.h"
@@ -33,23 +33,19 @@ class GroovieEngine;
 class T11hGame {
 public:
 #ifdef ENABLE_GROOVIE2
-	T11hGame();
+	T11hGame(byte *scriptVariables);
 	~T11hGame();
-	/**
-	* Sets a pointer to the script variables. This makes it easier if we want
-	* to debug write accesses to the script variables
-	* @param scriptVariables	The current variables from the script.
-	*/
-	void setVariables(byte *scriptVariables);
+
+	void handleOp(uint8 op);
+
+private:
+	Common::RandomSource _random;
 
 	void opMouseTrap();
 	void opBeehive();
 	void opPente();
 	void opGallery();
 
-private:
-	Common::RandomSource _random;
-
 	byte opGallerySub(int one, byte *field);
 	void inline setScriptVar(uint16 var, byte value);
 	void inline setScriptVar16(uint16 var, uint16 value);
@@ -61,4 +57,4 @@ private:
 
 } // End of Groovie namespace
 
-#endif // GROOVIE_T11HGAME_H
+#endif // GROOVIE_LOGIC_T11HGAME_H
diff --git a/engines/groovie/tlcgame.cpp b/engines/groovie/logic/tlcgame.cpp
similarity index 97%
rename from engines/groovie/tlcgame.cpp
rename to engines/groovie/logic/tlcgame.cpp
index a8ca60d7bc..60f02e91ff 100644
--- a/engines/groovie/tlcgame.cpp
+++ b/engines/groovie/logic/tlcgame.cpp
@@ -20,7 +20,7 @@
  *
  */
 
-#include "groovie/tlcgame.h"
+#include "groovie/logic/tlcgame.h"
 #include "groovie/groovie.h"
 
 #include "common/archive.h"
@@ -43,13 +43,12 @@ const char *kTlcMusicFiles[] = {"ep01epm", "ep01tatm", "amb_hs", "amb_mr", "amb_
 const uint8 kTlcEpQuestToPlay[] = { 0x0E, 0x0F, 0x0B, 0x10, 0x11, 0x12, 0x0C, 0x0C, 0x09, 0x06, 0x0F, 0x0C, 0x0B, 0x0D, 0x0D };
 
 
-TlcGame::TlcGame() :
+TlcGame::TlcGame(byte *scriptVariables) :
 	_numRegionHeaders(0), _regionHeader(NULL), _curQuestNumAnswers(-1), _epQuestionsData(NULL),
-	_random("GroovieTlcGame"), _scriptVariables(NULL),
+	_random("GroovieTlcGame"), _scriptVariables(scriptVariables),
 	_tatHeaders(NULL), _tatQuestions(NULL) {
 }
 
-
 TlcGame::~TlcGame() {
 	delete[] _regionHeader;
 	delete[] _epQuestionsData;
@@ -57,9 +56,31 @@ TlcGame::~TlcGame() {
 	delete[] _tatQuestions;
 }
 
+void TlcGame::handleOp(uint8 op) {
+	switch (op) {
+	case 0:
+		debugC(1, kDebugScript, "Groovie::Script: Op42 (0x%02X): TLC Regions", op);
+		opRegions();
+		break;
+
+	case 1:
+		debugC(1, kDebugScript, "Groovie::Script: Op42 (0x%02X): TLC Exit Polls", op);
+		opExitPoll();
+		break;
+
+	case 2:
+		debugC(1, kDebugScript, "Groovie::Script: Op42 (0x%02X): TLC TATFlags", op);
+		opFlags();
+		break;
 
-void TlcGame::setVariables(byte *scriptVariables) {
-	_scriptVariables = scriptVariables;
+	case 3:
+		debugC(1, kDebugScript, "Groovie::Script: Op42 (0x%02X): TLC TATs (TODO)", op);
+		opTat();
+		break;
+
+	default:
+		debugC(1, kDebugScript, "Groovie::Script: Op42 (0x%02X): TLC Invalid -> NOP", op);
+	}
 }
 
 // This function is mainly for debugging purpose
diff --git a/engines/groovie/tlcgame.h b/engines/groovie/logic/tlcgame.h
similarity index 90%
rename from engines/groovie/tlcgame.h
rename to engines/groovie/logic/tlcgame.h
index da3506644e..8363478c1f 100644
--- a/engines/groovie/tlcgame.h
+++ b/engines/groovie/logic/tlcgame.h
@@ -20,8 +20,8 @@
 *
 */
 
-#ifndef GROOVIE_TLCGAME_H
-#define GROOVIE_TLCGAME_H
+#ifndef GROOVIE_LOGIC_TLCGAME_H
+#define GROOVIE_LOGIC_TLCGAME_H
 
 #include "common/textconsole.h"
 #include "common/random.h"
@@ -72,17 +72,12 @@ class TlcGame
 {
 public:
 #ifdef ENABLE_GROOVIE2
-	TlcGame();
+	TlcGame(byte *scriptVariables);
 	~TlcGame();
 
 	static const char *getTlcMusicFilename(int musicId);
 
-	/**
-	 * Sets a pointer to the script variables. This makes it easier if we want
-	 * to debug write accesses to the script variables
-	 * @param scriptVariables	The current variables from the script.
-	 */
-	void setVariables(byte *scriptVariables);
+	void handleOp(uint8 op);
 
 	/**
 	 * Handle region commands. A region describes the coordinates of
@@ -196,4 +191,4 @@ private:
 
 } // End of Groovie namespace
 
-#endif // GROOVIE_TLCGAME_H
+#endif // GROOVIE_LOGIC_TLCGAME_H
diff --git a/engines/groovie/module.mk b/engines/groovie/module.mk
index a3cda1ea29..4010550f71 100644
--- a/engines/groovie/module.mk
+++ b/engines/groovie/module.mk
@@ -1,7 +1,9 @@
 MODULE := engines/groovie
 
 MODULE_OBJS := \
-	cell.o \
+	logic/cell.o \
+	video/player.o \
+	video/vdx.o \
 	cursor.o \
 	debug.o \
 	font.o \
@@ -10,18 +12,16 @@ MODULE_OBJS := \
 	lzss.o \
 	metaengine.o \
 	music.o \
-	player.o \
 	resource.o \
 	saveload.o \
-	script.o \
-	vdx.o
+	script.o
 
 ifdef ENABLE_GROOVIE2
 MODULE_OBJS += \
-	clangame.o \
-	roq.o \
-	t11hgame.o \
-	tlcgame.o
+	logic/clangame.o \
+	logic/t11hgame.o \
+	logic/tlcgame.o \
+	video/roq.o
 endif
 
 # This module can be built as a plugin
diff --git a/engines/groovie/music.cpp b/engines/groovie/music.cpp
index 5e1502a1f9..17f7124eb0 100644
--- a/engines/groovie/music.cpp
+++ b/engines/groovie/music.cpp
@@ -26,8 +26,8 @@
 #include "groovie/music.h"
 #include "groovie/groovie.h"
 #include "groovie/resource.h"
-#include "groovie/tlcgame.h"
-#include "groovie/clangame.h"
+#include "groovie/logic/tlcgame.h"
+#include "groovie/logic/clangame.h"
 
 #include "backends/audiocd/audiocd.h"
 #include "common/config-manager.h"
diff --git a/engines/groovie/script.cpp b/engines/groovie/script.cpp
index 8c8a9a656b..451e1db3fa 100644
--- a/engines/groovie/script.cpp
+++ b/engines/groovie/script.cpp
@@ -25,15 +25,15 @@
 #include "audio/mididrv.h"
 
 #include "groovie/script.h"
-#include "groovie/cell.h"
 #include "groovie/cursor.h"
 #include "groovie/graphics.h"
 #include "groovie/music.h"
-#include "groovie/player.h"
+#include "groovie/video/player.h"
 #include "groovie/resource.h"
 #include "groovie/saveload.h"
-#include "groovie/tlcgame.h"
-#include "groovie/t11hgame.h"
+#include "groovie/logic/cell.h"
+#include "groovie/logic/tlcgame.h"
+#include "groovie/logic/t11hgame.h"
 
 #include "gui/saveload.h"
 
@@ -73,7 +73,7 @@ const byte t7gMidiInitScript[] = {
 
 Script::Script(GroovieEngine *vm, EngineVersion version) :
 	_code(NULL), _savedCode(NULL), _stacktop(0), _debugger(NULL), _vm(vm),
-	_videoFile(NULL), _videoRef(UINT_MAX), _staufsMove(NULL), _lastCursor(0xff),
+	_videoFile(NULL), _videoRef(UINT_MAX), _cellGame(NULL), _lastCursor(0xff),
 	_version(version), _random("GroovieScripts"), _tlcGame(0), _t11hGame(0) {
 
 	// Initialize the opcode set depending on the engine version
@@ -116,7 +116,7 @@ Script::~Script() {
 	delete[] _code;
 	delete[] _savedCode;
 	delete _videoFile;
-	delete _staufsMove;
+	delete _cellGame;
 	delete _tlcGame;
 	delete _t11hGame;
 }
@@ -1781,31 +1781,6 @@ void Script::o_sub() {
 	setVariable(varnum1, _variables[varnum1] - _variables[varnum2]);
 }
 
-void Script::o_cellmove() {
-	uint16 depth = readScript8bits();
-	byte *scriptBoard = &_variables[0x19];
-	byte startX, startY, endX, endY;
-
-	debugC(1, kDebugScript, "Groovie::Script: CELL MOVE var[0x%02X]", depth);
-
-	if (!_staufsMove)
-		_staufsMove = new CellGame;
-
-	_staufsMove->playStauf(2, depth, scriptBoard);
-
-	startX = _staufsMove->getStartX();
-	startY = _staufsMove->getStartY();
-	endX = _staufsMove->getEndX();
-	endY = _staufsMove->getEndY();
-
-	// Set the movement origin
-	setVariable(0, startY); // y
-	setVariable(1, startX); // x
-	// Set the movement destination
-	setVariable(2, endY);
-	setVariable(3, endX);
-}
-
 void Script::o_returnscript() {
 	uint8 val = readScript8bits();
 
@@ -2069,106 +2044,46 @@ void Script::o2_setvideoskip() {
 
 // This function depends on the actual game played. So it is different for 
 // T7G, 11H, TLC, ...
-void Script::o2_gamespecial() {
-	uint8 arg = readScript8bits();
+void Script::o_gamelogic() {
+	uint8 param = readScript8bits();
 
 	switch (_version) {
-#ifdef ENABLE_GROOVIE2
-	case kGroovieTLC:
-		if (_tlcGame == NULL) {
-			_tlcGame = new TlcGame();
-			_tlcGame->setVariables(_variables);
-		}
-		switch (arg) {
-		case 0:
-			debugC(1, kDebugScript, "Groovie::Script: Op42 (0x%02X): TLC Regions", arg);
-			_tlcGame->opRegions();
-			break;
+	case kGroovieT7G:
+		if (!_cellGame)
+			_cellGame = new CellGame;
 
-		case 1:
-			debugC(1, kDebugScript, "Groovie::Script: Op42 (0x%02X): TLC Exit Polls", arg);
-			_tlcGame->opExitPoll();
-			break;
-
-		case 2:
-			debugC(1, kDebugScript, "Groovie::Script: Op42 (0x%02X): TLC TATFlags", arg);
-			_tlcGame->opFlags();
-			break;
+		debugC(1, kDebugScript, "Groovie::Script: CELL MOVE var[0x%02X]", param);
 
-		case 3:
-			debugC(1, kDebugScript, "Groovie::Script: Op42 (0x%02X): TLC TATs (TODO)", arg);
-			_tlcGame->opTat();
-			break;
+		_cellGame->playStauf(2, param, &_variables[0x19]);
 
-		default:
-			debugC(1, kDebugScript, "Groovie::Script: Op42 (0x%02X): TLC Invalid -> NOP", arg);
-		}
+		// Set the movement origin
+		setVariable(0, _cellGame->getStartY()); // y
+		setVariable(1, _cellGame->getStartX()); // x
+		// Set the movement destination
+		setVariable(2, _cellGame->getEndY());
+		setVariable(3, _cellGame->getEndX());
 		break;
 
-	case kGroovieT11H:
-		if (_t11hGame == NULL) {
-			_t11hGame = new T11hGame();
-			_t11hGame->setVariables(_variables);
-		}
-		switch (arg) {
-		case 1:
-			debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): T11H Connect four in the dining room. (tb.grv) TODO", arg);
-			break;
-
-		case 2:
-			debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): T11H Beehive Puzzle in the top room (hs.grv) TODO", arg);
-			_t11hGame->opBeehive();
-			break;
-
-		case 3:
-			debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): T11H Make last move on modern art picture in the gallery (bs.grv) TODO", arg);
-			_t11hGame->opGallery();
-			break;
-
-		case 4:
-			debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): T11H Triangle in the Chapel (tx.grv)", arg);
-			break;
-
-		case 5:
-			debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): T11H Mouse Trap in the lab (al.grv)", arg);
-			_t11hGame->opMouseTrap();
-			break;
-
-		case 6:
-			debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): T11H Pente (pt.grv)", arg);
-			_t11hGame->opPente();
-			break;
-
+#ifdef ENABLE_GROOVIE2
+	case kGroovieTLC:
+		if (!_tlcGame)
+			_tlcGame = new TlcGame(_variables);
 
-		default:
-			debugC(1, kDebugScript, "Groovie::Script: Op42 (0x%02X): T11H Invalid -> NOP", arg);
-		}
+		_tlcGame->handleOp(param);
 		break;
+
+	case kGroovieT11H:
 	case kGroovieUHP:
-		if (_t11hGame == NULL) {
-			_t11hGame = new T11hGame();
-			_t11hGame->setVariables(_variables);
-		}
-		switch (arg) {
-		case 2:
-			debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): UHP Beehive Puzzle", arg);
-			_t11hGame->opBeehive();
-			break;
-		case 5:
-			debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): UHP Mouse Trap", arg);
-			_t11hGame->opMouseTrap();
-			break;
-		case 8:
-			debugC(1, kDebugScript, "Groovie::Script Op42 (0x%02X): UHP Othello", arg);
-			// TODO: Same as the Clandestiny Othello/Reversi puzzle (opOthello)
-			break;
-		default:
-			debugC(1, kDebugScript, "Groovie::Script: Op42 (0x%02X): UHP Invalid -> NOP", arg);
-		}
+		if (!_t11hGame)
+			_t11hGame = new T11hGame(_variables);
+
+		// TODO: Separate UHP game logic in 11th Hour / Clandestiny
+		_t11hGame->handleOp(param);
 		break;
+
 #endif
 	default:
-		debugC(1, kDebugScript, "Groovie::Script: GameSpecial (0x%02X)", arg);
+		debugC(1, kDebugScript, "Groovie::Script: GameSpecial (0x%02X)", param);
 		warning("Groovie::Script: OpCode 0x42 for (GameSpecial) current game not implemented yet.");
 	}
 }
@@ -2297,7 +2212,7 @@ Script::OpcodeFunc Script::_opcodesT7G[NUM_OPCODES] = {
 	&Script::o_loadscript,
 	&Script::o_setvideoorigin, // 0x40
 	&Script::o_sub,
-	&Script::o_cellmove,
+	&Script::o_gamelogic,
 	&Script::o_returnscript,
 	&Script::o_sethotspotright, // 0x44
 	&Script::o_sethotspotleft,
@@ -2394,7 +2309,7 @@ Script::OpcodeFunc Script::_opcodesV2[NUM_OPCODES] = {
 	&Script::o_loadscript,
 	&Script::o_setvideoorigin, // 0x40
 	&Script::o_sub,
-	&Script::o2_gamespecial,
+	&Script::o_gamelogic,
 	&Script::o_returnscript,
 	&Script::o_sethotspotright, // 0x44
 	&Script::o_sethotspotleft,
diff --git a/engines/groovie/script.h b/engines/groovie/script.h
index fe4d9c8420..7023f52b63 100644
--- a/engines/groovie/script.h
+++ b/engines/groovie/script.h
@@ -132,7 +132,7 @@ private:
 	uint16 _oldInstruction;
 
 	// Special classes depending on played game
-	CellGame *_staufsMove;
+	CellGame *_cellGame;
 	TlcGame *_tlcGame;
 	T11hGame *_t11hGame;
 
@@ -230,7 +230,6 @@ private:
 	void o_loadscript();
 	void o_setvideoorigin();
 	void o_sub();
-	void o_cellmove();
 	void o_returnscript();
 	void o_sethotspotright();
 	void o_sethotspotleft();
@@ -252,7 +251,7 @@ private:
 	void o2_setvideoskip();
 	void o2_savescreen();
 	void o2_restorescreen();
-	void o2_gamespecial();
+	void o_gamelogic();
 	void o2_copyfgtobg();
 	void o2_setscriptend();
 	void o2_playsound();
diff --git a/engines/groovie/t11hgame.cpp b/engines/groovie/t11hgame.cpp
deleted file mode 100644
index cebc38ad79..0000000000
--- a/engines/groovie/t11hgame.cpp
+++ /dev/null
@@ -1,285 +0,0 @@
-/* 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 "groovie/t11hgame.h"
-#include "groovie/groovie.h"
-
-#include "common/archive.h"
-#include "common/config-manager.h"
-#include "common/debug-channels.h"
-#include "common/events.h"
-#include "common/file.h"
-#include "common/macresman.h"
-#include "common/translation.h"
-
-namespace Groovie {
-
-T11hGame::T11hGame() :
-	_random("GroovieT11hGame"), _scriptVariables(NULL) {
-}
-
-
-T11hGame::~T11hGame() {
-}
-
-
-void T11hGame::setVariables(byte *scriptVariables) {
-	_scriptVariables = scriptVariables;
-}
-
-
-/*
-* Mouse Trap puzzle in the Lab.
-*
-* Stauf's Goal is space 1, counting up as you go north east towards the north corner which is space 5 and the moveable space to the left of that is space 4
-* South east from Stauf's goal is the next line starting with space 6, counting up as you go north east where the moveable space to the right of the north corner is space 10
-* Next line is 11 (unmovable) to 15 (unmoveable), this line contains the center space which is space 13
-* Next line is 16 (moveable) to 20 (moveable)
-* Next line is 21 (unmovable) to 25 (unmovable), with 25 being the player's goal door
-*
-* Space -2 is the next piece, outside of the box
-*/
-void T11hGame::opMouseTrap() {
-	// FIXME: properly implement mouse trap game
-	// variable 24 is the mouse?
-	//_scriptVariables[24] = 2;
-
-	switch (_scriptVariables[2]) {
-	case 0:
-		warning("mouse trap _scriptVariables[2] is 0 not implemented yet");
-		break;
-	case 1: // init board
-		// value of 0 is V, 1 is <, 2 is ^, 3 is >
-		// variable 23 is the outside piece
-		_scriptVariables[23] = _random.getRandomNumber(3);
-		// variable slot is the space number + 25, the left corner (Stauf's goal) is space 1, above that is space 2, the center is 13, and the right corner (goal) is space 25
-		for (int i = 27; i <= 49; i++) {
-			_scriptVariables[i] = _random.getRandomNumber(3);
-		}
-		break;
-	case 2: // before player choose move floor, set the banned move
-	{
-		int clicked = int(_scriptVariables[0]) * 5 + int(_scriptVariables[1]) + 1;
-		_scriptVariables[clicked + 50] = 0;
-		break;
-	}
-	case 3: // after player moving floor
-		// a bunch of hardcoded conditionals to copy variables and set the banned move
-		// this probably also sets a variable to allow the player to move the mouse, and checks for win/lose
-		break;
-	case 4: // 4 is not in the switch/case according to Ghidra
-		warning("mouse trap _scriptVariables[2] is 4? this shouldn't happen");
-		break;
-	case 5: // maybe player moving mouse
-		break;
-	case 6: // Stauf moving floor?
-		break;
-	case 7: // maybe Stauf moving mouse
-		break;
-	case 8: // samantha making a move
-		break;
-
-	default:
-		warning((Common::String("mouse trap _scriptVariables[2] is ") + int(_scriptVariables[2]) + "? this shouldn't happen").c_str());
-		break;
-	}
-}
-
-
-void T11hGame::opBeehive() {
-	// FIXME: properly implement Beehive game
-	// for now just auto-solve the puzzle so the player can continue
-	_scriptVariables[13] = 5;
-}
-
-
-void T11hGame::opPente() {
-	// FIXME: properly implement Pente game (the final puzzle)
-	// for now just auto-solve the puzzle so the player can continue
-	_scriptVariables[5] = 4;
-}
-
-
-/*
-* Puzzle in the Gallery.
-* The aim is to select the last part of the image. When selecting a part all surrounding parts are also selected
-* +--------------------+--------------------------------+--------+
-* |         1/1A       |       2/1B                     |        |
-* |  +--------------+--+--------------------------+-----+        |
-* |  |              |                             |              |
-* +--+     4/1D     |            5/1E             |       3/1C   |
-* |                 |                             |              |
-* +-----+--------+--+--------+-----------------+--+--------+     |
-* |     |        |           |                 |           |     |
-* |     |        |           |                 |           |     |
-* |     |        |   8/21    |                 |           |     |
-* |     |        |           |     +-----------+           |     |
-* |     |        |           |     |           |           |     |
-* |     |        +-----------+     |   10/23   |   9/22    |     |
-* |     |                          |           |           |     |
-* |     |           7/20           +-----+-----+           +-----+
-* |     |                          |     |     |           |     |
-* |     +--------------------------+     |     |           |     |
-* |              6/1F                    |     |           |     |
-* +-----------+-----------+-----+--+     | 11  |           | 12  |
-* |   13/26   |           |     |  |     | /   |           | /   |
-* |     +-----+-----+     |     |  |     | 24  +-----------+ 25  |
-* |     |           |     |     |  |     |     |           |     |
-* +-----+   17/2A   |     |     |16|     |     |           |     |
-* |     |           |     |     |/ |     |     |           |     |
-* |     +-----+-----+     |     |29|     |     |           +-----+
-* |           |           |     |  |     |     |           |     |
-* |           |           |     |  |     +-----+   18/2B   |     |
-* |   19/2C   |   14/27   |     |  |           |           |     |
-* |           |           |     |  +-----------+           |     |
-* |           |           |     |  |           |           |     |
-* |           |           |     +--+   15/28   |           |     |
-* |           |           |                    |           |     |
-* |           +--------+--+--------------------+-----------+     |
-* |           | 20/2D  |              21/2E                      |
-* +-----------+--------+-----------------------------------------+
-*/
-
-/* Links between the pieces in the Gallery challenge */
-const byte T11hGame::kGalleryLinks[21][10] = {
-	{ 2,  4,  5,  0,  0,  0,  0,  0,  0,  0 },	//  1
-	{ 1,  5,  3,  0,  0,  0,  0,  0,  0,  0 },	//  2
-	{ 2,  5,  9, 12,  0,  0,  0,  0,  0,  0 },	//  3
-	{ 1,  5,  6,  7,  8,  0,  0,  0,  0,  0 },	//  4
-	{ 1,  2,  3,  4,  7,  8,  9,  0,  0,  0 },	//  5
-	{ 4,  7, 10, 11, 13, 14, 15, 16, 18,  0 },	//  6
-	{ 4,  5,  6,  8,  9, 10,  0,  0,  0,  0 },	//  7
-	{ 4,  5,  7,  0,  0,  0,  0,  0,  0,  0 },	//  8
-	{ 3,  5,  7, 10, 11, 12, 18,  0,  0,  0 },	//  9
-	{ 6,  7,  9, 11,  0,  0,  0,  0,  0,  0 },	// 10
-	{ 6,  9, 10, 18,  0,  0,  0,  0,  0,  0 },	// 11
-	{ 3,  9, 18, 21,  0,  0,  0,  0,  0,  0 },	// 12
-	{ 6, 14, 17, 19,  0,  0,  0,  0,  0,  0 },	// 13
-	{ 6, 13, 15, 17, 19, 20, 21,  0,  0,  0 },	// 14
-	{ 6, 14, 16, 18, 21,  0,  0,  0,  0,  0 },	// 15
-	{ 6, 15,  0,  0,  0,  0,  0,  0,  0,  0 },	// 16
-	{13, 14, 19,  0,  0,  0,  0,  0,  0,  0 },	// 17
-	{ 6,  9, 11, 12, 15, 21,  0,  0,  0,  0 },	// 18
-	{13, 14, 17, 20,  0,  0,  0,  0,  0,  0 },	// 19
-	{14, 19, 21,  0,  0,  0,  0,  0,  0,  0 },	// 20
-	{12, 14, 15, 18, 20,  0,  0,  0,  0,  0 }	// 21
-};
-
-void T11hGame::opGallery() {
-
-	byte field1[21];
-	byte field2[21];
-	byte var_18[21];
-	int var_1c, eax, edx, ecx;
-
-	// Copy RegMem to Field1
-	for (int i = 0; i < 21; i++) {
-		field1[i] = _scriptVariables[0x1A + i];
-	}
-
-	var_1c = 0;
-	for (int ebx = 0; ebx < 21; ebx++) {
-		var_18[ebx] = 0;
-		if (field1[ebx] != 0) {
-			memcpy(field2, field1, 21);
-
-			field2[ebx] = 0;
-			edx = kGalleryLinks[0][ebx];
-			eax = 1;
-			ecx = 0;
-			while (edx != 0) {
-				eax++;
-				field2[edx - 1] = ecx;
-				edx = kGalleryLinks[eax - 1][ebx];
-			}
-			var_18[ebx] = opGallerySub(1, field2);
-			if (var_18[ebx] == 1) {
-				var_1c++;
-			}
-		}
-	}
-
-	if (var_1c == 0) {
-		int esi = 0;
-		for (eax = 0; eax < 21; eax++) {
-			if (var_18[eax] > esi) {
-				esi = var_18[eax];
-			}
-		}
-
-		if (esi == 2) {
-			esi = 1;
-		} else {
-			if (esi <= 20) {
-				esi = 2;
-			} else {
-				esi -= 12;
-			}
-		}
-
-		for (eax = 0; eax < 21; eax++) {
-			if (var_18[eax] <= esi) {
-				var_18[eax] = 1;
-				var_1c++;
-			}
-		}
-	}
-
-	int selectedPart;
-
-	// TODO: copy the AI from the game
-	do {
-		selectedPart = _random.getRandomNumber(20) + 1;
-	} while (_scriptVariables[0x19 + selectedPart] != 1);
-
-	setScriptVar(0x2F, selectedPart / 10);
-	setScriptVar(0x30, selectedPart % 10);
-}
-
-byte T11hGame::opGallerySub(int one, byte* field) {
-	// TODO
-	warning("STUB: T11hGame::opGallerySub()");
-	return 0;
-}
-
-// This function is mainly for debugging purpose
-void inline T11hGame::setScriptVar(uint16 var, byte value) {
-	_scriptVariables[var] = value;
-	debugC(5, kDebugTlcGame, "script variable[0x%03X] = %d (0x%04X)", var, value, value);
-}
-
-void inline T11hGame::setScriptVar16(uint16 var, uint16 value) {
-	_scriptVariables[var] = value & 0xFF;
-	_scriptVariables[var + 1] = (value >> 8) & 0xFF;
-	debugC(5, kDebugTlcGame, "script variable[0x%03X, 0x%03X] = %d (0x%02X, 0x%02X)", var, var + 1, value, _scriptVariables[var], _scriptVariables[var + 1]);
-}
-
-uint16 inline T11hGame::getScriptVar16(uint16 var) {
-	uint16 value;
-
-	value = _scriptVariables[var];
-	value += _scriptVariables[var + 1] << 8;
-
-	return value;
-}
-
-} // End of Namespace Groovie
diff --git a/engines/groovie/player.cpp b/engines/groovie/video/player.cpp
similarity index 99%
rename from engines/groovie/player.cpp
rename to engines/groovie/video/player.cpp
index 1f6a0cde11..b715089d94 100644
--- a/engines/groovie/player.cpp
+++ b/engines/groovie/video/player.cpp
@@ -23,7 +23,7 @@
 #include "common/debug.h"
 #include "audio/audiostream.h"
 
-#include "groovie/player.h"
+#include "groovie/video/player.h"
 #include "groovie/groovie.h"
 #include "audio/mixer.h"
 #include "common/debug-channels.h"
diff --git a/engines/groovie/player.h b/engines/groovie/video/player.h
similarity index 95%
rename from engines/groovie/player.h
rename to engines/groovie/video/player.h
index 6181d94e5f..4c4bd75b6c 100644
--- a/engines/groovie/player.h
+++ b/engines/groovie/video/player.h
@@ -20,8 +20,8 @@
  *
  */
 
-#ifndef GROOVIE_PLAYER_H
-#define GROOVIE_PLAYER_H
+#ifndef GROOVIE_VIDEO_PLAYER_H
+#define GROOVIE_VIDEO_PLAYER_H
 
 #include "common/system.h"
 
@@ -76,4 +76,4 @@ protected:
 
 } // End of Groovie namespace
 
-#endif // GROOVIE_PLAYER_H
+#endif // GROOVIE_VIDEO_PLAYER_H
diff --git a/engines/groovie/roq.cpp b/engines/groovie/video/roq.cpp
similarity index 99%
rename from engines/groovie/roq.cpp
rename to engines/groovie/video/roq.cpp
index e610149b26..d37f05d9f9 100644
--- a/engines/groovie/roq.cpp
+++ b/engines/groovie/video/roq.cpp
@@ -23,7 +23,7 @@
 // ROQ video player based on this specification by Dr. Tim Ferguson:
 // http://www.csse.monash.edu.au/~timf/videocodec/idroq.txt
 
-#include "groovie/roq.h"
+#include "groovie/video/roq.h"
 #include "groovie/graphics.h"
 #include "groovie/groovie.h"
 
diff --git a/engines/groovie/roq.h b/engines/groovie/video/roq.h
similarity index 96%
rename from engines/groovie/roq.h
rename to engines/groovie/video/roq.h
index 895ec996f0..b59f332aa3 100644
--- a/engines/groovie/roq.h
+++ b/engines/groovie/video/roq.h
@@ -20,10 +20,10 @@
  *
  */
 
-#ifndef GROOVIE_ROQ_H
-#define GROOVIE_ROQ_H
+#ifndef GROOVIE_VIDEO_ROQ_H
+#define GROOVIE_VIDEO_ROQ_H
 
-#include "groovie/player.h"
+#include "groovie/video/player.h"
 #include "audio/mixer.h"
 
 namespace Groovie {
@@ -116,4 +116,4 @@ public:
 
 } // End of Groovie namespace
 
-#endif // GROOVIE_ROQ_H
+#endif // GROOVIE_VIDEO_ROQ_H
diff --git a/engines/groovie/vdx.cpp b/engines/groovie/video/vdx.cpp
similarity index 99%
rename from engines/groovie/vdx.cpp
rename to engines/groovie/video/vdx.cpp
index 8cc37a657c..dc66ce06a0 100644
--- a/engines/groovie/vdx.cpp
+++ b/engines/groovie/video/vdx.cpp
@@ -20,7 +20,7 @@
  *
  */
 
-#include "groovie/vdx.h"
+#include "groovie/video/vdx.h"
 #include "groovie/graphics.h"
 #include "groovie/groovie.h"
 #include "groovie/lzss.h"
diff --git a/engines/groovie/vdx.h b/engines/groovie/video/vdx.h
similarity index 94%
rename from engines/groovie/vdx.h
rename to engines/groovie/video/vdx.h
index c6515cd741..347da1cf47 100644
--- a/engines/groovie/vdx.h
+++ b/engines/groovie/video/vdx.h
@@ -20,10 +20,10 @@
  *
  */
 
-#ifndef GROOVIE_VDX_H
-#define GROOVIE_VDX_H
+#ifndef GROOVIE_VIDEO_VDX_H
+#define GROOVIE_VIDEO_VDX_H
 
-#include "groovie/player.h"
+#include "groovie/video/player.h"
 #include "audio/mixer.h"
 
 namespace Common {
@@ -83,4 +83,4 @@ private:
 
 } // End of Groovie namespace
 
-#endif // GROOVIE_VDX_H
+#endif // GROOVIE_VIDEO_VDX_H




More information about the Scummvm-git-logs mailing list