Player has Country now, not Race
This commit is contained in:
@@ -153,10 +153,10 @@ namespace OpenRa
|
||||
{
|
||||
DrawDownloadBar();
|
||||
|
||||
chromeCollection = "chrome-" + world.LocalPlayer.Race;
|
||||
radarCollection = "radar-" + world.LocalPlayer.Race;
|
||||
paletteCollection = "palette-" + world.LocalPlayer.Race;
|
||||
digitCollection = "digits-" + world.LocalPlayer.Race;
|
||||
chromeCollection = "chrome-" + world.LocalPlayer.Country.Race;
|
||||
radarCollection = "radar-" + world.LocalPlayer.Country.Race;
|
||||
paletteCollection = "palette-" + world.LocalPlayer.Country.Race;
|
||||
digitCollection = "digits-" + world.LocalPlayer.Country.Race;
|
||||
|
||||
buttons.Clear();
|
||||
|
||||
@@ -362,9 +362,13 @@ namespace OpenRa
|
||||
|
||||
void CycleRace(bool left)
|
||||
{
|
||||
// hack
|
||||
var newRace = Game.world.LocalPlayer.Race == "allies" ? "soviet" : "allies";
|
||||
Game.IssueOrder(Order.Chat("/race " + newRace));
|
||||
var countries = Game.world.GetCountries();
|
||||
var nextCountry = countries.Concat(countries)
|
||||
.SkipWhile(c => c != Game.world.LocalPlayer.Country)
|
||||
.Skip(1)
|
||||
.First();
|
||||
|
||||
Game.IssueOrder(Order.Chat("/race " + nextCountry));
|
||||
}
|
||||
|
||||
void CycleReady(bool left)
|
||||
@@ -467,7 +471,7 @@ namespace OpenRa
|
||||
paletteRect.Bottom+Game.viewport.Location.Y - 5),
|
||||
Player.PlayerColors[client.PaletteIndex].c);
|
||||
lineRenderer.Flush();
|
||||
renderer.DrawText(client.Race, new int2(r.Left + 220, y), Color.White);
|
||||
renderer.DrawText(client.Country, new int2(r.Left + 220, y), Color.White);
|
||||
renderer.DrawText(client.State.ToString(), new int2(r.Left + 290, y), Color.White);
|
||||
renderer.DrawText((client.SpawnPoint == 0)? "-" : client.SpawnPoint.ToString(), new int2(r.Left + 410, y), Color.White);
|
||||
y += 30;
|
||||
@@ -569,7 +573,7 @@ namespace OpenRa
|
||||
string[] tabKeys = { "normal", "ready", "selected" };
|
||||
var producing = queue.CurrentItem(groupName);
|
||||
var index = q.Key == currentTab ? 2 : (producing != null && producing.Done) ? 1 : 0;
|
||||
var race = world.LocalPlayer.Race;
|
||||
var race = world.LocalPlayer.Country.Race;
|
||||
rgbaRenderer.DrawSprite(ChromeProvider.GetImage(renderer,"tabs-"+tabKeys[index], race+"-"+q.Key), new float2(x, y), "chrome");
|
||||
|
||||
buttons.Add(Pair.New(new RectangleF(x, y, tabWidth, tabHeight),
|
||||
@@ -850,7 +854,7 @@ namespace OpenRa
|
||||
|
||||
var allBuildables = Rules.TechTree.AllBuildables(world.LocalPlayer, queueName)
|
||||
.Where(a => a.Traits.Contains<BuildableInfo>())
|
||||
.Where(a => a.Traits.Get<BuildableInfo>().Owner.Contains(world.LocalPlayer.Race))
|
||||
.Where(a => a.Traits.Get<BuildableInfo>().Owner.Contains(world.LocalPlayer.Country.Race))
|
||||
.OrderBy(a => a.Traits.Get<BuildableInfo>().TechLevel);
|
||||
|
||||
var queue = world.LocalPlayer.PlayerActor.traits.Get<Traits.ProductionQueue>();
|
||||
|
||||
Reference in New Issue
Block a user