aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/kyra/animator_v1.cpp6
-rw-r--r--engines/kyra/gui_hof.cpp4
-rw-r--r--engines/kyra/gui_v1.cpp2
-rw-r--r--engines/kyra/items_v2.cpp2
-rw-r--r--engines/kyra/kyra_hof.cpp42
-rw-r--r--engines/kyra/kyra_mr.cpp4
-rw-r--r--engines/kyra/kyra_v1.cpp30
-rw-r--r--engines/kyra/kyra_v2.cpp2
-rw-r--r--engines/kyra/scene.cpp20
-rw-r--r--engines/kyra/scene_hof.cpp2
-rw-r--r--engines/kyra/scene_mr.cpp4
-rw-r--r--engines/kyra/screen.cpp32
-rw-r--r--engines/kyra/screen_hof.cpp2
-rw-r--r--engines/kyra/screen_v1.cpp18
-rw-r--r--engines/kyra/script.cpp6
-rw-r--r--engines/kyra/script_tim.cpp4
-rw-r--r--engines/kyra/seqplayer.cpp8
-rw-r--r--engines/kyra/sequences_hof.cpp18
-rw-r--r--engines/kyra/sequences_mr.cpp2
-rw-r--r--engines/kyra/sequences_v1.cpp10
-rw-r--r--engines/kyra/sound.cpp4
-rw-r--r--engines/kyra/sound_adlib.cpp6
-rw-r--r--engines/kyra/sound_digital.cpp10
-rw-r--r--engines/kyra/sound_towns.cpp32
-rw-r--r--engines/kyra/sprites.cpp8
-rw-r--r--engines/kyra/staticres.cpp54
-rw-r--r--engines/kyra/text_hof.cpp2
-rw-r--r--engines/kyra/vqa.cpp14
-rw-r--r--engines/kyra/wsamovie.cpp14
29 files changed, 181 insertions, 181 deletions
diff --git a/engines/kyra/animator_v1.cpp b/engines/kyra/animator_v1.cpp
index ea56efd9fb..619c6c3d70 100644
--- a/engines/kyra/animator_v1.cpp
+++ b/engines/kyra/animator_v1.cpp
@@ -50,8 +50,8 @@ Animator_v1::Animator_v1(KyraEngine_v1 *vm, OSystem *system) {
Animator_v1::~Animator_v1() {
close();
- delete [] _actorBkgBackUp[0];
- delete [] _actorBkgBackUp[1];
+ delete[] _actorBkgBackUp[0];
+ delete[] _actorBkgBackUp[1];
}
void Animator_v1::init(int actors_, int items_, int sprites_) {
@@ -71,7 +71,7 @@ void Animator_v1::close() {
debugC(9, kDebugLevelAnimator, "Animator_v1::close()");
if (_initOk) {
_initOk = false;
- delete [] _screenObjects;
+ delete[] _screenObjects;
_screenObjects = _actors = _items = _sprites = _objectQueue = 0;
}
}
diff --git a/engines/kyra/gui_hof.cpp b/engines/kyra/gui_hof.cpp
index d1fcaa4712..cc212d28fc 100644
--- a/engines/kyra/gui_hof.cpp
+++ b/engines/kyra/gui_hof.cpp
@@ -468,13 +468,13 @@ void KyraEngine_HoF::showBookPage() {
if (leftPage) {
bookDecodeText(leftPage);
bookPrintText(2, leftPage, 20, leftPageY+20, 0x31);
- delete [] leftPage;
+ delete[] leftPage;
}
if (rightPage) {
bookDecodeText(rightPage);
bookPrintText(2, rightPage, 176, rightPageY+20, 0x31);
- delete [] rightPage;
+ delete[] rightPage;
}
_screen->showMouse();
}
diff --git a/engines/kyra/gui_v1.cpp b/engines/kyra/gui_v1.cpp
index e5a0c42281..2d2c4f1219 100644
--- a/engines/kyra/gui_v1.cpp
+++ b/engines/kyra/gui_v1.cpp
@@ -194,7 +194,7 @@ GUI_v1::GUI_v1(KyraEngine_v1 *vm, Screen_v1 *screen) : GUI(vm), _vm(vm), _screen
}
GUI_v1::~GUI_v1() {
- delete [] _menu;
+ delete[] _menu;
}
int GUI_v1::processButtonList(Button *list, uint16 inputFlag) {
diff --git a/engines/kyra/items_v2.cpp b/engines/kyra/items_v2.cpp
index 78768c70ab..923bf876b1 100644
--- a/engines/kyra/items_v2.cpp
+++ b/engines/kyra/items_v2.cpp
@@ -30,7 +30,7 @@ namespace Kyra {
void KyraEngine_v2::initItemList(int size) {
debugC(9, kDebugLevelMain, "KyraEngine_v2::initItemList(%d)", size);
- delete [] _itemList;
+ delete[] _itemList;
_itemList = new Item[size];
assert(_itemList);
diff --git a/engines/kyra/kyra_hof.cpp b/engines/kyra/kyra_hof.cpp
index 4ca695542c..7aa5f9373b 100644
--- a/engines/kyra/kyra_hof.cpp
+++ b/engines/kyra/kyra_hof.cpp
@@ -160,17 +160,17 @@ KyraEngine_HoF::~KyraEngine_HoF() {
if (_sequenceSoundList) {
for (int i = 0; i < _sequenceSoundListSize; i++) {
if (_sequenceSoundList[i])
- delete [] _sequenceSoundList[i];
+ delete[] _sequenceSoundList[i];
}
- delete [] _sequenceSoundList;
+ delete[] _sequenceSoundList;
_sequenceSoundList = NULL;
}
if (_dlgBuffer)
- delete [] _dlgBuffer;
+ delete[] _dlgBuffer;
for (int i = 0; i < 19; i++)
- delete [] _conversationState[i];
- delete [] _conversationState;
+ delete[] _conversationState[i];
+ delete[] _conversationState;
for (Common::Array<const TIMOpcode*>::iterator i = _timOpcodes.begin(); i != _timOpcodes.end(); ++i)
delete *i;
@@ -762,24 +762,24 @@ void KyraEngine_HoF::delay(uint32 amount, bool updateGame, bool isMainLoop) {
}
void KyraEngine_HoF::cleanup() {
- delete [] _inventoryButtons; _inventoryButtons = 0;
+ delete[] _inventoryButtons; _inventoryButtons = 0;
- delete [] _gamePlayBuffer; _gamePlayBuffer = 0;
- delete [] _unkBuf500Bytes; _unkBuf500Bytes = 0;
- delete [] _unkBuf200kByte; _unkBuf200kByte = 0;
+ delete[] _gamePlayBuffer; _gamePlayBuffer = 0;
+ delete[] _unkBuf500Bytes; _unkBuf500Bytes = 0;
+ delete[] _unkBuf200kByte; _unkBuf200kByte = 0;
freeSceneShapePtrs();
if (_optionsBuffer != _cCodeBuffer)
- delete [] _optionsBuffer;
+ delete[] _optionsBuffer;
_optionsBuffer = 0;
- delete [] _cCodeBuffer; _cCodeBuffer = 0;
- delete [] _chapterBuffer; _chapterBuffer = 0;
+ delete[] _cCodeBuffer; _cCodeBuffer = 0;
+ delete[] _chapterBuffer; _chapterBuffer = 0;
- delete [] _talkObjectList; _talkObjectList = 0;
- delete [] _shapeDescTable; _shapeDescTable = 0;
+ delete[] _talkObjectList; _talkObjectList = 0;
+ delete[] _shapeDescTable; _shapeDescTable = 0;
- delete [] _gfxBackUpRect; _gfxBackUpRect = 0;
+ delete[] _gfxBackUpRect; _gfxBackUpRect = 0;
for (int i = 0; i < ARRAYSIZE(_sceneAnimMovie); ++i) {
delete _sceneAnimMovie[i];
@@ -790,7 +790,7 @@ void KyraEngine_HoF::cleanup() {
_wsaSlots[i] = 0;
}
for (int i = 0; i < ARRAYSIZE(_buttonShapes); ++i) {
- delete [] _buttonShapes[i];
+ delete[] _buttonShapes[i];
_buttonShapes[i] = 0;
}
@@ -804,7 +804,7 @@ void KyraEngine_HoF::loadCCodeBuffer(const char *file) {
strcpy(tempString, file);
changeFileExtension(tempString);
- delete [] _cCodeBuffer;
+ delete[] _cCodeBuffer;
_cCodeBuffer = _res->fileData(tempString, 0);
}
@@ -813,7 +813,7 @@ void KyraEngine_HoF::loadOptionsBuffer(const char *file) {
strcpy(tempString, file);
changeFileExtension(tempString);
- delete [] _optionsBuffer;
+ delete[] _optionsBuffer;
_optionsBuffer = _res->fileData(tempString, 0);
}
@@ -828,7 +828,7 @@ void KyraEngine_HoF::loadChapterBuffer(int chapter) {
strcpy(tempString, chapterFilenames[chapter-1]);
changeFileExtension(tempString);
- delete [] _chapterBuffer;
+ delete[] _chapterBuffer;
_chapterBuffer = _res->fileData(tempString, 0);
_currentChapter = chapter;
}
@@ -1034,7 +1034,7 @@ void KyraEngine_HoF::loadCharacterShapes(int shapes) {
uint8 *data = _res->fileData(file, 0);
for (int i = 9; i <= 32; ++i)
addShapeToPool(data, i, i-9);
- delete [] data;
+ delete[] data;
_characterShapeFile = shapes;
}
@@ -1385,7 +1385,7 @@ int KyraEngine_HoF::initAnimationShapes(uint8 *filedata) {
void KyraEngine_HoF::uninitAnimationShapes(int count, uint8 *filedata) {
for (int i = 0; i < count; ++i)
remShapeFromPool(i+33);
- delete [] filedata;
+ delete[] filedata;
setNextIdleAnimTimer();
}
diff --git a/engines/kyra/kyra_mr.cpp b/engines/kyra/kyra_mr.cpp
index 5e23813eb2..1ed347953d 100644
--- a/engines/kyra/kyra_mr.cpp
+++ b/engines/kyra/kyra_mr.cpp
@@ -533,7 +533,7 @@ void KyraEngine_MR::initMouseShapes() {
assert(data);
for (int i = 0; i <= 6; ++i)
_gameShapes[i] = _screen->makeShapeCopy(data, i);
- delete [] data;
+ delete[] data;
}
void KyraEngine_MR::startup() {
@@ -728,7 +728,7 @@ void KyraEngine_MR::initItems() {
memcpy(_itemBuffer1, itemsDat , 72);
memcpy(_itemBuffer2, itemsDat+72, 144);
- delete [] itemsDat;
+ delete[] itemsDat;
_screen->_curPage = 0;
}
diff --git a/engines/kyra/kyra_v1.cpp b/engines/kyra/kyra_v1.cpp
index 98514a3c37..693ea74a35 100644
--- a/engines/kyra/kyra_v1.cpp
+++ b/engines/kyra/kyra_v1.cpp
@@ -116,28 +116,28 @@ KyraEngine_v1::~KyraEngine_v1() {
delete _animator;
delete _seq;
- delete [] _characterList;
+ delete[] _characterList;
- delete [] _movFacingTable;
+ delete[] _movFacingTable;
- delete [] _gui->_scrollUpButton.data0ShapePtr;
- delete [] _gui->_scrollUpButton.data1ShapePtr;
- delete [] _gui->_scrollUpButton.data2ShapePtr;
- delete [] _gui->_scrollDownButton.data0ShapePtr;
- delete [] _gui->_scrollDownButton.data1ShapePtr;
- delete [] _gui->_scrollDownButton.data2ShapePtr;
+ delete[] _gui->_scrollUpButton.data0ShapePtr;
+ delete[] _gui->_scrollUpButton.data1ShapePtr;
+ delete[] _gui->_scrollUpButton.data2ShapePtr;
+ delete[] _gui->_scrollDownButton.data0ShapePtr;
+ delete[] _gui->_scrollDownButton.data1ShapePtr;
+ delete[] _gui->_scrollDownButton.data2ShapePtr;
- delete [] _buttonData;
- delete [] _buttonDataListPtr;
+ delete[] _buttonData;
+ delete[] _buttonDataListPtr;
delete _gui;
- delete [] _itemBkgBackUp[0];
- delete [] _itemBkgBackUp[1];
+ delete[] _itemBkgBackUp[0];
+ delete[] _itemBkgBackUp[1];
for (int i = 0; i < ARRAYSIZE(_shapes); ++i) {
if (_shapes[i] != 0) {
- delete [] _shapes[i];
+ delete[] _shapes[i];
for (int i2 = 0; i2 < ARRAYSIZE(_shapes); i2++) {
if (_shapes[i2] == _shapes[i] && i2 != i) {
_shapes[i2] = 0;
@@ -148,7 +148,7 @@ KyraEngine_v1::~KyraEngine_v1() {
}
for (int i = 0; i < ARRAYSIZE(_sceneAnimTable); ++i)
- delete [] _sceneAnimTable[i];
+ delete[] _sceneAnimTable[i];
}
int KyraEngine_v1::init() {
@@ -623,7 +623,7 @@ void KyraEngine_v1::freeShapes123() {
debugC(9, kDebugLevelMain, "KyraEngine_v1::freeShapes123()");
for (int i = 123; i <= 172; ++i) {
- delete [] _shapes[i];
+ delete[] _shapes[i];
_shapes[i] = 0;
}
}
diff --git a/engines/kyra/kyra_v2.cpp b/engines/kyra/kyra_v2.cpp
index ccea7e08bb..6c4adea88c 100644
--- a/engines/kyra/kyra_v2.cpp
+++ b/engines/kyra/kyra_v2.cpp
@@ -238,7 +238,7 @@ void KyraEngine_v2::addShapeToPool(uint8 *shpData, int index) {
void KyraEngine_v2::remShapeFromPool(int idx) {
ShapeMap::iterator iter = _gameShapes.find(idx);
if (iter != _gameShapes.end()) {
- delete [] iter->_value;
+ delete[] iter->_value;
iter->_value = 0;
}
}
diff --git a/engines/kyra/scene.cpp b/engines/kyra/scene.cpp
index f3e41b2d39..9516da2dbd 100644
--- a/engines/kyra/scene.cpp
+++ b/engines/kyra/scene.cpp
@@ -60,8 +60,8 @@ int KyraEngine::findWay(int x, int y, int toX, int toY, int *moveTable, int move
if (lineIsPassable(curX, curY)) {
if (lastUsedEntry == moveTableSize) {
- delete [] pathTable1;
- delete [] pathTable2;
+ delete[] pathTable1;
+ delete[] pathTable2;
return 0x7D00;
}
// debug drawing
@@ -104,8 +104,8 @@ int KyraEngine::findWay(int x, int y, int toX, int toY, int *moveTable, int move
tempValue = findSubPath(x, y, curX, curY, pathTable2, 0, 0x7D0);
if (curX == toX && curY == toY) {
if (temp == 0x7D00 && tempValue == 0x7D00) {
- delete [] pathTable1;
- delete [] pathTable2;
+ delete[] pathTable1;
+ delete[] pathTable2;
return 0x7D00;
}
}
@@ -116,16 +116,16 @@ int KyraEngine::findWay(int x, int y, int toX, int toY, int *moveTable, int move
if (temp < tempValue) {
if (lastUsedEntry + temp > moveTableSize) {
- delete [] pathTable1;
- delete [] pathTable2;
+ delete[] pathTable1;
+ delete[] pathTable2;
return 0x7D00;
}
memcpy(&moveTable[lastUsedEntry], pathTable1, temp*sizeof(int));
lastUsedEntry += temp;
} else {
if (lastUsedEntry + tempValue > moveTableSize) {
- delete [] pathTable1;
- delete [] pathTable2;
+ delete[] pathTable1;
+ delete[] pathTable2;
return 0x7D00;
}
memcpy(&moveTable[lastUsedEntry], pathTable2, tempValue*sizeof(int));
@@ -137,8 +137,8 @@ int KyraEngine::findWay(int x, int y, int toX, int toY, int *moveTable, int move
break;
}
- delete [] pathTable1;
- delete [] pathTable2;
+ delete[] pathTable1;
+ delete[] pathTable2;
moveTable[lastUsedEntry] = 8;
return lastUsedEntry;
}
diff --git a/engines/kyra/scene_hof.cpp b/engines/kyra/scene_hof.cpp
index 3fc7947253..25613e2eb9 100644
--- a/engines/kyra/scene_hof.cpp
+++ b/engines/kyra/scene_hof.cpp
@@ -702,7 +702,7 @@ void KyraEngine_HoF::initSceneScreen(int unk1) {
void KyraEngine_HoF::freeSceneShapePtrs() {
debugC(9, kDebugLevelMain, "KyraEngine_HoF::freeSceneShapePtrs()");
for (int i = 0; i < ARRAYSIZE(_sceneShapeTable); ++i)
- delete [] _sceneShapeTable[i];
+ delete[] _sceneShapeTable[i];
memset(_sceneShapeTable, 0, sizeof(_sceneShapeTable));
}
diff --git a/engines/kyra/scene_mr.cpp b/engines/kyra/scene_mr.cpp
index 7da0dd9f75..03cc05cd34 100644
--- a/engines/kyra/scene_mr.cpp
+++ b/engines/kyra/scene_mr.cpp
@@ -311,7 +311,7 @@ void KyraEngine_MR::enterNewSceneUnk2(int unk1) {
void KyraEngine_MR::unloadScene() {
debugC(9, kDebugLevelMain, "KyraEngine_MR::unloadScene()");
- delete [] _sceneStrings;
+ delete[] _sceneStrings;
_sceneStrings = 0;
musicUpdate(0);
_emc->unload(&_sceneScriptData);
@@ -325,7 +325,7 @@ void KyraEngine_MR::unloadScene() {
void KyraEngine_MR::freeSceneShapes() {
debugC(9, kDebugLevelMain, "KyraEngine_MR::freeSceneShapes()");
for (uint i = 0; i < ARRAYSIZE(_sceneShapes); ++i) {
- delete [] _sceneShapes[i];
+ delete[] _sceneShapes[i];
_sceneShapes[i] = 0;
}
}
diff --git a/engines/kyra/screen.cpp b/engines/kyra/screen.cpp
index 298483465e..0f3d3f0259 100644
--- a/engines/kyra/screen.cpp
+++ b/engines/kyra/screen.cpp
@@ -40,28 +40,28 @@ Screen::Screen(KyraEngine *vm, OSystem *system)
Screen::~Screen() {
for (int i = 0; i < SCREEN_OVLS_NUM; ++i)
- delete [] _sjisOverlayPtrs[i];
+ delete[] _sjisOverlayPtrs[i];
- delete [] _pagePtrs[0];
+ delete[] _pagePtrs[0];
for (int f = 0; f < ARRAYSIZE(_fonts); ++f) {
delete[] _fonts[f].fontData;
_fonts[f].fontData = NULL;
}
- delete [] _sjisFontData;
- delete [] _sjisTempPage;
- delete [] _currentPalette;
- delete [] _screenPalette;
- delete [] _decodeShapeBuffer;
- delete [] _animBlockPtr;
+ delete[] _sjisFontData;
+ delete[] _sjisTempPage;
+ delete[] _currentPalette;
+ delete[] _screenPalette;
+ delete[] _decodeShapeBuffer;
+ delete[] _animBlockPtr;
if (_vm->gameFlags().platform != Common::kPlatformAmiga) {
for (int i = 0; i < ARRAYSIZE(_palettes); ++i)
- delete [] _palettes[i];
+ delete[] _palettes[i];
}
- delete [] _dirtyRects;
+ delete[] _dirtyRects;
}
bool Screen::init() {
@@ -843,7 +843,7 @@ void Screen::drawLine(bool vertical, int x, int y, int length, int color) {
void Screen::setAnimBlockPtr(int size) {
debugC(9, kDebugLevelScreen, "Screen::setAnimBlockPtr(%d)", size);
- delete [] _animBlockPtr;
+ delete[] _animBlockPtr;
_animBlockPtr = new uint8[size];
assert(_animBlockPtr);
memset(_animBlockPtr, 0, size);
@@ -867,7 +867,7 @@ bool Screen::loadFont(FontId fontId, const char *filename) {
error("fontId %d is invalid", fontId);
if (fnt->fontData)
- delete [] fnt->fontData;
+ delete[] fnt->fontData;
uint32 sz = 0;
uint8 *fontData = fnt->fontData = _vm->resource()->fileData(filename, &sz);
@@ -2235,7 +2235,7 @@ uint8 *Screen::encodeShape(int x, int y, int w, int h, int flags) {
uint8 *newShape2 = new uint8[shapeSize];
assert(newShape2);
memcpy(newShape2, newShape, shapeSize);
- delete [] newShape;
+ delete[] newShape;
newShape = newShape2;
} else {
dst = shapePtrBackUp;
@@ -2469,7 +2469,7 @@ void Screen::setMouseCursor(int x, int y, byte *shape) {
copyRegionToBuffer(8, xOffset, 0, mouseWidth, mouseHeight, cursor);
CursorMan.replaceCursor(cursor, mouseWidth, mouseHeight, x, y, 0);
CursorMan.showMouse(true);
- delete [] cursor;
+ delete[] cursor;
// makes sure that the cursor is drawn
// we do not use Screen::updateScreen here
@@ -2694,7 +2694,7 @@ void Screen::loadBitmap(const char *filename, int tempPage, int dstPage, uint8 *
if (skip)
srcData -= 4;
- delete [] srcData;
+ delete[] srcData;
}
bool Screen::loadPalette(const char *filename, uint8 *palData) {
@@ -2722,7 +2722,7 @@ bool Screen::loadPalette(const char *filename, uint8 *palData) {
memcpy(palData, srcData, fileSize);
}
}
- delete [] srcData;
+ delete[] srcData;
return true;
}
diff --git a/engines/kyra/screen_hof.cpp b/engines/kyra/screen_hof.cpp
index 9192626159..9a4237366b 100644
--- a/engines/kyra/screen_hof.cpp
+++ b/engines/kyra/screen_hof.cpp
@@ -37,7 +37,7 @@ Screen_HoF::Screen_HoF(KyraEngine_HoF *vm, OSystem *system)
}
Screen_HoF::~Screen_HoF() {
- delete [] _wsaFrameAnimBuffer;
+ delete[] _wsaFrameAnimBuffer;
}
void Screen_HoF::setScreenDim(int dim) {
diff --git a/engines/kyra/screen_v1.cpp b/engines/kyra/screen_v1.cpp
index 9454418fd5..7af01358e5 100644
--- a/engines/kyra/screen_v1.cpp
+++ b/engines/kyra/screen_v1.cpp
@@ -36,20 +36,20 @@ Screen_v1::Screen_v1(KyraEngine_v1 *vm, OSystem *system)
}
Screen_v1::~Screen_v1() {
- delete [] _bitBlitRects;
+ delete[] _bitBlitRects;
for (int i = 0; i < ARRAYSIZE(_saveLoadPage); ++i) {
- delete [] _saveLoadPage[i];
+ delete[] _saveLoadPage[i];
_saveLoadPage[i] = 0;
}
for (int i = 0; i < ARRAYSIZE(_saveLoadPageOvl); ++i) {
- delete [] _saveLoadPageOvl[i];
+ delete[] _saveLoadPageOvl[i];
_saveLoadPageOvl[i] = 0;
}
- delete [] _unkPtr1;
- delete [] _unkPtr2;
+ delete[] _unkPtr1;
+ delete[] _unkPtr2;
}
bool Screen_v1::init() {
@@ -148,7 +148,7 @@ void Screen_v1::savePageToDisk(const char *file, int page) {
void Screen_v1::loadPageFromDisk(const char *file, int page) {
debugC(9, kDebugLevelScreen, "Screen_v1::loadPageFromDisk('%s', %d)", file, page);
copyBlockToPage(page, 0, 0, SCREEN_W, SCREEN_H, _saveLoadPage[page/2]);
- delete [] _saveLoadPage[page/2];
+ delete[] _saveLoadPage[page/2];
if (_saveLoadPageOvl[page/2]) {
uint8 *dstPage = getOverlayPtr(page);
@@ -158,18 +158,18 @@ void Screen_v1::loadPageFromDisk(const char *file, int page) {
}
memcpy(dstPage, _saveLoadPageOvl[page/2], SCREEN_OVL_SJIS_SIZE);
- delete [] _saveLoadPageOvl[page/2];
+ delete[] _saveLoadPageOvl[page/2];
_saveLoadPageOvl[page/2] = 0;
} _saveLoadPage[page/2] = 0;
}
void Screen_v1::deletePageFromDisk(int page) {
debugC(9, kDebugLevelScreen, "Screen_v1::deletePageFromDisk(%d)", page);
- delete [] _saveLoadPage[page/2];
+ delete[] _saveLoadPage[page/2];
_saveLoadPage[page/2] = 0;
if (_saveLoadPageOvl[page/2]) {
- delete [] _saveLoadPageOvl[page/2];
+ delete[] _saveLoadPageOvl[page/2];
_saveLoadPageOvl[page/2] = 0;
}
}
diff --git a/engines/kyra/script.cpp b/engines/kyra/script.cpp
index e9dc34e581..e00ac6878d 100644
--- a/engines/kyra/script.cpp
+++ b/engines/kyra/script.cpp
@@ -139,9 +139,9 @@ void EMCInterpreter::unload(EMCData *data) {
if (!data)
return;
- delete [] data->text;
- delete [] data->ordr;
- delete [] data->data;
+ delete[] data->text;
+ delete[] data->ordr;
+ delete[] data->data;
data->text = 0;
data->ordr = data->data = 0;
diff --git a/engines/kyra/script_tim.cpp b/engines/kyra/script_tim.cpp
index 67e076cbf8..fa9d54e8be 100644
--- a/engines/kyra/script_tim.cpp
+++ b/engines/kyra/script_tim.cpp
@@ -128,8 +128,8 @@ void TIMInterpreter::unload(TIM *&tim) const {
if (!tim)
return;
- delete [] tim->text;
- delete [] tim->avtl;
+ delete[] tim->text;
+ delete[] tim->avtl;
delete tim;
tim = 0;
}
diff --git a/engines/kyra/seqplayer.cpp b/engines/kyra/seqplayer.cpp
index ddd8beb5dc..9a670ce85f 100644
--- a/engines/kyra/seqplayer.cpp
+++ b/engines/kyra/seqplayer.cpp
@@ -110,7 +110,7 @@ void SeqPlayer::makeHandShapes() {
} else {
for (int i = 0; i < ARRAYSIZE(_handShapes); ++i) {
if (_handShapes[i])
- delete [] _handShapes[i];
+ delete[] _handShapes[i];
_handShapes[i] = setPanPages(3, i);
assert(_handShapes[i]);
}
@@ -120,7 +120,7 @@ void SeqPlayer::makeHandShapes() {
void SeqPlayer::freeHandShapes() {
debugC(9, kDebugLevelSequence, "SeqPlayer::freeHandShapes()");
for (int i = 0; i < ARRAYSIZE(_handShapes); ++i) {
- delete [] _handShapes[i];
+ delete[] _handShapes[i];
_handShapes[i] = 0;
}
}
@@ -262,7 +262,7 @@ void SeqPlayer::s1_loadPalette() {
uint8 *srcData;
srcData = _res->fileData(_vm->seqCOLTable()[colNum], &fileSize);
memcpy(_screen->_currentPalette, srcData, fileSize);
- delete [] srcData;
+ delete[] srcData;
}
}
@@ -667,7 +667,7 @@ bool SeqPlayer::playSequence(const uint8 *seqData, bool skipSeq) {
_screen->updateScreen();
}
- delete [] _specialBuffer;
+ delete[] _specialBuffer;
_specialBuffer = 0;
return seqSkippedFlag;
}
diff --git a/engines/kyra/sequences_hof.cpp b/engines/kyra/sequences_hof.cpp
index 050b00c878..49a5a7dc94 100644
--- a/engines/kyra/sequences_hof.cpp
+++ b/engines/kyra/sequences_hof.cpp
@@ -1535,7 +1535,7 @@ void KyraEngine_HoF::seq_finaleActorScreen() {
seq_displayScrollText(dataPtr, &d, 2, 6, 5, 1, Screen::FID_GOLDFONT_FNT, Screen::FID_GOLDFONT_FNT, 0, talkieCreditsSpecial);
delay(120);
- delete [] dataPtr;
+ delete[] dataPtr;
_staticres->unloadId(k2SeqplayCreditsSpecial);
_sound->setSoundList(&_soundData[kMusicFinale]);
_sound->loadSoundFile(0);
@@ -2537,8 +2537,8 @@ void KyraEngine_HoF::seq_displayScrollText(uint8 *data, const ScreenDim *d, int
_abortIntroFlag= false;
resetSkipFlag();
- delete [] tmp;
- delete [] tmpStringTable;
+ delete[] tmp;
+ delete[] tmpStringTable;
}
void KyraEngine_HoF::seq_scrollPage() {
@@ -2628,7 +2628,7 @@ void KyraEngine_HoF::seq_init() {
uint32 outsize = READ_LE_UINT16(shp + 4);
_animShapeFiledata = new uint8[outsize];
Screen::decodeFrame4(shp + 10, _animShapeFiledata, outsize);
- delete [] shp;
+ delete[] shp;
do {
numShp++;
@@ -2647,19 +2647,19 @@ void KyraEngine_HoF::seq_init() {
}
void KyraEngine_HoF::seq_uninit() {
- delete [] _seqProcessedString;
+ delete[] _seqProcessedString;
_seqProcessedString = NULL;
- delete [] _activeWSA;
+ delete[] _activeWSA;
_activeWSA = NULL;
- delete [] _activeText;
+ delete[] _activeText;
_activeText = NULL;
delete _seqWsa;
_seqWsa = NULL;
- delete [] _animShapeFiledata;
+ delete[] _animShapeFiledata;
_animShapeFiledata = 0;
if (_flags.isDemo && !_flags.isTalkie)
@@ -2770,7 +2770,7 @@ void KyraEngine_HoF::seq_makeBookAppear() {
}
closeInvWsa();
- delete [] rect;
+ delete[] rect;
_invWsa.running = false;
_screen->showMouse();
diff --git a/engines/kyra/sequences_mr.cpp b/engines/kyra/sequences_mr.cpp
index 8c826e2048..f41ed9c2f3 100644
--- a/engines/kyra/sequences_mr.cpp
+++ b/engines/kyra/sequences_mr.cpp
@@ -241,7 +241,7 @@ void KyraEngine_MR::uninitAnimationShapes(int count, uint8 *filedata) {
debugC(9, kDebugLevelAnimator, "KyraEngine_MR::uninitAnimationShapes(%d, %p)", count, (const void*)filedata);
for (int i = 0; i < count; ++i)
_gameShapes[9+i] = 0;
- delete [] filedata;
+ delete[] filedata;
setNextIdleAnimTimer();
}
diff --git a/engines/kyra/sequences_v1.cpp b/engines/kyra/sequences_v1.cpp
index 01906d2529..75aa1b4518 100644
--- a/engines/kyra/sequences_v1.cpp
+++ b/engines/kyra/sequences_v1.cpp
@@ -1202,7 +1202,7 @@ void KyraEngine_v1::seq_playCredits() {
_system->delayMillis(nextLoop - now);
}
- delete [] buffer;
+ delete[] buffer;
_screen->fadeToBlack();
_screen->clearCurPage();
@@ -1682,13 +1682,13 @@ void KyraEngine_v1::setupPanPages() {
int pageBackUp = _screen->_curPage;
_screen->_curPage = 2;
- delete [] _panPagesTable[19];
+ delete[] _panPagesTable[19];
_panPagesTable[19] = _screen->encodeShape(0, 0, 16, 9, 0);
assert(_panPagesTable[19]);
int curX = 16;
for (int i = 0; i < 19; ++i) {
- delete [] _panPagesTable[i];
+ delete[] _panPagesTable[i];
_panPagesTable[i] = _screen->encodeShape(curX, 0, 8, 5, 0);
assert(_panPagesTable[i]);
curX += 8;
@@ -1697,7 +1697,7 @@ void KyraEngine_v1::setupPanPages() {
_screen->_curPage = pageBackUp;
} else {
for (int i = 0; i <= 19; ++i) {
- delete [] _panPagesTable[i];
+ delete[] _panPagesTable[i];
_panPagesTable[i] = _seq->setPanPages(3, i);
assert(_panPagesTable[i]);
}
@@ -1710,7 +1710,7 @@ void KyraEngine_v1::freePanPages() {
delete _endSequenceBackUpRect;
_endSequenceBackUpRect = 0;
for (int i = 0; i <= 19; ++i) {
- delete [] _panPagesTable[i];
+ delete[] _panPagesTable[i];
_panPagesTable[i] = 0;
}
}
diff --git a/engines/kyra/sound.cpp b/engines/kyra/sound.cpp
index 887e9c7267..90cbd5e539 100644
--- a/engines/kyra/sound.cpp
+++ b/engines/kyra/sound.cpp
@@ -107,7 +107,7 @@ bool Sound::voicePlay(const char *file, bool isSfx) {
_soundChannels[h].file = file;
_mixer->playInputStream(isSfx ? Audio::Mixer::kSFXSoundType : Audio::Mixer::kSpeechSoundType, &_soundChannels[h].channelHandle, audioStream);
- delete [] fileData;
+ delete[] fileData;
fileSize = 0;
return true;
@@ -320,7 +320,7 @@ void SoundMidiPC::metaEvent(byte type, byte *data, uint16 length) {
struct DeleterArray {
void operator ()(byte *ptr) {
- delete [] ptr;
+ delete[] ptr;
}
};
diff --git a/engines/kyra/sound_adlib.cpp b/engines/kyra/sound_adlib.cpp
index fa5a978665..b744579c98 100644
--- a/engines/kyra/sound_adlib.cpp
+++ b/engines/kyra/sound_adlib.cpp
@@ -507,7 +507,7 @@ int AdlibDriver::snd_deinitDriver(va_list &list) {
int AdlibDriver::snd_setSoundData(va_list &list) {
if (_soundData) {
- delete [] _soundData;
+ delete[] _soundData;
_soundData = 0;
}
_soundData = va_arg(list, uint8*);
@@ -2232,7 +2232,7 @@ SoundAdlibPC::SoundAdlibPC(KyraEngine *vm, Audio::Mixer *mixer)
SoundAdlibPC::~SoundAdlibPC() {
delete _driver;
- delete [] _soundDataPtr;
+ delete[] _soundDataPtr;
}
bool SoundAdlibPC::init() {
@@ -2382,7 +2382,7 @@ void SoundAdlibPC::loadSoundFile(uint file) {
memcpy(_soundDataPtr, p, soundDataSize*sizeof(uint8));
- delete [] file_data;
+ delete[] file_data;
file_data = p = 0;
file_size = 0;
diff --git a/engines/kyra/sound_digital.cpp b/engines/kyra/sound_digital.cpp
index f8c6fbdb04..ab60c3e1f5 100644
--- a/engines/kyra/sound_digital.cpp
+++ b/engines/kyra/sound_digital.cpp
@@ -107,8 +107,8 @@ AUDStream::AUDStream(Common::SeekableReadStream *stream, bool loop) : _stream(st
}
AUDStream::~AUDStream() {
- delete [] _outBuffer;
- delete [] _inBuffer;
+ delete[] _outBuffer;
+ delete[] _inBuffer;
delete _stream;
}
@@ -174,7 +174,7 @@ int AUDStream::readChunk(int16 *buffer, const int maxSamples) {
if (size == outSize) {
if (outSize > _outBufferSize) {
_outBufferSize = outSize;
- delete [] _outBuffer;
+ delete[] _outBuffer;
_outBuffer = new uint8[_outBufferSize];
assert(_outBuffer);
}
@@ -187,14 +187,14 @@ int AUDStream::readChunk(int16 *buffer, const int maxSamples) {
if (outSize > _outBufferSize) {
_outBufferSize = outSize;
- delete [] _outBuffer;
+ delete[] _outBuffer;
_outBuffer = new uint8[_outBufferSize];
assert(_outBuffer);
}
if (size > _inBufferSize) {
_inBufferSize = size;
- delete [] _inBuffer;
+ delete[] _inBuffer;
_inBuffer = new uint8[_inBufferSize];
assert(_inBuffer);
}
diff --git a/engines/kyra/sound_towns.cpp b/engines/kyra/sound_towns.cpp
index 9ac865c157..d2ce48f452 100644
--- a/engines/kyra/sound_towns.cpp
+++ b/engines/kyra/sound_towns.cpp
@@ -599,18 +599,18 @@ SoundTowns_EuphonyDriver::~SoundTowns_EuphonyDriver() {
MidiDriver_YM2612::removeLookupTables();
if (_fmInstruments) {
- delete [] _fmInstruments;
+ delete[] _fmInstruments;
_fmInstruments = 0;
}
if (_waveInstruments) {
- delete [] _waveInstruments;
+ delete[] _waveInstruments;
_waveInstruments = 0;
}
for (int i = 0; i < 10; i++) {
if (_waveSounds[i]) {
- delete [] _waveSounds[i];
+ delete[] _waveSounds[i];
_waveSounds[i] = 0;
}
}
@@ -709,14 +709,14 @@ void SoundTowns_EuphonyDriver::send(byte chan, uint32 b) {
void SoundTowns_EuphonyDriver::loadFmInstruments(const byte *instr) {
if (_fmInstruments)
- delete [] _fmInstruments;
+ delete[] _fmInstruments;
_fmInstruments = new uint8[0x1800];
memcpy(_fmInstruments, instr, 0x1800);
}
void SoundTowns_EuphonyDriver::loadWaveInstruments(const byte *instr) {
if (_waveInstruments)
- delete [] _waveInstruments;
+ delete[] _waveInstruments;
_waveInstruments = new uint8[0x1000];
memcpy(_waveInstruments, instr, 0x1000);
@@ -724,7 +724,7 @@ void SoundTowns_EuphonyDriver::loadWaveInstruments(const byte *instr) {
for (uint8 i = 0; i < 10; i++) {
if (_waveSounds[i])
- delete [] _waveSounds[i];
+ delete[] _waveSounds[i];
uint32 numsamples = READ_LE_UINT32(pos + 0x0C);
_waveSounds[i] = new int8[numsamples + 0x20];
memcpy(_waveSounds[i], pos, 0x20);
@@ -1010,7 +1010,7 @@ SoundTowns_EuphonyTrackQueue * SoundTowns_EuphonyTrackQueue::reset() {
void SoundTowns_EuphonyTrackQueue::loadDataToCurrentPosition(uint8 * trackdata, uint32 size, bool loop) {
if (_trackData)
- delete [] _trackData;
+ delete[] _trackData;
_trackData = new uint8[0xC58A];
memset(_trackData, 0, 0xC58A);
Screen::decodeFrame4(trackdata, _trackData, size);
@@ -1051,13 +1051,13 @@ void SoundTowns_EuphonyTrackQueue::release() {
_used = _fchan = _wchan = 0;
if (_trackData) {
- delete [] _trackData;
+ delete[] _trackData;
_trackData = 0;
}
while (i) {
if (i->_trackData) {
- delete [] i->_trackData;
+ delete[] i->_trackData;
i->_trackData = 0;
}
i = i->_next;
@@ -1097,7 +1097,7 @@ SoundTowns::SoundTowns(KyraEngine *vm, Audio::Mixer *mixer)
SoundTowns::~SoundTowns() {
AudioCD.stop();
haltTrack();
- delete [] _sfxFileData;
+ delete[] _sfxFileData;
Common::StackLock lock(_mutex);
_driver->setTimerCallback(0, 0);
@@ -1164,7 +1164,7 @@ void SoundTowns::loadSoundFile(uint file) {
if (_sfxFileIndex == file)
return;
_sfxFileIndex = file;
- delete [] _sfxFileData;
+ delete[] _sfxFileData;
_sfxFileData = _vm->resource()->fileData(fileListEntry(file), 0);
}
@@ -1293,7 +1293,7 @@ bool SoundTowns::loadInstruments() {
_driver->queue()->loadDataToCurrentPosition(twm + 0x0CA0, 0xC58A);
_driver->loadWaveInstruments(_driver->queue()->trackData() + 8);
- delete [] twm;
+ delete[] twm;
_driver->queue()->release();
return true;
@@ -1311,7 +1311,7 @@ void SoundTowns::playEuphonyTrack(uint32 offset, int loop) {
_parser->property(MidiParser::mpAutoLoop, loop);
_parser->loadMusic(twm + 0x4b70 + offset, 0xC58A);
- delete [] twm;
+ delete[] twm;
}
void SoundTowns::onTimer(void * data) {
@@ -1366,7 +1366,7 @@ SoundTowns_v2::~SoundTowns_v2() {
/*if (_driver)
delete _driver;*/
if (_twnTrackData)
- delete [] _twnTrackData;
+ delete[] _twnTrackData;
}
bool SoundTowns_v2::init() {
@@ -1416,7 +1416,7 @@ void SoundTowns_v2::playTrack(uint8 track) {
char musicfile[13];
sprintf(musicfile, fileListEntry(0), track);
if (_twnTrackData)
- delete [] _twnTrackData;
+ delete[] _twnTrackData;
_twnTrackData = _vm->resource()->fileData(musicfile, 0);
//_driver->loadData(_twnTrackData);
}
@@ -1492,7 +1492,7 @@ bool SoundTowns_v2::voicePlay(const char *file, bool) {
_soundChannels[h].file = file;
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_soundChannels[h].channelHandle, _currentSFX);
- delete [] data;
+ delete[] data;
return true;
}
diff --git a/engines/kyra/sprites.cpp b/engines/kyra/sprites.cpp
index b54192abae..4177f4cd7b 100644
--- a/engines/kyra/sprites.cpp
+++ b/engines/kyra/sprites.cpp
@@ -52,11 +52,11 @@ Sprites::Sprites(KyraEngine_v1 *vm, OSystem *system) {
}
Sprites::~Sprites() {
- delete [] _dat;
+ delete[] _dat;
freeSceneShapes();
for (int i = 0; i < MAX_NUM_ANIMS; i++) {
if (_anims[i].background)
- delete [] _anims[i].background;
+ delete[] _anims[i].background;
}
}
@@ -66,7 +66,7 @@ void Sprites::setupSceneAnims() {
for (int i = 0; i < MAX_NUM_ANIMS; i++) {
if (_anims[i].background) {
- delete [] _anims[i].background;
+ delete[] _anims[i].background;
_anims[i].background = 0;
}
@@ -515,7 +515,7 @@ void Sprites::loadDat(const char *filename, SceneExits &exits) {
void Sprites::freeSceneShapes() {
debugC(9, kDebugLevelSprites, "Sprites::freeSceneShapes()");
for (int i = 0; i < ARRAYSIZE(_sceneShapes); i++ ) {
- delete [] _sceneShapes[i];
+ delete[] _sceneShapes[i];
_sceneShapes[i] = 0;
}
}
diff --git a/engines/kyra/staticres.cpp b/engines/kyra/staticres.cpp
index c9d81cc92a..59a64e3aba 100644
--- a/engines/kyra/staticres.cpp
+++ b/engines/kyra/staticres.cpp
@@ -287,7 +287,7 @@ bool StaticResource::init() {
}
if (tempSize != 3*4) {
- delete [] temp;
+ delete[] temp;
warning("'%s' has illegal filesize %d", getFilename("INDEX"), tempSize);
outputError();
return false;
@@ -297,7 +297,7 @@ bool StaticResource::init() {
uint32 gameID = READ_BE_UINT32((temp+4));
uint32 featuresValue = READ_BE_UINT32((temp+8));
- delete [] temp;
+ delete[] temp;
temp = 0;
if (version != RESFILE_VERSION) {
@@ -545,7 +545,7 @@ bool StaticResource::loadStringTable(const char *filename, void *&ptr, int &size
curPos += strLen+1;
}
- delete [] filePtr;
+ delete[] filePtr;
ptr = output;
return true;
@@ -579,7 +579,7 @@ bool StaticResource::loadShapeTable(const char *filename, void *&ptr, int &size)
loadTo[i].yOffset = *src++;
}
- delete [] filePtr;
+ delete[] filePtr;
ptr = loadTo;
return true;
@@ -609,7 +609,7 @@ bool StaticResource::loadRoomTable(const char *filename, void *&ptr, int &size)
memset(loadTo[i].needInit, 0, sizeof(loadTo[i].needInit));
}
- delete [] filePtr;
+ delete[] filePtr;
ptr = loadTo;
return true;
@@ -642,7 +642,7 @@ bool StaticResource::loadPaletteTable(const char *filename, void *&ptr, int &siz
snprintf(name, 64, "%s%d.PAL", file, i);
table[(start != 0) ? (i-start) : i] = (char*)getFile(name, size);
if (!table[(start != 0) ? (i-start) : i]) {
- delete [] table;
+ delete[] table;
return false;
}
}
@@ -743,7 +743,7 @@ bool StaticResource::loadHofSequenceData(const char *filename, void *&ptr, int &
}
}
- delete [] filePtr;
+ delete[] filePtr;
HofSeqData *loadTo = new HofSeqData;
assert(loadTo);
@@ -783,7 +783,7 @@ bool StaticResource::loadHofShapeAnimDataV1(const char *filename, void *&ptr, in
loadTo[i].frames = tmp_f;
}
- delete [] filePtr;
+ delete[] filePtr;
ptr = loadTo;
return true;
@@ -815,7 +815,7 @@ bool StaticResource::loadHofShapeAnimDataV2(const char *filename, void *&ptr, in
loadTo[i].frames = tmp_f;
}
- delete [] filePtr;
+ delete[] filePtr;
ptr = loadTo;
return true;
@@ -823,7 +823,7 @@ bool StaticResource::loadHofShapeAnimDataV2(const char *filename, void *&ptr, in
void StaticResource::freeRawData(void *&ptr, int &size) {
uint8 *data = (uint8*)ptr;
- delete [] data;
+ delete[] data;
ptr = 0;
size = 0;
}
@@ -839,14 +839,14 @@ void StaticResource::freeStringTable(void *&ptr, int &size) {
void StaticResource::freeShapeTable(void *&ptr, int &size) {
Shape *data = (Shape*)ptr;
- delete [] data;
+ delete[] data;
ptr = 0;
size = 0;
}
void StaticResource::freeRoomTable(void *&ptr, int &size) {
Room *data = (Room*)ptr;
- delete [] data;
+ delete[] data;
ptr = 0;
size = 0;
}
@@ -855,16 +855,16 @@ void StaticResource::freeHofSequenceData(void *&ptr, int &size) {
HofSeqData *h = (HofSeqData*) ptr;
for (int i = 0; i < h->numSeq; i++) {
- delete [] h->seq[i].wsaFile;
- delete [] h->seq[i].cpsFile;
+ delete[] h->seq[i].wsaFile;
+ delete[] h->seq[i].cpsFile;
}
- delete [] h->seq;
+ delete[] h->seq;
for (int i = 0; i < h->numSeqn; i++) {
- delete [] h->seqn[i].wsaFile;
- delete [] h->seqn[i].wsaControl;
+ delete[] h->seqn[i].wsaFile;
+ delete[] h->seqn[i].wsaControl;
}
- delete [] h->seqn;
+ delete[] h->seqn;
delete h;
ptr = 0;
@@ -874,8 +874,8 @@ void StaticResource::freeHofSequenceData(void *&ptr, int &size) {
void StaticResource::freeHofShapeAnimDataV1(void *&ptr, int &size) {
ItemAnimData_v1 *d= (ItemAnimData_v1*) ptr;
for (int i = 0; i < size; i++)
- delete [] d[i].frames;
- delete [] d;
+ delete[] d[i].frames;
+ delete[] d;
ptr = 0;
size = 0;
}
@@ -883,8 +883,8 @@ void StaticResource::freeHofShapeAnimDataV1(void *&ptr, int &size) {
void StaticResource::freeHofShapeAnimDataV2(void *&ptr, int &size) {
ItemAnimData_v2 *d= (ItemAnimData_v2*) ptr;
for (int i = 0; i < size; i++)
- delete [] d[i].frames;
- delete [] d;
+ delete[] d[i].frames;
+ delete[] d;
ptr = 0;
size = 0;
}
@@ -892,7 +892,7 @@ void StaticResource::freeHofShapeAnimDataV2(void *&ptr, int &size) {
void StaticResource::freePaletteTable(void *&ptr, int &size) {
uint8 **data = (uint8**)ptr;
while (size--)
- delete [] data[size];
+ delete[] data[size];
ptr = 0;
size = 0;
}
@@ -1367,7 +1367,7 @@ void GUI_v1::initStaticResource() {
GUI_V1_BUTTON(_menuButtonData[4], 0x10, 1, 1, 1, 0x487, 0, 0, 0, 0, 0, 0);
GUI_V1_BUTTON(_menuButtonData[5], 0x11, 1, 1, 1, 0x487, 0, 0, 0, 0, 0, 0);
- delete [] _menu;
+ delete[] _menu;
_menu = new Menu[6];
assert(_menu);
@@ -1429,8 +1429,8 @@ void GUI_v1::initStaticResource() {
}
void KyraEngine_v1::setupButtonData() {
- delete [] _buttonData;
- delete [] _buttonDataListPtr;
+ delete[] _buttonData;
+ delete[] _buttonDataListPtr;
_buttonData = new Button[15];
assert(_buttonData);
@@ -1612,7 +1612,7 @@ const int8 KyraEngine_HoF::_dosTrackMap[] = {
const int KyraEngine_HoF::_dosTrackMapSize = ARRAYSIZE(KyraEngine_HoF::_dosTrackMap);
void KyraEngine_HoF::initInventoryButtonList() {
- delete [] _inventoryButtons;
+ delete[] _inventoryButtons;
_inventoryButtons = new Button[15];
assert(_inventoryButtons);
diff --git a/engines/kyra/text_hof.cpp b/engines/kyra/text_hof.cpp
index dd1796dd02..3a0dab730c 100644
--- a/engines/kyra/text_hof.cpp
+++ b/engines/kyra/text_hof.cpp
@@ -452,7 +452,7 @@ void KyraEngine_HoF::updateDlgBuffer() {
filename[11] = suffix[_lang];
if (_dlgBuffer)
- delete [] _dlgBuffer;
+ delete[] _dlgBuffer;
_dlgBuffer = _res->fileData(filename, 0);
}
diff --git a/engines/kyra/vqa.cpp b/engines/kyra/vqa.cpp
index db7cad941b..f4eadee4e2 100644
--- a/engines/kyra/vqa.cpp
+++ b/engines/kyra/vqa.cpp
@@ -69,7 +69,7 @@ void *VQAMovie::allocBuffer(int num, uint32 size) {
* We could use realloc() here, but we don't actually need the
* old contents of the buffer.
*/
- delete [] _buffers[num].data;
+ delete[] _buffers[num].data;
_buffers[num].data = new uint8[size];
_buffers[num].size = size;
}
@@ -81,7 +81,7 @@ void *VQAMovie::allocBuffer(int num, uint32 size) {
void VQAMovie::freeBuffers() {
for (int i = 0; i < ARRAYSIZE(_buffers); i++) {
- delete [] _buffers[i].data;
+ delete[] _buffers[i].data;
_buffers[i].data = NULL;
_buffers[i].size = 0;
}
@@ -356,11 +356,11 @@ bool VQAMovie::open(const char *filename) {
void VQAMovie::close() {
debugC(9, kDebugLevelMovie, "VQAMovie::close()");
if (_opened) {
- delete [] _frameInfo;
- delete [] _frame;
- delete [] _codeBook;
- delete [] _partialCodeBook;
- delete [] _vectorPointers;
+ delete[] _frameInfo;
+ delete[] _frame;
+ delete[] _codeBook;
+ delete[] _partialCodeBook;
+ delete[] _vectorPointers;
if (_vm->_mixer->isSoundHandleActive(_sound)) {
_vm->_mixer->stopHandle(_sound);
diff --git a/engines/kyra/wsamovie.cpp b/engines/kyra/wsamovie.cpp
index 764327d701..5190f24ad6 100644
--- a/engines/kyra/wsamovie.cpp
+++ b/engines/kyra/wsamovie.cpp
@@ -117,7 +117,7 @@ int WSAMovieV1::open(const char *filename, int offscreenDecode, uint8 *palBuf) {
if (firstFrame)
Screen::decodeFrame4(_frameData, _deltaBuffer, _deltaBufferSize);
- delete [] p;
+ delete[] p;
_opened = true;
return _numFrames;
@@ -126,10 +126,10 @@ int WSAMovieV1::open(const char *filename, int offscreenDecode, uint8 *palBuf) {
void WSAMovieV1::close() {
debugC(9, kDebugLevelMovie, "WSAMovieV1::close()");
if (_opened) {
- delete [] _deltaBuffer;
- delete [] _offscreenBuffer;
- delete [] _frameOffsTable;
- delete [] _frameData;
+ delete[] _deltaBuffer;
+ delete[] _offscreenBuffer;
+ delete[] _frameOffsTable;
+ delete[] _frameData;
_opened = false;
}
}
@@ -230,7 +230,7 @@ int WSAMovieAmiga::open(const char *filename, int offscreenDecode, uint8 *palBuf
void WSAMovieAmiga::close() {
debugC(9, kDebugLevelMovie, "WSAMovieAmiga::close()");
if (_opened) {
- delete [] _buffer;
+ delete[] _buffer;
_buffer = 0;
}
WSAMovieV1::close();
@@ -423,7 +423,7 @@ int WSAMovieV2::open(const char *filename, int unk1, uint8 *palBuf) {
if (firstFrame)
Screen::decodeFrame4(_frameData, _deltaBuffer, _deltaBufferSize);
- delete [] p;
+ delete[] p;
_opened = true;
return _numFrames;