gothic-1-community-patch
gothic-1-community-patch copied to clipboard
World isn't displayed properly in savegame menu (RU)
Describe the bug The current world isn't displayed in the savegame menu, but at the left window side.
Expected behavior The current world is displayed correctly in the savegame menu (RU).
Additional context Bug and fix provided by N1kX94.
Reference:
https://github.com/AmProsius/gothic-1-community-patch/blob/e66b303623c042ec5cfc387a1b0d4bd352605f12/scriptbase/_work/Data/Scripts/System/Menu/Menu_Savegame.d#L134-L157
instance MENUITEM_LOADSAVE_LEVELNAME(C_MENU_ITEM_DEF)
{
type = MENU_ITEM_TEXT;
text[0] = "Мир:";
posx = -4000;
posy = 3960;
fontName = MENU_FONT_SMALL;
flags = flags & ~IT_SELECTABLE;
};
instance MENUITEM_LOADSAVE_LEVELNAME_VALUE(C_MENU_ITEM_DEF)
{
type = MENU_ITEM_TEXT;
text[0] = "";
posx = -4000;
posy = 3960 + 320;
dimx = 8192 - posx;
dimy = 350;
fontName = MENU_FONT_SMALL;
flags = flags & ~IT_SELECTABLE;
};
changed to
instance MENUITEM_LOADSAVE_LEVELNAME(C_MENU_ITEM_DEF)
{
type = MENU_ITEM_TEXT;
text[0] = "Мир:";
posx = SAVEGAME_X2;
posy = 3960;
fontName = MENU_FONT_SMALL;
flags = flags & ~IT_SELECTABLE;
};
instance MENUITEM_LOADSAVE_LEVELNAME_VALUE(C_MENU_ITEM_DEF)
{
type = MENU_ITEM_TEXT;
text[0] = "";
posx = SAVEGAME_X2;
posy = 3960 + 320;
dimx = 8192 - posx;
dimy = 350;
fontName = MENU_FONT_SMALL;
flags = flags & ~IT_SELECTABLE;
};
Thanks for already providing a fix and screenshot. That gives a clear picture of what's the problem.
Technically this is just another instance variable (int) assignment replacement. However, these instances are inside the menu scripts. We will therefore have to operate, not on the content-parser (as usual), but on the menu-parser. The procedure is no different, but the functions we use all work on the content-parser, and we will need equivalents. I had done similar things in the past, I will try to write convenient functions for this.