diff options
author | Strangerke | 2013-03-05 07:56:53 +0100 |
---|---|---|
committer | Strangerke | 2013-03-05 07:56:53 +0100 |
commit | 6b2890dc6e2eccd367a69f5bdcd755e6a1b8c1ad (patch) | |
tree | 5fc39f90012c87f0d88d0525935d39bbe872aebe | |
parent | 1bcc9d09bc10a37e81785fee0071a06c741bc4c0 (diff) | |
download | scummvm-rg350-6b2890dc6e2eccd367a69f5bdcd755e6a1b8c1ad.tar.gz scummvm-rg350-6b2890dc6e2eccd367a69f5bdcd755e6a1b8c1ad.tar.bz2 scummvm-rg350-6b2890dc6e2eccd367a69f5bdcd755e6a1b8c1ad.zip |
HOPKINS: Some more renaming in FontManager
-rw-r--r-- | engines/hopkins/font.cpp | 18 | ||||
-rw-r--r-- | engines/hopkins/font.h | 5 |
2 files changed, 11 insertions, 12 deletions
diff --git a/engines/hopkins/font.cpp b/engines/hopkins/font.cpp index 743ae8ba70..d0f7325710 100644 --- a/engines/hopkins/font.cpp +++ b/engines/hopkins/font.cpp @@ -40,23 +40,23 @@ FontManager::FontManager() { FontManager::~FontManager() { _vm->_globals.freeMemory(_font); - _vm->_globals.freeMemory(BUF_ZONE); + _vm->_globals.freeMemory(_zoneText); } void FontManager::setParent(HopkinsEngine *vm) { _vm = vm; } -void FontManager::loadZoneTxt() { +void FontManager::loadZoneText() { switch (_vm->_globals._language) { case LANG_EN: - BUF_ZONE = _vm->_fileManager.loadFile("ZONEAN.TXT"); + _zoneText = _vm->_fileManager.loadFile("ZONEAN.TXT"); break; case LANG_FR: - BUF_ZONE = _vm->_fileManager.loadFile("ZONE01.TXT"); + _zoneText = _vm->_fileManager.loadFile("ZONE01.TXT"); break; case LANG_SP: - BUF_ZONE = _vm->_fileManager.loadFile("ZONEES.TXT"); + _zoneText = _vm->_fileManager.loadFile("ZONEES.TXT"); break; } } @@ -86,14 +86,14 @@ void FontManager::clearAll() { _index[idx] = 0; _tempText = g_PTRNUL; - BUF_ZONE = g_PTRNUL; + _zoneText = g_PTRNUL; } void FontManager::initData() { _font = _vm->_fileManager.loadFile("FONTE3.SPR"); _fontFixedWidth = 12; _fontFixedHeight = 21; - loadZoneTxt(); + loadZoneText(); } /** * Display Text @@ -225,8 +225,8 @@ void FontManager::box(int idx, int messageId, const Common::String &filename, in bufSize = 100; _tempText = _vm->_globals.allocMemory(110); Common::fill(&_tempText[0], &_tempText[110], 0); - memcpy(_tempText, BUF_ZONE + _index[messageId], 96); - WRITE_LE_UINT16((uint16 *)_tempText + 48, READ_LE_INT16(BUF_ZONE + _index[messageId] + 96)); + memcpy(_tempText, _zoneText + _index[messageId], 96); + WRITE_LE_UINT16((uint16 *)_tempText + 48, READ_LE_INT16(_zoneText + _index[messageId] + 96)); } byte *curTempTextPtr = _tempText; for (int i = 0; i < bufSize; i++) { diff --git a/engines/hopkins/font.h b/engines/hopkins/font.h index 6243a2e6d0..1a27efbd82 100644 --- a/engines/hopkins/font.h +++ b/engines/hopkins/font.h @@ -67,10 +67,9 @@ private: Common::String _indexName; int _index[4048]; byte *_tempText; + byte *_zoneText; - byte *BUF_ZONE; - - void loadZoneTxt(); + void loadZoneText(); public: byte *_font; int _fontFixedWidth; |