From f4f4c867a41a8bd306c3ec288e5b948ad1bf7e25 Mon Sep 17 00:00:00 2001 From: Bendegúz Nagy Date: Sun, 19 Jun 2016 16:17:28 +0200 Subject: DM: Add InventoryMan, G0041_s_Graphic562_Box_ViewportFloppyZzzCross --- engines/dm/dm.cpp | 4 ++++ engines/dm/dm.h | 2 ++ engines/dm/inventory.cpp | 11 +++++++++++ engines/dm/inventory.h | 14 ++++++++++++++ engines/dm/module.mk | 3 ++- 5 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 engines/dm/inventory.cpp create mode 100644 engines/dm/inventory.h (limited to 'engines/dm') diff --git a/engines/dm/dm.cpp b/engines/dm/dm.cpp index af0868d061..24182e387b 100644 --- a/engines/dm/dm.cpp +++ b/engines/dm/dm.cpp @@ -19,6 +19,7 @@ #include "champion.h" #include "loadsave.h" #include "objectman.h" +#include "inventory.h" namespace DM { @@ -51,6 +52,7 @@ DMEngine::DMEngine(OSystem *syst) : Engine(syst), _console(nullptr) { _championMan = nullptr; _loadsaveMan = nullptr; _objectMan = nullptr; + _inventoryMan = nullptr; _stopWaitingForPlayerInput = false; _gameTimeTicking = false; @@ -70,6 +72,7 @@ DMEngine::~DMEngine() { delete _championMan; delete _loadsaveMan; delete _objectMan; + delete _inventoryMan; // clear debug channels DebugMan.clearAllDebugChannels(); @@ -146,6 +149,7 @@ Common::Error DMEngine::run() { _championMan = new ChampionMan(this); _loadsaveMan = new LoadsaveMan(this); _objectMan = new ObjectMan(this); + _inventoryMan = new InventoryMan(this); _displayMan->setUpScreens(320, 200); initializeGame(); // @ F0463_START_InitializeGame_CPSADEF diff --git a/engines/dm/dm.h b/engines/dm/dm.h index 14a8772dba..66be764bbc 100644 --- a/engines/dm/dm.h +++ b/engines/dm/dm.h @@ -16,6 +16,7 @@ class MenuMan; class ChampionMan; class LoadsaveMan; class ObjectMan; +class InventoryMan; enum direction { @@ -101,6 +102,7 @@ public: ChampionMan *_championMan; LoadsaveMan *_loadsaveMan; ObjectMan *_objectMan; + InventoryMan *_inventoryMan; bool _stopWaitingForPlayerInput; // G0321_B_StopWaitingForPlayerInput bool _gameTimeTicking; // @ G0301_B_GameTimeTicking bool _restartGameAllowed; // @ G0524_B_RestartGameAllowed diff --git a/engines/dm/inventory.cpp b/engines/dm/inventory.cpp new file mode 100644 index 0000000000..378d79839b --- /dev/null +++ b/engines/dm/inventory.cpp @@ -0,0 +1,11 @@ +#include "inventory.h" + + + +namespace DM { + +Viewport gViewportFloppyZzzCross = {174, 2}; // @ G0041_s_Graphic562_Box_ViewportFloppyZzzCross + +InventoryMan::InventoryMan(DMEngine *vm): _vm(vm) {} + +} \ No newline at end of file diff --git a/engines/dm/inventory.h b/engines/dm/inventory.h new file mode 100644 index 0000000000..06488fe4d4 --- /dev/null +++ b/engines/dm/inventory.h @@ -0,0 +1,14 @@ +#include "dm.h" +#include "gfx.h" + + + +namespace DM { + +class InventoryMan { + DMEngine *_vm; +public: + InventoryMan(DMEngine *vm); +}; + +} \ No newline at end of file diff --git a/engines/dm/module.mk b/engines/dm/module.mk index 088caf82d3..3a7fa1038c 100644 --- a/engines/dm/module.mk +++ b/engines/dm/module.mk @@ -9,7 +9,8 @@ MODULE_OBJS := \ menus.o \ champion.o \ loadsave.o \ - objectman.o + objectman.o \ + inventory.o MODULE_DIRS += \ engines/dm -- cgit v1.2.3