From f76e02e5d65ae235e4816ace30398c3b923a6b4a Mon Sep 17 00:00:00 2001 From: athrxx Date: Sun, 5 Oct 2014 15:15:31 +0200 Subject: KYRA: (EOB) - add support for Italian fan translation of EOB I --- engines/kyra/detection_tables.h | 16 ++++++++++++++++ engines/kyra/staticres.cpp | 2 +- engines/kyra/staticres_eob.cpp | 28 +++++++++++++++++++++------- engines/kyra/text_rpg.cpp | 4 ++-- 4 files changed, 40 insertions(+), 10 deletions(-) (limited to 'engines/kyra') diff --git a/engines/kyra/detection_tables.h b/engines/kyra/detection_tables.h index 1ada9a87ba..2ee0262ef2 100644 --- a/engines/kyra/detection_tables.h +++ b/engines/kyra/detection_tables.h @@ -1568,6 +1568,22 @@ const KYRAGameDescription adGameDescs[] = { EOB_FLAGS }, + { // Italian fan translation + { + "eob", + 0, + { + { "EOBDATA3.PAK", 0, "3ed915ab5b94d60dbfe1b55379889c51", -1 }, + { 0, 0, 0, 0 } + }, + Common::IT_ITA, + Common::kPlatformDOS, + ADGF_TESTING, + GUIO7(GUIO_NOSPEECH, GUIO_MIDIADLIB, GUIO_MIDIPCSPK, GUIO_RENDERVGA, GUIO_RENDEREGA, GUIO_RENDERCGA, GAMEOPTION_EOB_HPGRAPHS) + }, + EOB_FLAGS + }, + { { "eob2", diff --git a/engines/kyra/staticres.cpp b/engines/kyra/staticres.cpp index 9b3b92b9c7..731f2f4ce5 100644 --- a/engines/kyra/staticres.cpp +++ b/engines/kyra/staticres.cpp @@ -39,7 +39,7 @@ namespace Kyra { -#define RESFILE_VERSION 85 +#define RESFILE_VERSION 86 namespace { bool checkKyraDat(Common::SeekableReadStream *file) { diff --git a/engines/kyra/staticres_eob.cpp b/engines/kyra/staticres_eob.cpp index 54cc3066ec..aa7adc7461 100644 --- a/engines/kyra/staticres_eob.cpp +++ b/engines/kyra/staticres_eob.cpp @@ -464,20 +464,34 @@ void EoBCoreEngine::initStaticResource() { // EOB I doesn't have load and save menus, because there is only one single // save slot. Instead of emulating this we provide a menu similiar to EOB II. - static const char *const saveLoadStrings[3][4] = { - { "Cancel", "Empty Slot", "Save Game", "Load Game" }, - { "Abbr.", "Leerer Slot", "Speichern", " Laden" }, - { 0, 0, 0, 0 } + static const char *const saveLoadStrings[4][4] = { + { "Cancel", "Empty Slot", "Save Game", "Load Game" }, + { "Abbr.", "Leerer Slot", "Speichern", " Laden" }, + { " < < ", "Posizione Vuota", "Salva", "Carica" }, + { 0, 0, 0, 0 } }; - static const char *const errorSlotEmptyString[3] = { + static const char *const errorSlotEmptyString[4] = { "There is no game\rsaved in that slot!", "Hier ist noch kein\rSpiel gespeichert!", + "Non c'\x0E alcun gioco\rsalvato in quella\rposizione!", 0 }; - _saveLoadStrings = saveLoadStrings[(_flags.lang == Common::EN_ANY) ? 0 : ((_flags.lang == Common::DE_DEU) ? 1 : 2)]; - _errorSlotEmptyString = errorSlotEmptyString[(_flags.lang == Common::EN_ANY) ? 0 : ((_flags.lang == Common::DE_DEU) ? 1 : 2)]; + if (_flags.lang == Common::EN_ANY) { + _saveLoadStrings = saveLoadStrings[0]; + _errorSlotEmptyString = errorSlotEmptyString[0]; + } else if (_flags.lang == Common::DE_DEU) { + _saveLoadStrings = saveLoadStrings[1]; + _errorSlotEmptyString = errorSlotEmptyString[1]; + } else if (_flags.lang == Common::IT_ITA) { + _saveLoadStrings = saveLoadStrings[2]; + _errorSlotEmptyString = errorSlotEmptyString[2]; + } else { + _saveLoadStrings = saveLoadStrings[3]; + _errorSlotEmptyString = errorSlotEmptyString[3]; + } + _menuOkString = "OK"; } diff --git a/engines/kyra/text_rpg.cpp b/engines/kyra/text_rpg.cpp index 03acde8497..5cd99738ef 100644 --- a/engines/kyra/text_rpg.cpp +++ b/engines/kyra/text_rpg.cpp @@ -30,7 +30,7 @@ namespace Kyra { enum { - kEoBTextBufferSize = 2048 + kEoBTextBufferSize = 2560 }; TextDisplayer_rpg::TextDisplayer_rpg(KyraRpgEngine *engine, Screen *scr) : _vm(engine), _screen(scr), @@ -216,7 +216,7 @@ void TextDisplayer_rpg::displayText(char *str, ...) { break; default: - if (_vm->game() == GI_LOL || (unsigned char)c > 30) { + if (_vm->game() == GI_EOB1 || _vm->game() == GI_LOL || (unsigned char)c > 30) { _lineWidth += (sjisTextMode ? 4 : (_screen->_currentFont == Screen::FID_SJIS_FNT ? 9 : _screen->getCharWidth((uint8)c))); _currentLine[_numCharsLeft++] = c; _currentLine[_numCharsLeft] = 0; -- cgit v1.2.3