Zero Hour rebuilt from EA's source: x64, Direct3D 11, VS2022/CMake, ~60 original bugs fixed, an AI that builds a base. Bring your own game.
C++ cmakecnccommand-and-conquercppdirectx11game-enginegame-preservationgeneralsrtssage-enginex64zero-hour
feat(hud): tab screen buttons and briefing in each side's steel
Olcay Seygan0269d313fb28
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 9caae8525..57627c497 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -29,7 +29,7 @@ found and fixed, EA's own, not port damage.**- The superweapon countdowns stand where they do in a player's game while you watch, in their tray. The observer's bar named no tray for them, so they used to sit bare and higher up.- The card that rises when you point at a build button is drawn in your side's own art now, with the price and the build time beside the name behind a coin and a clock. Under them one row of icons says what you are buying: health, armour class, damage, damage a second, range and speed for a unit, health, armour and the power it adds or draws for a building. The six lines of figures that used to pad out the description are gone, and so is the "Power Required" line EA wrote into every building's text, in every language. The small tooltip beside the pointer sits in a framed well of the same art in a match and of the watcher's steel in the menus. Both are cut from the bar itself: the same near-black shell, bevelled lip and sunk glass, the card's corner shaped like the side's bar (America's 45 degree cut, China's two steps, the GLA's bitten scrap, Turkiye's wide chamfer with its turquoise light), open on the side that meets the screen's edge.- The army screen, the lobby and the score screen wear our own emblems. Every army has a card of its own on the army screen, the generals included, where EA's faces and logos used to be, and the player card shows the same one. Turkiye stops borrowing America's logo there and in the lobby's game list. On the score screen each player's row starts with his army's emblem, and your own army's card stands faint behind the table.-- The Tab screen, with the players, their teams and the chat buttons, is painted in your side's bar now instead of EA's see-through black with a blue rule. It stands in the top left corner on the same dark steel in three tiers, square on the screen's two edges and cut at the corner facing the battlefield, every player's row in a sunk well with alternate rows a shade lighter so a name lines up with its team at a glance. The watcher gets it in his own steel. The panel is solid, so the battlefield no longer shows through the list. The Classic interface keeps EA's screen.+- The Tab screen, with the players, their teams and the chat buttons, is painted in your side's bar now instead of EA's see-through black with a blue rule. It stands in the top left corner on the same dark steel in three tiers, square on the screen's two edges and cut at the corner facing the battlefield, every player's row in a sunk well with alternate rows a shade lighter so a name lines up with its team at a glance. Its buttons are cut from the same metal: the mute switch carries a speaker that is struck through once you have muted someone, the money's minus, plus and Send sit in bezels shaped like the side's toolbar buttons, and Main Menu stands in a socket of its own. In a campaign the mission's briefing lines sit straight on the dark glass, without the grey veil and blue frame they used to wear. The watcher gets it in his own steel. The panel is solid, so the battlefield no longer shows through the list. The Classic interface keeps EA's screen.- Eight new player colours after the original eight: Teal, Lime, Navy, Magenta, Brown, Lavender, Coral and Olive, for players and AI in skirmish, LAN and online. They replace Crimson, Azure and Salmon.## Your queue in pictures againdiff --git a/GeneralsMD/Code/Data/Art/Textures/ReforgedHudAmericaTabPanel.dds b/GeneralsMD/Code/Data/Art/Textures/ReforgedHudAmericaTabPanel.ddsindex b073e8862..0977d88c9 100644Binary files a/GeneralsMD/Code/Data/Art/Textures/ReforgedHudAmericaTabPanel.dds and b/GeneralsMD/Code/Data/Art/Textures/ReforgedHudAmericaTabPanel.dds differdiff --git a/GeneralsMD/Code/Data/Art/Textures/ReforgedHudChinaTabPanel.dds b/GeneralsMD/Code/Data/Art/Textures/ReforgedHudChinaTabPanel.ddsindex c16db8968..55141708a 100644Binary files a/GeneralsMD/Code/Data/Art/Textures/ReforgedHudChinaTabPanel.dds and b/GeneralsMD/Code/Data/Art/Textures/ReforgedHudChinaTabPanel.dds differdiff --git a/GeneralsMD/Code/Data/Art/Textures/ReforgedHudGlaTabPanel.dds b/GeneralsMD/Code/Data/Art/Textures/ReforgedHudGlaTabPanel.ddsindex 136190e6f..50fd4aeee 100644Binary files a/GeneralsMD/Code/Data/Art/Textures/ReforgedHudGlaTabPanel.dds and b/GeneralsMD/Code/Data/Art/Textures/ReforgedHudGlaTabPanel.dds differdiff --git a/GeneralsMD/Code/Data/Art/Textures/ReforgedHudObsTabPanel.dds b/GeneralsMD/Code/Data/Art/Textures/ReforgedHudObsTabPanel.ddsindex a6eece684..3a41999ef 100644Binary files a/GeneralsMD/Code/Data/Art/Textures/ReforgedHudObsTabPanel.dds and b/GeneralsMD/Code/Data/Art/Textures/ReforgedHudObsTabPanel.dds differdiff --git a/GeneralsMD/Code/Data/Art/Textures/ReforgedHudTurkiyeTabPanel.dds b/GeneralsMD/Code/Data/Art/Textures/ReforgedHudTurkiyeTabPanel.ddsindex 3154a0087..1cc7cb671 100644Binary files a/GeneralsMD/Code/Data/Art/Textures/ReforgedHudTurkiyeTabPanel.dds and b/GeneralsMD/Code/Data/Art/Textures/ReforgedHudTurkiyeTabPanel.dds differdiff --git a/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudAmericaTabPanel.ini b/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudAmericaTabPanel.iniindex b877c05b3..bcfb8c8da 100644--- a/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudAmericaTabPanel.ini+++ b/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudAmericaTabPanel.ini@@ -8,3 +8,167 @@ MappedImage AmericaProTabPanelCoords = Left:0 Top:0 Right:1379 Bottom:714Status = NONEEnd++; The screen's buttons (tab_button, TAB_BUTTONS), each at its size at 1080 and Diplomacy.cpp's dressTabButton+; stretching it over its button: Send, the money's - and + (Square), Mute and Unmute, Main Menu (Exit); H hilited,+; P pushed, D disabled.++MappedImage AmericaProTabSend+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:4 Right:1492 Bottom:47+ Status = NONE+End++MappedImage AmericaProTabSendH+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:58 Right:1492 Bottom:101+ Status = NONE+End++MappedImage AmericaProTabSendP+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:112 Right:1492 Bottom:155+ Status = NONE+End++MappedImage AmericaProTabSendD+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:166 Right:1492 Bottom:209+ Status = NONE+End++MappedImage AmericaProTabSquare+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:4 Right:1540 Bottom:47+ Status = NONE+End++MappedImage AmericaProTabSquareH+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:58 Right:1540 Bottom:101+ Status = NONE+End++MappedImage AmericaProTabSquareP+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:112 Right:1540 Bottom:155+ Status = NONE+End++MappedImage AmericaProTabSquareD+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:166 Right:1540 Bottom:209+ Status = NONE+End++MappedImage AmericaProTabMute+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:4 Right:1587 Bottom:47+ Status = NONE+End++MappedImage AmericaProTabMuteH+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:58 Right:1587 Bottom:101+ Status = NONE+End++MappedImage AmericaProTabMuteP+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:112 Right:1587 Bottom:155+ Status = NONE+End++MappedImage AmericaProTabMuteD+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:166 Right:1587 Bottom:209+ Status = NONE+End++MappedImage AmericaProTabUnmute+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:4 Right:1635 Bottom:47+ Status = NONE+End++MappedImage AmericaProTabUnmuteH+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:58 Right:1635 Bottom:101+ Status = NONE+End++MappedImage AmericaProTabUnmuteP+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:112 Right:1635 Bottom:155+ Status = NONE+End++MappedImage AmericaProTabUnmuteD+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:166 Right:1635 Bottom:209+ Status = NONE+End++MappedImage AmericaProTabExit+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:4 Right:1806 Bottom:52+ Status = NONE+End++MappedImage AmericaProTabExitH+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:58 Right:1806 Bottom:106+ Status = NONE+End++MappedImage AmericaProTabExitP+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:112 Right:1806 Bottom:160+ Status = NONE+End++MappedImage AmericaProTabExitD+ Texture = ReforgedHudAmericaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:166 Right:1806 Bottom:214+ Status = NONE+Enddiff --git a/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudChinaTabPanel.ini b/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudChinaTabPanel.iniindex 5aee33307..bf07f81e9 100644--- a/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudChinaTabPanel.ini+++ b/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudChinaTabPanel.ini@@ -8,3 +8,167 @@ MappedImage ChinaProTabPanelCoords = Left:0 Top:0 Right:1379 Bottom:714Status = NONEEnd++; The screen's buttons (tab_button, TAB_BUTTONS), each at its size at 1080 and Diplomacy.cpp's dressTabButton+; stretching it over its button: Send, the money's - and + (Square), Mute and Unmute, Main Menu (Exit); H hilited,+; P pushed, D disabled.++MappedImage ChinaProTabSend+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:4 Right:1492 Bottom:47+ Status = NONE+End++MappedImage ChinaProTabSendH+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:58 Right:1492 Bottom:101+ Status = NONE+End++MappedImage ChinaProTabSendP+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:112 Right:1492 Bottom:155+ Status = NONE+End++MappedImage ChinaProTabSendD+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:166 Right:1492 Bottom:209+ Status = NONE+End++MappedImage ChinaProTabSquare+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:4 Right:1540 Bottom:47+ Status = NONE+End++MappedImage ChinaProTabSquareH+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:58 Right:1540 Bottom:101+ Status = NONE+End++MappedImage ChinaProTabSquareP+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:112 Right:1540 Bottom:155+ Status = NONE+End++MappedImage ChinaProTabSquareD+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:166 Right:1540 Bottom:209+ Status = NONE+End++MappedImage ChinaProTabMute+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:4 Right:1587 Bottom:47+ Status = NONE+End++MappedImage ChinaProTabMuteH+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:58 Right:1587 Bottom:101+ Status = NONE+End++MappedImage ChinaProTabMuteP+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:112 Right:1587 Bottom:155+ Status = NONE+End++MappedImage ChinaProTabMuteD+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:166 Right:1587 Bottom:209+ Status = NONE+End++MappedImage ChinaProTabUnmute+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:4 Right:1635 Bottom:47+ Status = NONE+End++MappedImage ChinaProTabUnmuteH+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:58 Right:1635 Bottom:101+ Status = NONE+End++MappedImage ChinaProTabUnmuteP+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:112 Right:1635 Bottom:155+ Status = NONE+End++MappedImage ChinaProTabUnmuteD+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:166 Right:1635 Bottom:209+ Status = NONE+End++MappedImage ChinaProTabExit+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:4 Right:1806 Bottom:52+ Status = NONE+End++MappedImage ChinaProTabExitH+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:58 Right:1806 Bottom:106+ Status = NONE+End++MappedImage ChinaProTabExitP+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:112 Right:1806 Bottom:160+ Status = NONE+End++MappedImage ChinaProTabExitD+ Texture = ReforgedHudChinaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:166 Right:1806 Bottom:214+ Status = NONE+Enddiff --git a/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudGlaTabPanel.ini b/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudGlaTabPanel.iniindex fc747d0f6..15c43b4e4 100644--- a/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudGlaTabPanel.ini+++ b/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudGlaTabPanel.ini@@ -8,3 +8,167 @@ MappedImage GlaProTabPanelCoords = Left:0 Top:0 Right:1379 Bottom:714Status = NONEEnd++; The screen's buttons (tab_button, TAB_BUTTONS), each at its size at 1080 and Diplomacy.cpp's dressTabButton+; stretching it over its button: Send, the money's - and + (Square), Mute and Unmute, Main Menu (Exit); H hilited,+; P pushed, D disabled.++MappedImage GlaProTabSend+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:4 Right:1492 Bottom:47+ Status = NONE+End++MappedImage GlaProTabSendH+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:58 Right:1492 Bottom:101+ Status = NONE+End++MappedImage GlaProTabSendP+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:112 Right:1492 Bottom:155+ Status = NONE+End++MappedImage GlaProTabSendD+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:166 Right:1492 Bottom:209+ Status = NONE+End++MappedImage GlaProTabSquare+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:4 Right:1540 Bottom:47+ Status = NONE+End++MappedImage GlaProTabSquareH+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:58 Right:1540 Bottom:101+ Status = NONE+End++MappedImage GlaProTabSquareP+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:112 Right:1540 Bottom:155+ Status = NONE+End++MappedImage GlaProTabSquareD+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:166 Right:1540 Bottom:209+ Status = NONE+End++MappedImage GlaProTabMute+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:4 Right:1587 Bottom:47+ Status = NONE+End++MappedImage GlaProTabMuteH+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:58 Right:1587 Bottom:101+ Status = NONE+End++MappedImage GlaProTabMuteP+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:112 Right:1587 Bottom:155+ Status = NONE+End++MappedImage GlaProTabMuteD+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:166 Right:1587 Bottom:209+ Status = NONE+End++MappedImage GlaProTabUnmute+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:4 Right:1635 Bottom:47+ Status = NONE+End++MappedImage GlaProTabUnmuteH+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:58 Right:1635 Bottom:101+ Status = NONE+End++MappedImage GlaProTabUnmuteP+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:112 Right:1635 Bottom:155+ Status = NONE+End++MappedImage GlaProTabUnmuteD+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:166 Right:1635 Bottom:209+ Status = NONE+End++MappedImage GlaProTabExit+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:4 Right:1806 Bottom:52+ Status = NONE+End++MappedImage GlaProTabExitH+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:58 Right:1806 Bottom:106+ Status = NONE+End++MappedImage GlaProTabExitP+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:112 Right:1806 Bottom:160+ Status = NONE+End++MappedImage GlaProTabExitD+ Texture = ReforgedHudGlaTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:166 Right:1806 Bottom:214+ Status = NONE+Enddiff --git a/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudObsTabPanel.ini b/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudObsTabPanel.iniindex a513b59fc..f198d9983 100644--- a/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudObsTabPanel.ini+++ b/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudObsTabPanel.ini@@ -8,3 +8,167 @@ MappedImage HelpboxTabPanelCoords = Left:0 Top:0 Right:1379 Bottom:714Status = NONEEnd++; The screen's buttons (tab_button, TAB_BUTTONS), each at its size at 1080 and Diplomacy.cpp's dressTabButton+; stretching it over its button: Send, the money's - and + (Square), Mute and Unmute, Main Menu (Exit); H hilited,+; P pushed, D disabled.++MappedImage HelpboxTabSend+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:4 Right:1492 Bottom:47+ Status = NONE+End++MappedImage HelpboxTabSendH+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:58 Right:1492 Bottom:101+ Status = NONE+End++MappedImage HelpboxTabSendP+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:112 Right:1492 Bottom:155+ Status = NONE+End++MappedImage HelpboxTabSendD+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:166 Right:1492 Bottom:209+ Status = NONE+End++MappedImage HelpboxTabSquare+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:4 Right:1540 Bottom:47+ Status = NONE+End++MappedImage HelpboxTabSquareH+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:58 Right:1540 Bottom:101+ Status = NONE+End++MappedImage HelpboxTabSquareP+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:112 Right:1540 Bottom:155+ Status = NONE+End++MappedImage HelpboxTabSquareD+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:166 Right:1540 Bottom:209+ Status = NONE+End++MappedImage HelpboxTabMute+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:4 Right:1587 Bottom:47+ Status = NONE+End++MappedImage HelpboxTabMuteH+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:58 Right:1587 Bottom:101+ Status = NONE+End++MappedImage HelpboxTabMuteP+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:112 Right:1587 Bottom:155+ Status = NONE+End++MappedImage HelpboxTabMuteD+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:166 Right:1587 Bottom:209+ Status = NONE+End++MappedImage HelpboxTabUnmute+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:4 Right:1635 Bottom:47+ Status = NONE+End++MappedImage HelpboxTabUnmuteH+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:58 Right:1635 Bottom:101+ Status = NONE+End++MappedImage HelpboxTabUnmuteP+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:112 Right:1635 Bottom:155+ Status = NONE+End++MappedImage HelpboxTabUnmuteD+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:166 Right:1635 Bottom:209+ Status = NONE+End++MappedImage HelpboxTabExit+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:4 Right:1806 Bottom:52+ Status = NONE+End++MappedImage HelpboxTabExitH+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:58 Right:1806 Bottom:106+ Status = NONE+End++MappedImage HelpboxTabExitP+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:112 Right:1806 Bottom:160+ Status = NONE+End++MappedImage HelpboxTabExitD+ Texture = ReforgedHudObsTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:166 Right:1806 Bottom:214+ Status = NONE+Enddiff --git a/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudTurkiyeTabPanel.ini b/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudTurkiyeTabPanel.iniindex 30d5b661c..cbd90e127 100644--- a/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudTurkiyeTabPanel.ini+++ b/GeneralsMD/Code/Data/INI/MappedImages/HandCreated/ReforgedHudTurkiyeTabPanel.ini@@ -8,3 +8,167 @@ MappedImage TurkiyeProTabPanelCoords = Left:0 Top:0 Right:1379 Bottom:714Status = NONEEnd++; The screen's buttons (tab_button, TAB_BUTTONS), each at its size at 1080 and Diplomacy.cpp's dressTabButton+; stretching it over its button: Send, the money's - and + (Square), Mute and Unmute, Main Menu (Exit); H hilited,+; P pushed, D disabled.++MappedImage TurkiyeProTabSend+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:4 Right:1492 Bottom:47+ Status = NONE+End++MappedImage TurkiyeProTabSendH+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:58 Right:1492 Bottom:101+ Status = NONE+End++MappedImage TurkiyeProTabSendP+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:112 Right:1492 Bottom:155+ Status = NONE+End++MappedImage TurkiyeProTabSendD+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1384 Top:166 Right:1492 Bottom:209+ Status = NONE+End++MappedImage TurkiyeProTabSquare+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:4 Right:1540 Bottom:47+ Status = NONE+End++MappedImage TurkiyeProTabSquareH+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:58 Right:1540 Bottom:101+ Status = NONE+End++MappedImage TurkiyeProTabSquareP+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:112 Right:1540 Bottom:155+ Status = NONE+End++MappedImage TurkiyeProTabSquareD+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1496 Top:166 Right:1540 Bottom:209+ Status = NONE+End++MappedImage TurkiyeProTabMute+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:4 Right:1587 Bottom:47+ Status = NONE+End++MappedImage TurkiyeProTabMuteH+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:58 Right:1587 Bottom:101+ Status = NONE+End++MappedImage TurkiyeProTabMuteP+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:112 Right:1587 Bottom:155+ Status = NONE+End++MappedImage TurkiyeProTabMuteD+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1544 Top:166 Right:1587 Bottom:209+ Status = NONE+End++MappedImage TurkiyeProTabUnmute+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:4 Right:1635 Bottom:47+ Status = NONE+End++MappedImage TurkiyeProTabUnmuteH+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:58 Right:1635 Bottom:101+ Status = NONE+End++MappedImage TurkiyeProTabUnmuteP+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:112 Right:1635 Bottom:155+ Status = NONE+End++MappedImage TurkiyeProTabUnmuteD+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1592 Top:166 Right:1635 Bottom:209+ Status = NONE+End++MappedImage TurkiyeProTabExit+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:4 Right:1806 Bottom:52+ Status = NONE+End++MappedImage TurkiyeProTabExitH+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:58 Right:1806 Bottom:106+ Status = NONE+End++MappedImage TurkiyeProTabExitP+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:112 Right:1806 Bottom:160+ Status = NONE+End++MappedImage TurkiyeProTabExitD+ Texture = ReforgedHudTurkiyeTabPanel.tga+ TextureWidth = 2048+ TextureHeight = 1024+ Coords = Left:1640 Top:166 Right:1806 Bottom:214+ Status = NONE+Enddiff --git a/GeneralsMD/Code/GameEngine/Include/GameClient/ControlBarScheme.h b/GeneralsMD/Code/GameEngine/Include/GameClient/ControlBarScheme.hindex 90fbc4bf6..24eec56d6 100644--- a/GeneralsMD/Code/GameEngine/Include/GameClient/ControlBarScheme.h+++ b/GeneralsMD/Code/GameEngine/Include/GameClient/ControlBarScheme.h@@ -362,6 +362,9 @@ public:const ControlBarTooltipImages& getConsoleTooltipImages( void ) const { return m_consoleTooltip; }/// the Tab screen's painting of the scheme on screen, NULL when it names none (Classic keeps EA's screen)const Image *getTabPanelImage( void ) const { return m_currentScheme ? m_currentScheme->m_tooltip.tabPanel : NULL; }+ /// one of the Tab screen's buttons beside that painting, <TooltipImage>Tab<piece> ("SendH", "Mute"), NULL+ /// under a scheme without the painting+ const Image *getTabImage( const char *piece ) const;/// the scheme's painting, cut at the panel seams and each piece drawn where its panel standsvoid drawPainting( ICoord2D offset, Bool foreground );diff --git a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/ControlBar/ControlBarScheme.cpp b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/ControlBar/ControlBarScheme.cppindex 61f64c084..920c2c90b 100644--- a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/ControlBar/ControlBarScheme.cpp+++ b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/ControlBar/ControlBarScheme.cpp@@ -1407,6 +1407,16 @@ const ControlBarTooltipImages& ControlBarSchemeManager::getTooltipImages( void )return m_currentScheme->m_tooltip;}+const Image *ControlBarSchemeManager::getTabImage( const char *piece ) const+{+ if( getTabPanelImage() == NULL )+ return NULL;+ AsciiString name = m_currentScheme->m_tooltipName;+ name.concat( "Tab" );+ name.concat( piece );+ return TheMappedImageCollection->findImageByName( name );+}+//-----------------------------------------------------------------------------/** Nine pieces between outer and inner: the corners, the edges stretched along inner and the centre* under it. A piece the art leaves out (drawImage takes NULL) leaves what is under it showing. */diff --git a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Diplomacy.cpp b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Diplomacy.cppindex 33a477bd1..add6e1c59 100644--- a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Diplomacy.cpp+++ b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Diplomacy.cpp@@ -47,6 +47,7 @@#include "GameClient/Gadget.h"#include "GameClient/GadgetCheckBox.h"#include "GameClient/GadgetListBox.h"+#include "GameClient/GadgetPushButton.h"#include "GameClient/GadgetTextEntry.h"#include "GameClient/GadgetStaticText.h"#include "GameClient/GadgetRadioButton.h"@@ -368,6 +369,55 @@ void UpdateDiplomacyBriefingText(AsciiString newText, Bool clear)GadgetListBoxAddEntryText(listboxSolo, translated, TheInGameUI->getMessageColor(numEntries%2), -1);}+/// a Diplomacy.wnd button in the scheme's own pieces beside its painting, <TooltipImage>Tab<piece>{,H,P,D}:+/// one picture stretched over the button where the layout named EA's three+static void dressTabButton( GameWindow *button, const char *piece )+{+ const ControlBarSchemeManager *schemes = TheControlBar->getControlBarSchemeManager();+ AsciiString name;+ GadgetButtonSetEnabledImage(button, schemes->getTabImage(piece));+ name.format("%sH", piece);+ GadgetButtonSetHiliteImage(button, schemes->getTabImage(name.str()));+ name.format("%sP", piece);+ GadgetButtonSetHiliteSelectedImage(button, schemes->getTabImage(name.str()));+ name.format("%sD", piece);+ GadgetButtonSetDisabledImage(button, schemes->getTabImage(name.str()));+}++/// The Tab screen's controls on the scheme's painting (Tools/hud_command_bar.py tab_panel, TAB_BUTTONS): the+/// Main Menu, mute and money buttons in the side's pieces, and the campaign's briefing list without EA's+/// veil and blue rule, standing in the painting's glass (y 99..608 of the 714 the window is at 1080) so its+/// lines read on the wells and not across their lips.+static void dressForPanel( void )+{+ Int width, height;+ theWindow->winGetSize(&width, &height);+ dressTabButton(TheWindowManager->winGetWindowFromId(theWindow, NAMEKEY("Diplomacy.wnd:ButtonHide")), "Exit");+ for (Int i = 0; i < MAX_SLOTS; ++i)+ {+ dressTabButton(buttonMute[i], "Mute");+ dressTabButton(buttonUnMute[i], "Unmute");+ dressTabButton(buttonMoneyMinus[i], "Square");+ dressTabButton(buttonMoneyPlus[i], "Square");+ dressTabButton(buttonMoneySend[i], "Send");+ }++ GameWindow *listboxSolo = TheWindowManager->winGetWindowFromId(theWindow, NAMEKEY("Diplomacy.wnd:ListboxSolo"));+ GadgetListBoxSetEnabledColor(listboxSolo, WIN_COLOR_UNDEFINED);+ GadgetListBoxSetEnabledBorderColor(listboxSolo, WIN_COLOR_UNDEFINED);+ GadgetListBoxSetHiliteColor(listboxSolo, WIN_COLOR_UNDEFINED);+ GadgetListBoxSetHiliteBorderColor(listboxSolo, WIN_COLOR_UNDEFINED);+ GadgetListBoxSetDisabledColor(listboxSolo, WIN_COLOR_UNDEFINED);+ GadgetListBoxSetDisabledBorderColor(listboxSolo, WIN_COLOR_UNDEFINED);+ Int x, y, screenX, screenY, panelX, panelY, listWidth, listHeight;+ listboxSolo->winGetPosition(&x, &y);+ listboxSolo->winGetScreenPosition(&screenX, &screenY);+ theWindow->winGetScreenPosition(&panelX, &panelY);+ listboxSolo->winGetSize(&listWidth, &listHeight);+ listboxSolo->winSetPosition(x, y + panelY + height * 99 / 714 - screenY);+ listboxSolo->winSetSize(listWidth, height * (608 - 99) / 714);+}+// ------------------------------------------------------------------------------------------------// ------------------------------------------------------------------------------------------------void ShowDiplomacy( Bool immediate )@@ -461,6 +511,8 @@ void ShowDiplomacy( Bool immediate )TheInGameUI->registerWindowLayout(theLayout);grabWindowPointers();+ if (panel)+ dressForPanel();PopulateInGameDiplomacyPopup();if(TheGameSpyInfo && TheGameSpyInfo->getLocalProfileID() != 0)diff --git a/GeneralsMD/Code/Tools/hud_command_bar.py b/GeneralsMD/Code/Tools/hud_command_bar.pyindex e18a4078b..b730ec6e4 100644--- a/GeneralsMD/Code/Tools/hud_command_bar.py+++ b/GeneralsMD/Code/Tools/hud_command_bar.py@@ -1021,6 +1021,8 @@ def button(p, r, kind, state, build):# texels): on the slope the rule lit as a grey-to-pale gradient that DXT5 smeared into the# white lip below, and in game it read as part of the lipp.h[sl][m] = p.h[sl][m].max()+ if kind is None: # a plate the code writes its text on+ returnoff = 1 if state == "P" else 0raised, ink, *again = icon(kind.replace("Idle", ""), (x0 + x1) / 2 + off, (y0 + y1) / 2 + off, build)p.bump(raised, 1.1, 0.6, glyph)@@ -2081,6 +2083,10 @@ def tab_panel(side):[(344, 22, TURQ), (W - 186, foot[0] + 9, AMBER)])sheet_img = Image.new("RGBA", TAB_SHEET, (0, 0, 0, 0))sheet_img.paste(img.crop((0, 0, W, H)), (0, 0))+ boxes = tab_button_boxes()+ for kind in TAB_BUTTONS:+ for state in TAB_STATES:+ put(sheet_img, tab_button(side, kind, state), boxes["Tab" + kind + state])return sheet_img@@ -2152,16 +2158,70 @@ def tab_fittings(p, build, W, H, top, foot):screw(p, x, y, 2.4)+# The Tab screen's buttons, on the painting's sheet to its right: Diplomacy.cpp stretches each over its+# button of Diplomacy.wnd, so each is drawn at its size there at 1080. Send, the money's - and + (Square) and+# Main Menu (Exit) are the toolbar's bezel round a dark face the code writes its text on; Mute (the player can+# be heard) and Unmute (he is muted) carry a speaker, its sound in two arcs or struck through. D is disabled.+TAB_BUTTONS = dict(Send=(tab_u(760) - tab_u(700), tab_u(118) - tab_u(94)), Square=(tab_u(590) - tab_u(566), tab_u(118) - tab_u(94)),+ Mute=(tab_u(44) - tab_u(20), tab_u(118) - tab_u(94)), Unmute=(tab_u(44) - tab_u(20), tab_u(118) - tab_u(94)),+ Exit=(TAB_HIDE[2] - TAB_HIDE[0], TAB_HIDE[3] - TAB_HIDE[1]))+TAB_BUTTON_X = dict(Send=1384, Square=1496, Mute=1544, Unmute=1592, Exit=1640)+TAB_STATES = ("", "H", "P", "D")+TAB_BUTTON_STEP = 54+++def tab_button_boxes():+ """Tab<kind><state> -> its box on the sheet, the states one under the other."""+ return {"Tab" + kind + state: (TAB_BUTTON_X[kind], 4 + TAB_BUTTON_STEP * i, TAB_BUTTON_X[kind] + w, 4 + TAB_BUTTON_STEP * i + h)+ for kind, (w, h) in TAB_BUTTONS.items() for i, state in enumerate(TAB_STATES)}+++def arc(cx, cy, r, t, sweep=0.8, n=10):+ angles = np.linspace(-sweep, sweep, n)+ return [(cx + (r + t / 2) * np.cos(a), cy + (r + t / 2) * np.sin(a)) for a in angles] + \+ [(cx + (r - t / 2) * np.cos(a), cy + (r - t / 2) * np.sin(a)) for a in angles[::-1]]+++def speaker(cx, cy, muted):+ """A speaker centred on cx, cy: its sound in two arcs, or struck through by a cross."""+ x = cx - 1+ parts = [plate(x - 8, cy - 4, x - 4, cy + 4), [(x - 4, cy - 4), (x + 2, cy - 9), (x + 2, cy + 9), (x - 4, cy + 4)]]+ if muted:+ parts += stroke([(x + 5, cy - 4), (x + 12, cy + 4)], 2.0) + stroke([(x + 5, cy + 4), (x + 12, cy - 4)], 2.0)+ else:+ parts += [arc(x + 2, cy, 5, 1.8), arc(x + 2, cy, 9.5, 1.8)]+ return parts+++def tab_button(side, kind, state):+ look = BAR_LOOKS[side]+ build = look["build"]+ w, h = TAB_BUTTONS[kind]+ o = 32 # a padded canvas, as mount_button's: shade's noise fields+ p = Painter(w + 2 * o, h + 2 * o) # go bad on one 31 texels high+ st = "I" if state == "D" else state+ button(p, (o, o, o + w, o + h), None, st, build)+ if kind in ("Mute", "Unmute"):+ off = 1 if state == "P" else 0+ p.bump(speaker(o + w / 2 + off, o + h / 2 + off, kind == "Unmute"), 1.1, 0.6,+ {"": PAPERM, "H": GOLDM, "P": HILITE, "I": DIM}[st])+ return shade(p, look, shadow=False, falloff=False).crop((o, o, o + w, o + h))++def check_tab(sheet_img, side_name, prefix):- """The painting is mapped at the window's size, opaque along the screen's two edges it stands on, and- the rows, the titles and the Main Menu button stand on it."""+ """The painting and its buttons are mapped where the generator put them, the painting opaque along the+ screen's two edges it stands on, and the rows, the titles and the Main Menu button stand on it."""M = read_mapped(side_name, "TabPanel")- assert M == {prefix + "TabPanel": (0, 0) + TAB_PANEL}, "ReforgedHud%sTabPanel.ini maps %s" % (side_name, M)+ want = {prefix + "TabPanel": (0, 0) + TAB_PANEL}+ want.update({prefix + name: box for name, box in tab_button_boxes().items()})+ assert M == want, "ReforgedHud%sTabPanel.ini maps %s, the generator draws %s" % (side_name, sorted(set(M) ^ set(want)) or M, want)a = np.asarray(sheet_img)[..., 3]W, H = TAB_PANELassert (a[0, :W - 60] == 255).all() and (a[:H - 60, 0] == 255).all(), "the Tab screen leaves the screen's edge"for x0, y0, x1, y1 in [TAB_TITLES, TAB_TABLE, TAB_HIDE]:assert (a[y0:y1, x0:x1] == 255).all(), "the Tab screen has a hole under %s" % ((x0, y0, x1, y1),)+ for name, (x0, y0, x1, y1) in tab_button_boxes().items():+ assert (a[y0 + 8:y1 - 8, x0 + 8:x1 - 8] == 255).all(), "%s%s has a hole in its face" % (prefix, name)# ---------------------------------------------------------------------------------------------- the observer