Ticket #3197: t3197_pop_cap_tooltip.patch
File t3197_pop_cap_tooltip.patch, 2.0 KB (added by , 9 years ago) |
---|
-
binaries/data/mods/public/gui/session/session.js
707 707 Engine.GetGUIObjectByName("resourceFood").caption = Math.floor(playerState.resourceCounts.food); 708 708 Engine.GetGUIObjectByName("resourceWood").caption = Math.floor(playerState.resourceCounts.wood); 709 709 Engine.GetGUIObjectByName("resourceStone").caption = Math.floor(playerState.resourceCounts.stone); 710 710 Engine.GetGUIObjectByName("resourceMetal").caption = Math.floor(playerState.resourceCounts.metal); 711 711 Engine.GetGUIObjectByName("resourcePop").caption = playerState.popCount + "/" + playerState.popLimit; 712 712 Engine.GetGUIObjectByName("population").tooltip = translate("Population (current / limit)") + "\n" 713 + translate("Maximum population") + ": " + playerState.popMax; 714 // resourcePop population 713 715 g_IsTrainingBlocked = playerState.trainingBlocked; 714 716 } 715 717 716 718 function selectAndMoveTo(ent) 717 719 { -
binaries/data/mods/public/gui/session/top_panel/resource_population.xml
1 1 <?xml version="1.0" encoding="utf-8"?> 2 2 <object name="population" size="370 0 460 100%" type="image" style="resourceCounter" tooltip_style="sessionToolTipBold"> 3 <translatableAttribute id="tooltip"> Population (current / limit)</translatableAttribute>3 <translatableAttribute id="tooltip"></translatableAttribute> 4 4 <object size="0 -4 40 34" type="image" sprite="stretched:session/icons/resources/population.png" ghost="true"/> 5 5 <object size="32 0 100% 100%-2" type="text" style="resourceText" name="resourcePop"/> 6 6 </object>