From dddd07cc8754117811c296d9b0c384306e70baa0 Mon Sep 17 00:00:00 2001 From: Filippos Karapetis Date: Fri, 4 Dec 2015 22:28:38 +0200 Subject: LAB: Remove unused code --- engines/lab/engine.cpp | 37 ------------------------------------- engines/lab/parsefun.h | 6 ------ 2 files changed, 43 deletions(-) (limited to 'engines/lab') diff --git a/engines/lab/engine.cpp b/engines/lab/engine.cpp index b4b20e7e4d..b6e6f7282b 100644 --- a/engines/lab/engine.cpp +++ b/engines/lab/engine.cpp @@ -49,8 +49,6 @@ extern uint16 NumInv, ManyRooms, HighestCondition, Direction; bool ispal = false, noupdatediff = false, MainDisplay = true, QuitLab = false; -#define BUFFERSIZE 850000L - /* LAB: Labyrinth specific code for the special puzzles */ #define SPECIALLOCK 100 #define SPECIALBRICK 101 @@ -1062,8 +1060,6 @@ void LabEngine::go() { _event->initMouse(); - initRoomBuffer(); - _msgFont = _resource->getFont("P:AvanteG.12"); _event->mouseHide(); @@ -1097,7 +1093,6 @@ void LabEngine::go() { closeFont(_msgFont); - freeRoomBuffer(); _graphics->freePict(); freeScreens(); @@ -1200,36 +1195,4 @@ void LabEngine::mayShowCrumbIndicatorOff() { } } -/* Have to make sure that ROOMBUFFERSIZE is bigger than the biggest piece of memory - that we need */ -#define ROOMBUFFERSIZE (2 * 20480L) - -static void *_roomBuffer = nullptr; -static uint16 _curMarker = 0; -static void *_memPlace = nullptr; - -/*****************************************************************************/ -/* Allocates the memory for the room buffers. */ -/*****************************************************************************/ -bool initRoomBuffer() { - _curMarker = 0; - - if ((_roomBuffer = calloc(ROOMBUFFERSIZE, 1))) { - _memPlace = _roomBuffer; - - return true; - } else - return false; -} - -/*****************************************************************************/ -/* Frees the memory for the room buffers. */ -/*****************************************************************************/ -void freeRoomBuffer() { - if (_roomBuffer) { - free(_roomBuffer); - _roomBuffer = nullptr; - } -} - } // End of namespace Lab diff --git a/engines/lab/parsefun.h b/engines/lab/parsefun.h index ad8f04b0e9..7f8895176b 100644 --- a/engines/lab/parsefun.h +++ b/engines/lab/parsefun.h @@ -40,12 +40,6 @@ namespace Lab { bool parse(const char *inputFile); - -/* From allocRoom.c */ - -bool initRoomBuffer(); -void freeRoomBuffer(); - /* From ProcessRoom.c */ ViewData *getViewData(uint16 roomNum, uint16 direction); -- cgit v1.2.3