diff options
Diffstat (limited to 'engines/kyra')
-rw-r--r-- | engines/kyra/animator_tim.cpp | 4 | ||||
-rw-r--r-- | engines/kyra/gui_lok.cpp | 4 | ||||
-rw-r--r-- | engines/kyra/gui_lol.cpp | 16 | ||||
-rw-r--r-- | engines/kyra/gui_v2.cpp | 2 | ||||
-rw-r--r-- | engines/kyra/kyra_lok.cpp | 2 | ||||
-rw-r--r-- | engines/kyra/kyra_v1.cpp | 2 | ||||
-rw-r--r-- | engines/kyra/kyra_v1.h | 2 | ||||
-rw-r--r-- | engines/kyra/lol.cpp | 22 | ||||
-rw-r--r-- | engines/kyra/resource_intern.cpp | 14 | ||||
-rw-r--r-- | engines/kyra/scene_lol.cpp | 4 | ||||
-rw-r--r-- | engines/kyra/screen.cpp | 4 | ||||
-rw-r--r-- | engines/kyra/screen_lol.cpp | 8 | ||||
-rw-r--r-- | engines/kyra/script_lol.cpp | 8 | ||||
-rw-r--r-- | engines/kyra/seqplayer.cpp | 2 | ||||
-rw-r--r-- | engines/kyra/sequences_hof.cpp | 2 | ||||
-rw-r--r-- | engines/kyra/sequences_lol.cpp | 4 | ||||
-rw-r--r-- | engines/kyra/sound.h | 2 | ||||
-rw-r--r-- | engines/kyra/sound_towns.cpp | 2 | ||||
-rw-r--r-- | engines/kyra/sprites_lol.cpp | 2 | ||||
-rw-r--r-- | engines/kyra/text_lol.cpp | 26 |
20 files changed, 66 insertions, 66 deletions
diff --git a/engines/kyra/animator_tim.cpp b/engines/kyra/animator_tim.cpp index 3fbda7c45d..ef1c760d71 100644 --- a/engines/kyra/animator_tim.cpp +++ b/engines/kyra/animator_tim.cpp @@ -67,7 +67,7 @@ TimAnimator::~TimAnimator() { void TimAnimator::init(int animIndex, Movie *wsa, int x, int y, int wsaCopyParams, int frameDelay) { Animation *anim = &_animations[animIndex]; anim->wsa = wsa; - anim->x = x; + anim->x = x; anim->y = y; anim->wsaCopyParams = wsaCopyParams; anim->frameDelay = frameDelay; @@ -123,7 +123,7 @@ void TimAnimator::setupPart(int animIndex, int part, int firstFrame, int lastFra void TimAnimator::start(int animIndex, int part) { if (!_vm || !_system || !_screen) - return; + return; Animation *anim = &_animations[animIndex]; anim->curPart = part; diff --git a/engines/kyra/gui_lok.cpp b/engines/kyra/gui_lok.cpp index afc2c0bc47..1a822b01a5 100644 --- a/engines/kyra/gui_lok.cpp +++ b/engines/kyra/gui_lok.cpp @@ -688,7 +688,7 @@ int GUI_LoK::loadGameMenu(Button *button) { void GUI_LoK::redrawTextfield() { _screen->fillRect(38, 91, 287, 102, _vm->gameFlags().platform == Common::kPlatformAmiga ? 18 : 250); _text->printText(_savegameName, 38, 92, 253, 0, 0); - + _screen->_charWidth = -2; int width = _screen->getTextWidth(_savegameName); _screen->fillRect(39 + width, 93, 45 + width, 100, _vm->gameFlags().platform == Common::kPlatformAmiga ? 31 : 254); @@ -742,7 +742,7 @@ int GUI_LoK::saveGame(Button *button) { _cancelSubMenu = false; Screen::FontId cf = _screen->setFont(Screen::FID_8_FNT); - + if (_savegameOffset == 0 && _vm->_gameToLoad == 0) { _savegameName[0] = 0; } else { diff --git a/engines/kyra/gui_lol.cpp b/engines/kyra/gui_lol.cpp index a96c40d1f8..ac6e1aaf27 100644 --- a/engines/kyra/gui_lol.cpp +++ b/engines/kyra/gui_lol.cpp @@ -212,7 +212,7 @@ void LoLEngine::gui_displayCharInventory(int charNum) { if (c && !b) b = 1; } - + if (_flags.use16ColorMode) gui_drawBarGraph(154, 66 + i * 8, 34, 5, b, e, 0x88, 0); else @@ -251,7 +251,7 @@ void LoLEngine::gui_printCharacterStats(int index, int redraw, int value) { col = 158; if (redraw) _screen->fprintString("%s", offs + 108, y, col, 0, 4, getLangString(0x4014 + index)); - } + } } else { //skills int s = index - 2; @@ -650,7 +650,7 @@ int LoLEngine::gui_enableControls() { int start = 74; int end = 83; - + if (_flags.isTalkie) { start = 76; end = 85; @@ -676,7 +676,7 @@ int LoLEngine::gui_disableControls(int controlMode) { int start = 74; int end = 83; int swtch = 76; - + if (_flags.isTalkie) { start = 76; end = 85; @@ -846,7 +846,7 @@ void LoLEngine::gui_triggerEvent(int eventType) { for (Common::HashMap<int, int16>::const_iterator c = _keyMap.begin(); c != _keyMap.end(); ++c) { if (c->_value == eventType) evt.kbd.keycode = (Common::KeyCode) c->_key; - } + } } removeInputTop(); @@ -2621,9 +2621,9 @@ void GUI_LoL::updateSavegameList() { KyraEngine_v1::SaveHeader header; Common::InSaveFile *in; - + _savegameList = new char*[_savegameListSize]; - + for (int i = 0; i < _savegameListSize; i++) { in = _vm->openSaveForReading(_vm->getSavegameFilename(i), header); if (in) { @@ -2790,7 +2790,7 @@ int GUI_LoL::clickedOptionsMenu(Button *button) { case 0xfff9: _vm->_configMusic ^= 1; _vm->sound()->enableMusic(_vm->_configMusic); - + if (_vm->_configMusic) _vm->snd_playTrack(_vm->_curMusicTheme); else diff --git a/engines/kyra/gui_v2.cpp b/engines/kyra/gui_v2.cpp index cf9ccfc0d3..e1016665a2 100644 --- a/engines/kyra/gui_v2.cpp +++ b/engines/kyra/gui_v2.cpp @@ -748,7 +748,7 @@ const char *GUI_v2::nameInputProcess(char *buffer, int x, int y, uint8 c1, uint8 int x2 = x, y2 = y; Screen::FontId of = _screen->setFont(Screen::FID_8_FNT); _text->printText(buffer, x, y, c1, c2, c2); - + for (int i = 0; i < curPos; ++i) x2 += getCharWidth(buffer[i]); diff --git a/engines/kyra/kyra_lok.cpp b/engines/kyra/kyra_lok.cpp index 68e0eb66d5..7cfa7bd29e 100644 --- a/engines/kyra/kyra_lok.cpp +++ b/engines/kyra/kyra_lok.cpp @@ -339,7 +339,7 @@ Common::Error KyraEngine_LoK::go() { void KyraEngine_LoK::startup() { static const uint8 colorMap[] = { 0, 0, 0, 0, 12, 12, 12, 0, 0, 0, 0, 0 }; _screen->setTextColorMap(colorMap); - + _sound->setSoundList(&_soundData[kMusicIngame]); if (_flags.platform == Common::kPlatformPC98) _sound->loadSoundFile("SE.DAT"); diff --git a/engines/kyra/kyra_v1.cpp b/engines/kyra/kyra_v1.cpp index ffb9050aba..451750ce14 100644 --- a/engines/kyra/kyra_v1.cpp +++ b/engines/kyra/kyra_v1.cpp @@ -363,7 +363,7 @@ void KyraEngine_v1::setupKeyMap() { static const int16 keyCodesDOS[] = { 61, 43, 96, 96, 102, 102, 98, 98, 97, 92, 92, 91, 91, 101, 101, 112, 113, 114, 25, 20, 55, 110}; static const int16 keyCodesPC98[] = { 53, 29, 68, 68, 73, 73, 76, 76, 72, 71, 71, 67, 67, 69, 69, 99, 100, 101, 25, 20, 55, 1 }; - + const int16 *keyCodes = _flags.platform == Common::kPlatformPC98 ? keyCodesPC98 : keyCodesDOS; _keyMap.clear(); diff --git a/engines/kyra/kyra_v1.h b/engines/kyra/kyra_v1.h index e73a8b77b7..1ad13cd092 100644 --- a/engines/kyra/kyra_v1.h +++ b/engines/kyra/kyra_v1.h @@ -68,7 +68,7 @@ class KyraMetaEngine; * Kyrandia 1 Russian (no feature request) * Kyrandia 2 Russian (no feature request) * Kyrandia 3 Russian (feature request #2812792 "Kyrandia3 Russian") - * + * * The primary maintainer for the engine is LordHoto, although some parts are maintained by _athrxx. * If you have questions about parts of the code, the following rough description might help in * determining who you should ask: diff --git a/engines/kyra/lol.cpp b/engines/kyra/lol.cpp index 41d017223b..be5a755200 100644 --- a/engines/kyra/lol.cpp +++ b/engines/kyra/lol.cpp @@ -1589,7 +1589,7 @@ void LoLEngine::initDialogueSequence(int controlMode, int pageNum) { } else { _screen->fillRect(0, 128, 319, 199, 1); gui_drawBox(0, 129, 320, 71, 136, 251, -1); - gui_drawBox(1, 130, 318, 69, 136, 251, 252); + gui_drawBox(1, 130, 318, 69, 136, 251, 252); } _screen->modifyScreenDim(5, 8, 131, 306, 66); @@ -1721,7 +1721,7 @@ void LoLEngine::generateBrightnessPalette(const Palette &src, Palette &dst, int modifier = 0; else if (modifier < 0 || modifier > 7 || !(_flagsTable[31] & 0x08)) modifier = 8; - + modifier >>= 1; if (modifier) modifier--; @@ -1780,7 +1780,7 @@ void LoLEngine::createTransparencyTables() { _res->loadFileToBuf("LOL.NOL", tpal, 48); for (int i = 15; i > -1; i--) { - int s = colTbl[i << 1] * 3; + int s = colTbl[i << 1] * 3; tpal[s] = tpal[i * 3]; tpal[s + 1] = tpal[i * 3 + 1]; tpal[s + 2] = tpal[i * 3 + 2]; @@ -2173,7 +2173,7 @@ int LoLEngine::processMagicHeal(int charNum, int spellLevel) { SWAP(dst[s + 2], dst[i + 2]); } } - + _screen->generateGrayOverlay(tpal, _healOverlay, 52, 22, 20, 0, 256, true); } @@ -2311,7 +2311,7 @@ int LoLEngine::processMagicIce(int charNum, int spellLevel) { _screen->loadPalette("LOLICE.NOL", swampCol); for (int i = 1; i < 16; i++) { uint16 v = (s[i * 3] + s[i * 3 + 1] + s[i * 3 + 2]) / 3; - tpal[i * 3] = 0; + tpal[i * 3] = 0; tpal[i * 3 + 1] = v; tpal[i * 3 + 2] = v << 1; @@ -2319,11 +2319,11 @@ int LoLEngine::processMagicIce(int charNum, int spellLevel) { tpal[i * 3 + 2] = 29; } - } else { + } else { _screen->loadPalette("SWAMPICE.COL", swampCol); tpal.copy(s, 128); swampCol.copy(s, 128); - + for (int i = 1; i < 128; i++) { tpal[i * 3] = 0; uint16 v = (s[i * 3] + s[i * 3 + 1] + s[i * 3 + 2]) / 3; @@ -2544,7 +2544,7 @@ int LoLEngine::processMagicFireball(int charNum, int spellLevel) { } else { if (_flags.use16ColorMode) _screen->drawShape(_screen->_curPage, shp, fX, fY, 0, 4, sW, sH); - else + else _screen->drawShape(_screen->_curPage, shp, fX, fY, 0, 0x1004, _transparencyTable1, _transparencyTable2, sW, sH); } @@ -2883,7 +2883,7 @@ int LoLEngine::processMagicVaelansCube() { tmpPal2[i * 3 + 2] = (a > 60) ? 60 : a; } } - + snd_playSoundEffect(146, -1); uint32 ctime = _system->getMillis(); @@ -4013,10 +4013,10 @@ void LoLEngine::displayAutomap() { static const uint8 ovlSrc[] = { 0x00, 0xEE, 0xCC, 0x33, 0x44, 0x55, 0x66, 0x77, 0x88, 0x99, 0xAA, 0x22, 0x11, 0xDD, 0xEE, 0xCC }; memset(_mapOverlay, 0, 256); for (int i = 0; i < 16; i++) - _mapOverlay[(i << 4) | i] = ovlSrc[i]; + _mapOverlay[(i << 4) | i] = ovlSrc[i]; } else _screen->generateGrayOverlay(_screen->getPalette(3), _mapOverlay, 52, 0, 0, 0, 256, false); - + _screen->loadFont(Screen::FID_9_FNT, "FONT9PN.FNT"); _screen->loadFont(Screen::FID_6_FNT, "FONT6PN.FNT"); diff --git a/engines/kyra/resource_intern.cpp b/engines/kyra/resource_intern.cpp index dc1bcf90b7..49c2c85a32 100644 --- a/engines/kyra/resource_intern.cpp +++ b/engines/kyra/resource_intern.cpp @@ -877,7 +877,7 @@ public: ~CmpVocDecoder(); uint8 *process(uint8 *src, uint32 insize, uint32 *outsize, bool disposeInput = true); -private: +private: void decodeHelper(int p); int32 *_vtbl; @@ -1028,7 +1028,7 @@ Common::Archive *InstallerLoader::load(Resource *owner, const Common::String &fi newEntry.size = outsize; newEntry.name = entryStr; } - + fileList.push_back(newEntry); } pos++; @@ -1187,7 +1187,7 @@ CmpVocDecoder::~CmpVocDecoder() { uint8 *CmpVocDecoder::process(uint8 *src, uint32 insize, uint32 *outsize, bool disposeInput) { *outsize = 0; uint8 *outTemp = new uint8[insize]; - + uint8 *inPosH = src; uint8 *outPosH = outTemp; uint8 *outPosD = outTemp + READ_LE_UINT32(src); @@ -1221,7 +1221,7 @@ uint8 *CmpVocDecoder::process(uint8 *src, uint32 insize, uint32 *outsize, bool d uint8 *vocPtr = src + offset; uint32 vocLen = (vocPtr[27] | (vocPtr[28] << 8) | (vocPtr[29] << 16)) - 2; - + uint8 *vocOutEnd = outPosD + vocLen + 32; uint8 *vocInEnd = src + offset + fileSize; memcpy(outPosD, vocPtr, 32); @@ -1235,7 +1235,7 @@ uint8 *CmpVocDecoder::process(uint8 *src, uint32 insize, uint32 *outsize, bool d uint32 readSize = MIN<uint32>(8192, vocInEnd - vocPtr); memcpy(_sndArray, vocPtr, readSize); vocPtr += readSize; - + for (int i = -128; i < 128; i++) _stTbl[i + 128] = (int32)((float)i / t + 0.5f); @@ -1255,7 +1255,7 @@ uint8 *CmpVocDecoder::process(uint8 *src, uint32 insize, uint32 *outsize, bool d memcpy(dst, _sndArray, numBytesOut); dst += numBytesOut; } - + *dst++ = 0; memcpy(outPosH, spos, headerEntryLen); WRITE_LE_UINT32(outPosH, outPosD - outTemp); @@ -1287,7 +1287,7 @@ void CmpVocDecoder::decodeHelper(int p1) { int d = 3; int s = 1; - + while (s < p2) { fi2 = _floatArray[s]; fi1 = _floatArray[s + 1]; diff --git a/engines/kyra/scene_lol.cpp b/engines/kyra/scene_lol.cpp index 3d4910fd68..60d4749774 100644 --- a/engines/kyra/scene_lol.cpp +++ b/engines/kyra/scene_lol.cpp @@ -99,7 +99,7 @@ void LoLEngine::loadLevel(int index) { setMouseCursorToItemInHand(); if (_flags.use16ColorMode) - _screen->fadeToPalette1(10); + _screen->fadeToPalette1(10); snd_playTrack(_curMusicTheme); } @@ -415,7 +415,7 @@ void LoLEngine::loadLevelGraphics(const char *file, int specialColor, int weight } v += 384; - } + } if (_currentLevel == 11) { if (_flags.use16ColorMode) { diff --git a/engines/kyra/screen.cpp b/engines/kyra/screen.cpp index 708a7f41f3..cec6f1970a 100644 --- a/engines/kyra/screen.cpp +++ b/engines/kyra/screen.cpp @@ -2146,7 +2146,7 @@ void Screen::decodeFrameDeltaPage(uint8 *dst, const uint8 *src, int pitch, bool } void Screen::convertAmigaGfx(uint8 *data, int w, int h, int depth, bool wsa, int bytesPerPlane) { - const int planeWidth = (bytesPerPlane == -1) ? (w + 7) / 8 : bytesPerPlane; + const int planeWidth = (bytesPerPlane == -1) ? (w + 7) / 8 : bytesPerPlane; const int planeSize = planeWidth * h; const uint imageSize = planeSize * depth; @@ -3365,7 +3365,7 @@ void SJISFont::drawChar(uint16 c, byte *dst, int pitch) const { if (_is16Color) { // PC98 16 color games specify a color value which is for the // PC98 text mode palette, thus we need to remap it. - color1 = ((_colorMap[1] >> 5) & 0x7) + 16; + color1 = ((_colorMap[1] >> 5) & 0x7) + 16; color2 = ((_colorMap[0] >> 5) & 0x7) + 16; } else { color1 = _colorMap[1]; diff --git a/engines/kyra/screen_lol.cpp b/engines/kyra/screen_lol.cpp index f15c8dd612..6b94043005 100644 --- a/engines/kyra/screen_lol.cpp +++ b/engines/kyra/screen_lol.cpp @@ -191,7 +191,7 @@ uint8 *Screen_LoL::generateLevelOverlay(const Palette &srcPal, uint8 *ovl, int o weight = 255; const uint8 *srt = srcPal.getData(); - + uint16 r = srt[opColor * 3]; uint16 g = srt[opColor * 3 + 1]; uint16 b = srt[opColor * 3 + 2]; @@ -848,7 +848,7 @@ void Screen_LoL::fadeToPalette1(int delay) { void Screen_LoL::loadSpecialColors(Palette &dst) { if (_use16ColorMode) return; - + dst.copy(*_screenPalette, 192, 4); } @@ -941,9 +941,9 @@ bool Screen_LoL::fadePaletteStep(uint8 *pal1, uint8 *pal2, uint32 elapsedTime, u Palette **Screen_LoL::generateFadeTable(Palette **dst, Palette *src1, Palette *src2, int numTabs) { int len = _use16ColorMode ? 48 : 768; - if (!src1) + if (!src1) src1 = _screenPalette; - + uint8 *p1 = (*dst++)->getData(); uint8 *p2 = src1->getData(); uint8 *p3 = src2->getData(); diff --git a/engines/kyra/script_lol.cpp b/engines/kyra/script_lol.cpp index cf4f9ecdaf..810b36f94b 100644 --- a/engines/kyra/script_lol.cpp +++ b/engines/kyra/script_lol.cpp @@ -2151,7 +2151,7 @@ int LoLEngine::olol_paletteFlash(EMCState *script) { uint8 *d = p2.getData(); for (int i = 0; i < 16; i++) - d[i * 3] = 0x3f; + d[i * 3] = 0x3f; _screen->setScreenPalette(p2); _screen->updateScreen(); @@ -2164,7 +2164,7 @@ int LoLEngine::olol_paletteFlash(EMCState *script) { _screen->updateScreen(); - } else { + } else { Palette &p2 = _screen->getPalette(3); uint8 ovl[256]; @@ -2653,8 +2653,8 @@ int LoLEngine::tlol_fadeInPalette(const TIM *tim, const uint16 *param) { _screen->setScreenPalette(_screen->getPalette(0)); _screen->copyPage(2, 0); } - - _screen->fadePalette(pal, param[1]); + + _screen->fadePalette(pal, param[1]); return 1; } diff --git a/engines/kyra/seqplayer.cpp b/engines/kyra/seqplayer.cpp index d6409e49c1..511a7da21d 100644 --- a/engines/kyra/seqplayer.cpp +++ b/engines/kyra/seqplayer.cpp @@ -657,7 +657,7 @@ bool SeqPlayer::playSequence(const uint8 *seqData, bool skipSeq) { } delete[] _specialBuffer; _specialBuffer = 0; - + for (uint i = 0; i < ARRAYSIZE(_seqMovies); ++i) { delete _seqMovies[i].movie; _seqMovies[i].movie = 0; diff --git a/engines/kyra/sequences_hof.cpp b/engines/kyra/sequences_hof.cpp index 8d7cda79c1..bdba04bf9e 100644 --- a/engines/kyra/sequences_hof.cpp +++ b/engines/kyra/sequences_hof.cpp @@ -2796,7 +2796,7 @@ void KyraEngine_HoF::seq_init() { { 0xd8, 0xda, 0xd9, 0xd8 }, (_flags.lang == Common::JA_JPN) ? Screen::FID_SJIS_FNT : Screen::FID_8_FNT, 240 }; - + _menu = new MainMenu(this); _menu->init(data, MainMenu::Animation()); } diff --git a/engines/kyra/sequences_lol.cpp b/engines/kyra/sequences_lol.cpp index 236a559816..dc1a0f4d15 100644 --- a/engines/kyra/sequences_lol.cpp +++ b/engines/kyra/sequences_lol.cpp @@ -1160,7 +1160,7 @@ void LoLEngine::showCredits() { _outroShapeTable[i] = (i << 4) | i; else _outroShapeTable[255] = 0; - + _sound->haltTrack(); _sound->loadSoundFile("LOREFINL"); _sound->playTrack(4); @@ -1474,7 +1474,7 @@ void LoLEngine::processCredits(char *t, int dimState, int page, int delayTime) { curShapeFile = curShapeFile % 28; loadOutroShapes(curShapeFile, shapes); - + if (!_flags.use16ColorMode) { _screen->getPalette(0).copy(monsterPal, curShapeFile * 40, 40, 88); _screen->setScreenPalette(_screen->getPalette(0)); diff --git a/engines/kyra/sound.h b/engines/kyra/sound.h index 9cba030a13..3b0fbbed0a 100644 --- a/engines/kyra/sound.h +++ b/engines/kyra/sound.h @@ -266,7 +266,7 @@ public: bool hasSoundFile(uint file) const { return _music->hasSoundFile(file) && _sfx->hasSoundFile(file); } void loadSoundFile(uint file) { _music->loadSoundFile(file); _sfx->loadSoundFile(file); } void loadSoundFile(Common::String file) { _music->loadSoundFile(file); _sfx->loadSoundFile(file); } - + void loadSfxFile(Common::String file) { _sfx->loadSoundFile(file); } void playTrack(uint8 track) { _music->playTrack(track); } diff --git a/engines/kyra/sound_towns.cpp b/engines/kyra/sound_towns.cpp index ce7658ee63..7b4a15dc4a 100644 --- a/engines/kyra/sound_towns.cpp +++ b/engines/kyra/sound_towns.cpp @@ -3562,7 +3562,7 @@ void TownsPC98_OpnDriver::loadSoundEffectData(uint8 *data, uint8 trackNum) { void TownsPC98_OpnDriver::reset() { Common::StackLock lock(_mutex); - + _musicPlaying = false; _sfxPlaying = false; _fading = false; diff --git a/engines/kyra/sprites_lol.cpp b/engines/kyra/sprites_lol.cpp index a943853867..ce14489e3e 100644 --- a/engines/kyra/sprites_lol.cpp +++ b/engines/kyra/sprites_lol.cpp @@ -1026,7 +1026,7 @@ uint8 *LoLEngine::drawItemOrMonster(uint8 *shape, uint8 *monsterPalette, int x, if (_flags.use16ColorMode) { if (_currentLevel != 22) flg &= 0xdfff; - + } else { if (_currentLevel == 22) { if (brightnessOverlay) diff --git a/engines/kyra/text_lol.cpp b/engines/kyra/text_lol.cpp index 8f6b04afb9..d5264be483 100644 --- a/engines/kyra/text_lol.cpp +++ b/engines/kyra/text_lol.cpp @@ -128,8 +128,8 @@ void TextDisplayer_LoL::expandField() { h = 4; stepH = 1; } - - _screen->copyRegion(83, y, 0, 0, 235, h, 0, 2, Screen::CR_NO_P_CHECK); + + _screen->copyRegion(83, y, 0, 0, 235, h, 0, 2, Screen::CR_NO_P_CHECK); for (int i = 140; i < 177; i++) { uint32 endTime = _vm->_system->getMillis() + _vm->_tickLength; @@ -360,7 +360,7 @@ void TextDisplayer_LoL::preprocessString(char *str, EMCState *script, const uint void TextDisplayer_LoL::displayText(char *str, ...) { const bool isPc98 = (_vm->gameFlags().platform == Common::kPlatformPC98); - + _printFlag = false; _lineWidth = 0; @@ -382,7 +382,7 @@ void TextDisplayer_LoL::displayText(char *str, ...) { const ScreenDim *sd = _screen->_curDim; int sdx = _screen->curDimIndex(); - bool pc98PrintFlag = (isPc98 && (sdx == 3 || sdx == 4 || sdx == 5 || sdx == 15)) ? true : false; + bool pc98PrintFlag = (isPc98 && (sdx == 3 || sdx == 4 || sdx == 5 || sdx == 15)) ? true : false; uint16 charsPerLine = (sd->w << 3) / (_screen->getFontWidth() + _screen->_charWidth); while (c) { @@ -587,7 +587,7 @@ void TextDisplayer_LoL::printLine(char *str) { w -= _textDimData[sdx].column; int n2 = 0; - int n1 = (w / 4) - 1; + int n1 = (w / 4) - 1; do { c = str[n2]; @@ -612,7 +612,7 @@ void TextDisplayer_LoL::printLine(char *str) { while (n1 > 0) { //cut off line after last space c = str[n1]; - + lw -= _screen->getCharWidth((uint8)c); if (!n2 && lw <= w) @@ -623,7 +623,7 @@ void TextDisplayer_LoL::printLine(char *str) { _printFlag = false; break; } - n1--; + n1--; } if (!n1) { @@ -641,7 +641,7 @@ void TextDisplayer_LoL::printLine(char *str) { str[s] = 0; uint8 col = _textDimData[sdx].color1; - if (isPc98 && (sdx == 2 || sdx == 3 || sdx == 4 || sdx == 5 || sdx == 15)) { + if (isPc98 && (sdx == 2 || sdx == 3 || sdx == 4 || sdx == 5 || sdx == 15)) { switch (_textDimData[sdx].color1) { case 0x88: col = 0x41; @@ -739,12 +739,12 @@ void TextDisplayer_LoL::textPageBreak() { char *txt = _vm->getLangString(0x4073); if (_vm->gameFlags().use16ColorMode) { - _vm->gui_drawBox(x + 8, (y & ~7) - 1, 66, 10, 0xee, 0xcc, -1); + _vm->gui_drawBox(x + 8, (y & ~7) - 1, 66, 10, 0xee, 0xcc, -1); _vm->_screen->printText(txt, (x + 37 - (strlen(txt) << 1) + 4) & ~3, (y + 2) & ~7, 0xc1, 0); } else { - _vm->gui_drawBox(x, y, 74, 9, 136, 251, -1); + _vm->gui_drawBox(x, y, 74, 9, 136, 251, -1); _vm->_screen->printText(txt, x + 37 - (_vm->_screen->getTextWidth(txt) >> 1), y + 2, 144, 0); - } + } _vm->removeInputTop(); @@ -784,7 +784,7 @@ void TextDisplayer_LoL::textPageBreak() { } while (loop); - if (_vm->gameFlags().use16ColorMode) + if (_vm->gameFlags().use16ColorMode) _screen->fillRect(x + 8, y, x + 57, y + 9, _textDimData[_screen->curDimIndex()].color2); else _screen->fillRect(x, y, x + 73, y + 8, _textDimData[_screen->curDimIndex()].color2); @@ -815,7 +815,7 @@ void TextDisplayer_LoL::clearCurDim() { _screen->fillRect(tmp->sx << 3, tmp->sy, ((tmp->sx + tmp->w) << 3) - 2, (tmp->sy + tmp->h) - 2, _textDimData[d].color2); } else _screen->fillRect(tmp->sx << 3, tmp->sy, ((tmp->sx + tmp->w) << 3) - 1, (tmp->sy + tmp->h) - 1, _textDimData[d].color2); - + _lineCount = 0; _textDimData[d].column = _textDimData[d].line = 0; } |