SWORD1: PSX: Improve accuracy of "Paused" message

This commit is contained in:
AndywinXp 2023-10-17 00:26:46 +02:00
parent bde3a46cf4
commit 3bde6ebf00
4 changed files with 28 additions and 3 deletions

View File

@ -3112,6 +3112,21 @@ bool Control::loadCustomStrings(const char *filename) {
}
const uint8 *Control::getPauseString() {
if (SwordEngine::isPsx()) {
switch (SwordEngine::_systemVars.language) {
case BS1_ENGLISH:
return _psxPauseStrings[0];
case BS1_GERMAN:
case BS1_FRENCH:
return _psxPauseStrings[1];
case BS1_ITALIAN:
case BS1_SPANISH:
return _psxPauseStrings[2];
default:
return _psxPauseStrings[0];
}
}
return _lStrings[STR_PAUSED];
}

View File

@ -216,6 +216,7 @@ private:
static const uint8 _mediaHouseLanguageStrings[20][43];
uint8 _customStrings[20][43];
const uint8(*_lStrings)[43];
const uint8 _psxPauseStrings[3][7] = { "Paused", "Pause", "Pausa" };
SwordEngine *_vm;
Common::SaveFileManager *_saveFileMan;
ObjectMan *_objMan;

View File

@ -753,6 +753,11 @@ void SwordEngine::showDebugInfo() {
int32 pausedX = Logic::_scriptVars[SCROLL_OFFSET_X] + 400;
int32 pausedY = Logic::_scriptVars[SCROLL_OFFSET_Y] + 315;
if (SwordEngine::isPsx()) {
pausedX += 20;
pausedY -= 16;
}
uint8 buf[255];
if (_systemVars.gamePaused) {

View File

@ -294,9 +294,13 @@ void Text::printDebugLine(uint8 *ascii, uint8 first, int x, int y) {
x += _resMan->getUint16(head->width);
// The very first executable version didn't use any overlap (verified on UK disasm)
if (SwordEngine::_systemVars.realLanguage != Common::EN_ANY)
x -= DEBUG_OVERLAP;
if (SwordEngine::isPsx()) {
x -= OVERLAP;
} else {
// The very first executable version didn't use any overlap (verified on UK disasm)
if (SwordEngine::_systemVars.realLanguage != Common::EN_ANY)
x -= DEBUG_OVERLAP;
}
ascii++;
} while (*ascii);