Change saved <summary> tag back to English

This ensures loading a 2.4 save in the English-only 2.3 or earlier
doesn't result in missing characters because a translated area name
appears in the save file. We are not reading from <summary> anymore
in 2.4.

The way this is done is by not translating the area names inside
mapclass::currentarea(), but at the callsites other than the one which
saves the <summary>.
This commit is contained in:
Dav999
2023-09-13 18:47:20 +02:00
committed by Misa Elizabeth Kai
parent ac7fe4475c
commit 187fd85e14
2 changed files with 20 additions and 17 deletions

View File

@@ -1242,51 +1242,54 @@ void mapclass::spawncompanion(void)
const char* mapclass::currentarea(const int roomx, const int roomy)
{
/* For translation, the returned value is passed to loc::gettext_roomname_special().
* Returned strings must therefore be found in roomnames_special.xml! */
if (roomx >= 102 && roomx <= 104 && roomy >= 110 && roomy <= 111)
{
return loc::gettext_roomname_special("The Ship");
return "The Ship";
}
switch (area(roomx, roomy))
{
case 0:
return loc::gettext_roomname_special("Dimension VVVVVV");
return "Dimension VVVVVV";
break;
case 1:
return loc::gettext_roomname_special("Dimension VVVVVV");
return "Dimension VVVVVV";
break;
case 2:
return loc::gettext_roomname_special("Laboratory");
return "Laboratory";
break;
case 3:
return loc::gettext_roomname_special("The Tower");
return "The Tower";
break;
case 4:
return loc::gettext_roomname_special("Warp Zone");
return "Warp Zone";
break;
case 5:
return loc::gettext_roomname_special("Space Station");
return "Space Station";
break;
case 6:
return loc::gettext_roomname_special("Outside Dimension VVVVVV");
return "Outside Dimension VVVVVV";
break;
case 7:
return loc::gettext_roomname_special("Outside Dimension VVVVVV");
return "Outside Dimension VVVVVV";
break;
case 8:
return loc::gettext_roomname_special("Outside Dimension VVVVVV");
return "Outside Dimension VVVVVV";
break;
case 9:
return loc::gettext_roomname_special("Outside Dimension VVVVVV");
return "Outside Dimension VVVVVV";
break;
case 10:
return loc::gettext_roomname_special("Outside Dimension VVVVVV");
return "Outside Dimension VVVVVV";
break;
case 11:
return loc::gettext_roomname_special("The Tower");
return "The Tower";
break;
}
return loc::gettext_roomname_special("???");
return "???";
}
static void copy_short_to_int(int* dest, const short* src, const size_t size)