public void UpdatePlanetInfo(PlanetInfo info, PlanetResourcesDetails resDetails, List<Building> buildings, List<ResourceDeposit> unusedResources, BuildQueue queue) { if (info.IsHabited.Equals("True")) { IsInhabited = true; if (info.IsOwnedByPlayer) { SliderTaxRate = int.Parse(info.TaxRate); IsDetailsEnabled = true; } else { IsDetailsEnabled = false; } } else { IsInhabited = false; IsDetailsEnabled = false; } PlanetBuildingsData.UpdateBuildingDetails(buildings, unusedResources, queue); InfoTabData.UpdateDetails(info); PlanetResourcesData.UpdateResourceDetails(resDetails); RaisePropertyChanged("IsDetailsEnabled"); RaisePropertyChanged("InfoTabData"); RaisePropertyChanged("PlanetResourcesData"); RaisePropertyChanged("PlanetBuildingsData"); }
internal void UpdateAdminInfo(PlanetInfo planetInfo) { model.UpdateAdminInfo(planetInfo.PopIncreaseRate); }
public void UpdatePlanetInfo(PlanetInfo info, PlanetResourcesDetails resDetails, List<Building> buildings, ResourceManager manager, List<ResourceDeposit> unusedResources, BuildQueue queue) { model.UpdatePlanetInfo(info, resDetails, buildings, unusedResources, queue); UpdateResources(manager); }
public void UpdateDetails(PlanetInfo info) { PNameText = "Name: " + info.Name; PTierText = "Tier: " + info.Tier; PSpeedText = "Speed: " + info.Speed; PDistanceText = "Distance from star: " + info.Distance; POwnerText = "Owned by: " + info.Owner; PHabitedText = "Is Habited: " + info.IsHabited; PPopulationText = "Population: " + info.Population; PPopIncRateText = "Population Growth Rate: " + info.PopIncreaseRate; MapImage.Texture = info.PlanetMapTexture; }