示例#1
0
        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");
        }
示例#2
0
 internal void UpdateAdminInfo(PlanetInfo planetInfo)
 {
     model.UpdateAdminInfo(planetInfo.PopIncreaseRate);
 }
示例#3
0
 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);
 }
示例#4
0
 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;            
 }