Move the credits button on main menu
Patch By: Nescio
Comments By: Stan
Differential Revision: https://code.wildfiregames.com/D2430
Move the credits button on main menu
Description
Details
Event TimelineComment Actions Thanks! Comment Actions Removing the empty space above the buttons would make it look better at low resolution screens. This is how it currently looks on 1280×720: Comment Actions Index: binaries/data/mods/public/gui/pregame/menupanel.xml =================================================================== --- binaries/data/mods/public/gui/pregame/menupanel.xml (revision 23392) +++ binaries/data/mods/public/gui/pregame/menupanel.xml (working copy) @@ -5,7 +5,7 @@ <object name="mainMenu" type="image" style="MainMenuPanel" size="60 -2 300 100%+2" z="50"> - <object name="mainMenuButtons" size="8 156 100%-8 356"> + <object name="mainMenuButtons" size="8 126 100%-8 326"> <repeat count="10"> <object name="mainMenuButton[n]" type="button" style="StoneButtonFancy" tooltip_style="pgToolTip"/> </repeat> That would implicitly remove that space as well if there isn't enough space. I guess there is no vertical align option for GUI objects, but one should be able to code it with 5 lines: let size = Engine.GetGUIObjectByName(mainMenuButtons).size; size.top = logo.size.bottom size.bottom = projectInformation.size.top; Engine.GetGUIObjectByName(mainMenuButtons).size = size; + something like that +/- refactoring + consistent with the rest of the code Comment Actions or this pattern (has the advantage of not hardcoding references to neighbors): top = 50%-halfHeight bottom = 50% + halfHeight ` where 2 * halfHeight = buttons * buttonHeight Comment Actions
True, though 1280×720 is actually larger (and newer?) than 1024×768. |