expose strings from build palette widget to chrome yaml
prepare for localisation efforts
This commit is contained in:
@@ -26,6 +26,10 @@ namespace OpenRA.Mods.RA.Widgets
|
|||||||
public int Columns = 3;
|
public int Columns = 3;
|
||||||
public int Rows = 5;
|
public int Rows = 5;
|
||||||
|
|
||||||
|
public string ReadyText = "";
|
||||||
|
public string HoldText = "";
|
||||||
|
public string RequiresText = "";
|
||||||
|
|
||||||
ProductionQueue CurrentQueue;
|
ProductionQueue CurrentQueue;
|
||||||
List<ProductionQueue> VisibleQueues;
|
List<ProductionQueue> VisibleQueues;
|
||||||
|
|
||||||
@@ -291,8 +295,8 @@ namespace OpenRA.Mods.RA.Widgets
|
|||||||
|
|
||||||
string GetOverlayForItem(ProductionItem item)
|
string GetOverlayForItem(ProductionItem item)
|
||||||
{
|
{
|
||||||
if (item.Paused) return "ON HOLD";
|
if (item.Paused) return HoldText;
|
||||||
if (item.Done) return "READY";
|
if (item.Done) return ReadyText;
|
||||||
return WidgetUtils.FormatTime(item.RemainingTimeActual);
|
return WidgetUtils.FormatTime(item.RemainingTimeActual);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -484,7 +488,7 @@ namespace OpenRA.Mods.RA.Widgets
|
|||||||
var prereqs = buildable.Prerequisites
|
var prereqs = buildable.Prerequisites
|
||||||
.Select( a => Description( a ) );
|
.Select( a => Description( a ) );
|
||||||
Game.Renderer.Fonts["Regular"].DrawText(
|
Game.Renderer.Fonts["Regular"].DrawText(
|
||||||
"Requires {0}".F(prereqs.JoinWith(", ")),
|
"{0} {1}".F(RequiresText, prereqs.JoinWith(", ")),
|
||||||
p.ToInt2(),
|
p.ToInt2(),
|
||||||
Color.White);
|
Color.White);
|
||||||
|
|
||||||
|
|||||||
@@ -58,6 +58,9 @@ Container@INGAME_ROOT:
|
|||||||
Y:280
|
Y:280
|
||||||
Width:250
|
Width:250
|
||||||
Height:500
|
Height:500
|
||||||
|
ReadyText: READY
|
||||||
|
HoldText: ON HOLD
|
||||||
|
RequiresText: Requires
|
||||||
Button@INGAME_OPTIONS_BUTTON:
|
Button@INGAME_OPTIONS_BUTTON:
|
||||||
X:0
|
X:0
|
||||||
Y:0
|
Y:0
|
||||||
|
|||||||
Reference in New Issue
Block a user