public void AddAgentResultNotification(bool Good, string result, Empire Owner)
 {
     if (Owner != EmpireManager.GetEmpireByName(Ship.universeScreen.PlayerLoyalty))
     {
         return;
     }
     Notification cNote = new Notification()
     {
         Message = result,
         IconPath = (Good ? "NewUI/icon_spy_notification" : "NewUI/icon_spy_notification_bad"),
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     if (!Good)
     {
         AudioManager.PlayCue("sd_ui_spy_fail_02");
     }
     else
     {
         AudioManager.PlayCue("sd_ui_spy_win_02");
     }
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddBeingInvadedNotification(SolarSystem beingInvaded, Empire Invader)
 {
     Notification cNote = new Notification()
     {
         RelevantEmpire = Invader
     };
     string[] singular = new string[] { Invader.data.Traits.Singular, Localizer.Token(1500), "\n", Localizer.Token(1501), beingInvaded.Name, Localizer.Token(1502) };
     cNote.Message = string.Concat(singular);
     cNote.ReferencedItem1 = beingInvaded;
     cNote.IconPath = "NewUI/icon_planet_terran_01_mid";
     cNote.Action = "SnapToSystem";
     cNote.ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64);
     cNote.DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64);
     AudioManager.PlayCue("sd_notify_alert");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddSurrendered(Empire Absorber, Empire Target)
 {
     Notification cNote = new Notification()
     {
         RelevantEmpire = Absorber,
         Message = string.Concat(Target.data.Traits.Name, " ", Localizer.Token(2259), Absorber.data.Traits.Name),
         IconPath = "NewUI/icon_planet_terran_01_mid",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_troop_march_01");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddResearchComplete(string unlocked, Empire emp)
 {
     Notification cNote = new Notification()
     {
         Tech = true,
         Message = string.Concat(Localizer.Token(ResourceManager.TechTree[unlocked].NameIndex), Localizer.Token(1514)),
         ReferencedItem1 = unlocked,
         //Added by McShooterz: Techs using Icon Path need this for notifications
         IconPath = ResourceManager.TextureDict.ContainsKey(string.Concat("TechIcons/", ResourceManager.TechTree[unlocked].IconPath)) ? string.Concat("TechIcons/", ResourceManager.TechTree[unlocked].IconPath) : string.Concat("TechIcons/", unlocked),
         //IconPath = string.Concat("TechIcons/", unlocked),
         Action = "ResearchScreen",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_ui_notification_research_01");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddRebellionNotification(Planet beingInvaded, Empire Invader)
 {
     Notification cNote = new Notification()
     {
         Message = string.Concat("Rebellion on ", beingInvaded.Name, "!"),
         ReferencedItem1 = beingInvaded.system,
         IconPath = "UI/icon_rebellion",
         Action = "SnapToSystem",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_troop_march_01");
     AudioManager.PlayCue("sd_notify_alert");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddEmpireDiedNotification(Empire thatDied)
 {
     Notification cNote = new Notification()
     {
         RelevantEmpire = thatDied,
         Message = string.Concat(thatDied.data.Traits.Name, " has been defeated"),
         IconPath = "NewUI/icon_planet_terran_01_mid",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_troop_march_01");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
        public void DoExplore(float elapsedTime)
        {
            this.HasPriorityOrder = true;
            this.IgnoreCombat = true;
            if (this.ExplorationTarget == null)
            {
                this.ExplorationTarget = this.Owner.loyalty.GetGSAI().AssignExplorationTarget(this.Owner);
                if (this.ExplorationTarget == null)
                {
                    this.OrderQueue.Clear();
                    this.State = AIState.AwaitingOrders;
                    return;
                }
            }
            else if (this.DoExploreSystem(elapsedTime))
            {
                if (this.Owner.loyalty == ArtificialIntelligence.universeScreen.player)
                {
                    //added by gremlin  add shamatts notification here
                    string planetsInfo = "";
                    Dictionary<string, int> planetsTypesNumber = new Dictionary<string, int>();
                    SolarSystem system = this.ExplorationTarget;
                    if (system.PlanetList.Count > 0)
                    {
                        foreach (Planet planet in system.PlanetList)
                        {
                            // some planets don't have Type set and it is null
                            if (planet.Type == null)
                            {
                                planet.Type = "Other";
                            }

                            if (!planetsTypesNumber.ContainsKey(planet.Type))
                            {
                                planetsTypesNumber.Add(planet.Type, 1);
                            }
                            else
                            {
                                planetsTypesNumber[planet.Type] += 1;
                            }
                        }

                        foreach (KeyValuePair<string, int> pair in planetsTypesNumber)
                        {
                            planetsInfo = planetsInfo + "\n" + pair.Value + " " + pair.Key;
                        }
                    }

                    Notification cNote = new Notification()
                    {
                        Pause = false,
                        RelevantEmpire = this.Owner.loyalty,
                        Message = string.Concat(system.Name, " system explored."),
                        ReferencedItem1 = system,
                        IconPath = "NewUI/icon_planet_terran_01_mid",
                        Action = "SnapToExpandSystem",
                        ClickRect = new Rectangle(Planet.universeScreen.NotificationManager.NotificationArea.X, Planet.universeScreen.NotificationManager.NotificationArea.Y, 64, 64),
                        DestinationRect = new Rectangle(Planet.universeScreen.NotificationManager.NotificationArea.X, Planet.universeScreen.NotificationManager.NotificationArea.Y + Planet.universeScreen.NotificationManager.NotificationArea.Height - (Planet.universeScreen.NotificationManager.NotificationList.Count + 1) * 70, 64, 64)

                    };
                    cNote.Message = cNote.Message + planetsInfo;
                    if (system.combatTimer > 0)
                    {
                        cNote.Message += "\nCombat in system!!!";
                    }
                    if (system.OwnerList.Count > 0 && !system.OwnerList.Contains(this.Owner.loyalty))
                    {
                        cNote.Message += "\nContested system!!!";
                    }

                    foreach (Planet stuff in system.PlanetList)
                    {

                        foreach (Building tile in stuff.BuildingList)
                        {
                            if (tile.IsCommodity)
                            {

                                cNote.Message += "\n" + tile.Name + " on " + stuff.Name;
                                break;
                            }

                        }

                    }

                    AudioManager.PlayCue("sd_ui_notification_warning");
                    lock (GlobalStats.NotificationLocker)
                    {
                        Planet.universeScreen.NotificationManager.NotificationList.Add(cNote);
                    }
                }
                this.ExplorationTarget = null;

            }
        }
 public void AddWarDeclaredNotification(Empire Declarant, Empire Other)
 {
     Notification cNote = new Notification()
     {
         Message = string.Concat(Declarant.data.Traits.Name, " and ", Other.data.Traits.Name, " are now at war"),
         IconPath = "ResearchMenu/icons_techroot_infantry_hover",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 78, 58),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_troop_march_01");
     AudioManager.PlayCue("sd_notify_alert");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddNoMolesNotification(Empire Us, Empire them)
 {
     Notification cNote = new Notification()
     {
         Pause = false,
         RelevantEmpire = Us,
         Message = string.Concat(Localizer.Token(1508), them.data.Traits.Singular, Localizer.Token(1509)),
         IconPath = "NewUI/icon_planet_terran_01_mid",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_troop_march_01");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddMoneyWarning()
 {
     Notification cNote = new Notification()
     {
         Pause = false,
         Message = Localizer.Token(2296),
         IconPath = "UI/icon_warning_money",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_ui_notification_warning");
     AudioManager.PlayCue("sd_trade_01");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddMoleRemovedNotification(Planet wasConquered, Empire Us, Empire them)
 {
     Notification cNote = new Notification()
     {
         Pause = false,
         RelevantEmpire = Us,
         Message = string.Concat("Removed ", them.data.Traits.Singular, " agent from ", wasConquered.Name),
         ReferencedItem1 = wasConquered,
         IconPath = string.Concat("Planets/", wasConquered.planetType),
         Action = "SnapToPlanet",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_troop_march_01");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddFoundSomethingInteresting(Planet p)
 {
     Notification cNote = new Notification()
     {
         Pause = false,
         Message = string.Concat(Localizer.Token(1505), p.Name, Localizer.Token(1506)),
         ReferencedItem1 = p.system,
         ReferencedItem2=p,
         IconPath = string.Concat("Planets/", p.planetType),
         Action = "SnapToExpandSystem",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_ui_notification_encounter");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddForeignTroopsRemovedNotification(Planet where)
 {
     Notification cNote = new Notification()
     {
         Message = string.Concat("Foreign troops evacuated from ", where.Name),
         ReferencedItem1 = where,
         IconPath = string.Concat("Planets/", where.planetType),
         Action = "SnapToPlanet",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_notify_alert");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddEventNotification(ExplorationEvent expEvent, string cMessage)
 {
     Notification cNote = new Notification()
     {
         Pause = false,
         Message = cMessage,
         ReferencedItem1 = expEvent,
         IconPath = "ResearchMenu/icon_event_science",
         Action = "LoadEvent",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_ui_notification_encounter");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddEnemyTroopsLandedNotification(Planet where, Empire Invader, Empire Player)
 {
     Notification cNote = new Notification()
     {
         RelevantEmpire = Invader,
         Message = string.Concat(Invader.data.Traits.Singular, Localizer.Token(1507), where.Name, "!"),
         ReferencedItem1 = where,
         IconPath = string.Concat("Planets/", where.planetType),
         Action = "CombatScreen",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_notify_alert");
     AudioManager.PlayCue("sd_troop_march_01");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddPeaceTreatyEnteredNotification(Empire First, Empire Second)
 {
     Notification cNote = new Notification()
     {
         Pause = false,
         Message = string.Concat(First.data.Traits.Name, " and ", Second.data.Traits.Name, "\n are now at peace"),
         IconPath = "UI/icon_peace",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 78, 58),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_ui_notification_conquer_01");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddTroopsRemovedNotification(Planet where)
 {
     Notification cNote = new Notification()
     {
         Message = string.Concat("Your troops stationed on ", where.Name, " had to evacuate when ", where.Owner.data.Traits.Name, " colonized the planet"),
         ReferencedItem1 = where,
         IconPath = string.Concat("Planets/", where.planetType),
         Action = "SnapToPlanet",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_notify_alert");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddPeaceTreatyExpiredNotification(Empire otherEmpire)
 {
     Notification cNote = new Notification()
     {
         Pause = false,
         Message = string.Concat("Peace Treaty expired with \n", otherEmpire.data.Traits.Name),
         IconPath = "UI/icon_peace_cancel",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_ui_notification_warning");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddWarStartedNotification(Empire First, Empire Second)
 {
     Notification cNote = new Notification()
     {
         Message = string.Concat(First.data.Traits.Name, " and ", Second.data.Traits.Name, "\n are now at War"),
         IconPath = "UI/icon_warning_money",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_ui_notification_startgame");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddPlanetDiedNotification(Planet died, Empire Owner)
 {
     Notification cNote = new Notification()
     {
         Message = string.Concat(Localizer.Token(1511), died.Name, Localizer.Token(1512)),
         ReferencedItem1 = died.system,
         IconPath = string.Concat("Planets/", died.planetType),
         Action = "SnapToSystem",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_ui_notification_warning");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
 public void AddColonizedNotification(Planet wasColonized, Empire emp)
 {
     Notification cNote = new Notification()
     {
         RelevantEmpire = emp,
         Message = string.Concat(wasColonized.Name, Localizer.Token(1513)),
         ReferencedItem1 = wasColonized,
         IconPath = string.Concat("Planets/", wasColonized.planetType),
         Action = "SnapToPlanet",
         ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64),
         DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64)
     };
     AudioManager.PlayCue("sd_ui_notification_colonized_01");
     this.NotificationList.Add(cNote);
 }
 public void AddRandomEventNotification(string Message, string IconPath, string Action, Planet p)
 {
     Notification cNote = new Notification()
     {
         Message = Message
     };
     if (Action != null)
     {
         cNote.Action = Action;
     }
     if (p != null)
     {
         cNote.ReferencedItem1 = p;
     }
     cNote.IconPath = (IconPath != null ? IconPath : "ResearchMenu/icon_event_science_bad");
     cNote.ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64);
     cNote.DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64);
     AudioManager.PlayCue("sd_ui_notification_encounter");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }
        public void UpdateOwnedPlanet()
        {
            ++this.TurnsSinceTurnover;
            --this.Crippled_Turns;
            if (this.Crippled_Turns < 0)
                this.Crippled_Turns = 0;
            this.ConstructionQueue.ApplyPendingRemovals();
            this.UpdateDevelopmentStatus();
            this.Description = this.DevelopmentStatus;
            this.AffectNearbyShips();
            this.TerraformPoints += this.TerraformToAdd;
            if ((double)this.TerraformPoints > 0.0 && (double)this.Fertility < 1.0)
            {
                this.Fertility += this.TerraformToAdd;
                if (this.Type == "Barren" && (double)this.Fertility > 0.01)
                {
                    lock (GlobalStats.ObjectManagerLocker)
                        Planet.universeScreen.ScreenManager.inter.ObjectManager.Remove((ISceneObject)this.SO);
                    this.planetType = 14;
                    this.Terraform();
                }
                else if (this.Type == "Desert" && (double)this.Fertility > 0.35)
                {
                    lock (GlobalStats.ObjectManagerLocker)
                        Planet.universeScreen.ScreenManager.inter.ObjectManager.Remove((ISceneObject)this.SO);
                    this.planetType = 18;
                    this.Terraform();
                }
                else if (this.Type == "Ice" && (double)this.Fertility > 0.35)
                {
                    lock (GlobalStats.ObjectManagerLocker)
                        Planet.universeScreen.ScreenManager.inter.ObjectManager.Remove((ISceneObject)this.SO);
                    this.planetType = 19;
                    this.Terraform();
                }
                else if (this.Type == "Swamp" && (double)this.Fertility > 0.75)
                {
                    lock (GlobalStats.ObjectManagerLocker)
                        Planet.universeScreen.ScreenManager.inter.ObjectManager.Remove((ISceneObject)this.SO);
                    this.planetType = 21;
                    this.Terraform();
                }
                else if (this.Type == "Steppe" && (double)this.Fertility > 0.6)
                {
                    lock (GlobalStats.ObjectManagerLocker)
                        Planet.universeScreen.ScreenManager.inter.ObjectManager.Remove((ISceneObject)this.SO);
                    this.planetType = 11;
                    this.Terraform();
                }
                else if (this.Type == "Tundra" && (double)this.Fertility > 0.95)
                {
                    lock (GlobalStats.ObjectManagerLocker)
                        Planet.universeScreen.ScreenManager.inter.ObjectManager.Remove((ISceneObject)this.SO);
                    this.planetType = 22;
                    this.Terraform();
                }
                if ((double)this.Fertility > 1.0)
                    this.Fertility = 1f;
            }
            if (this.GovernorOn)
                this.DoGoverning();
            this.UpdateIncomes();
            // ADDED BY SHAHMATT (notification about empty queue)
            if (GlobalStats.ExtraNotiofications && this.Owner == EmpireManager.GetEmpireByName(Planet.universeScreen.PlayerLoyalty)
                && this.ConstructionQueue.Count <= 0 && !this.queueEmptySent)
            {
                if (this.colonyType == Planet.ColonyType.Colony || this.colonyType == Planet.ColonyType.Core || this.colonyType == Planet.ColonyType.Industrial || !this.GovernorOn)
                {
                    this.queueEmptySent = true;
                    Notification cNote = new Notification()
                    {
                        Pause = false,
                        RelevantEmpire = this.Owner,
                        Message = string.Concat(this.Name, " is not producing anything."),
                        ReferencedItem1 = this, //this.system,
                        IconPath = string.Concat("Planets/", this.planetType),//"UI/icon_warning_money",
                        Action = "SnapToPlanet", //"SnapToSystem",
                        ClickRect = new Rectangle(Planet.universeScreen.NotificationManager.NotificationArea.X, Planet.universeScreen.NotificationManager.NotificationArea.Y, 64, 64),
                        DestinationRect = new Rectangle(Planet.universeScreen.NotificationManager.NotificationArea.X, Planet.universeScreen.NotificationManager.NotificationArea.Y + Planet.universeScreen.NotificationManager.NotificationArea.Height - (Planet.universeScreen.NotificationManager.NotificationList.Count + 1) * 70, 64, 64)
                    };
                    AudioManager.PlayCue("sd_ui_notification_warning");
                    lock (GlobalStats.NotificationLocker)
                    {
                        Planet.universeScreen.NotificationManager.NotificationList.Add(cNote);
                    }
                }
            }
            else if (GlobalStats.ExtraNotiofications && this.Owner !=null && this.Owner.isPlayer && this.ConstructionQueue.Count > 0)
            {
                this.queueEmptySent = false;
            }
            // END OF ADDED BY SHAHMATT
            //if ((double)this.ShieldStrengthCurrent < (double)this.ShieldStrengthMax)
            //{
            //    ++this.ShieldStrengthCurrent;
            //    if ((double)this.ShieldStrengthCurrent > (double)this.ShieldStrengthMax)
            //        this.ShieldStrengthCurrent = this.ShieldStrengthMax;
            //}
            //if ((double)this.ShieldStrengthCurrent > (double)this.ShieldStrengthMax)
            //    this.ShieldStrengthCurrent = this.ShieldStrengthMax;
            //added by gremlin Planetary Shield Change
            if (this.ShieldStrengthCurrent < this.ShieldStrengthMax)
            {
                Planet shieldStrengthCurrent = this;

                if (!this.RecentCombat)
                {

                    if (this.ShieldStrengthCurrent > this.ShieldStrengthMax / 10)
                    {
                        shieldStrengthCurrent.ShieldStrengthCurrent += shieldStrengthCurrent.ShieldStrengthMax / 10;
                    }
                    else
                    {
                        shieldStrengthCurrent.ShieldStrengthCurrent++;
                    }
                }
                if ((double)this.ShieldStrengthCurrent > (double)this.ShieldStrengthMax)
                    this.ShieldStrengthCurrent = this.ShieldStrengthMax;
            }

            //this.UpdateTimer = 10f;
            this.HarvestResources();
            this.ApplyProductionTowardsConstruction();
            this.GrowPopulation();
            //Added by McShooterz
            this.HealTroops();
            if ((double)this.FoodHere > (double)this.MAX_STORAGE)
                this.FoodHere = this.MAX_STORAGE;
            if ((double)this.ProductionHere <= (double)this.MAX_STORAGE)
                return;
            this.ProductionHere = this.MAX_STORAGE;
        }
 public void AddConqueredNotification(Planet wasConquered, Empire Conquerer, Empire Loser)
 {
     Notification cNote = new Notification()
     {
         RelevantEmpire = Conquerer
     };
     string[] name = new string[] { Conquerer.data.Traits.Name, Localizer.Token(1503), wasConquered.Name, "\n", Localizer.Token(1504), Loser.data.Traits.Name };
     cNote.Message = string.Concat(name);
     cNote.ReferencedItem1 = wasConquered.system;
     cNote.IconPath = string.Concat("Planets/", wasConquered.planetType);
     cNote.Action = "SnapToSystem";
     cNote.ClickRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y, 64, 64);
     cNote.DestinationRect = new Rectangle(this.NotificationArea.X, this.NotificationArea.Y + this.NotificationArea.Height - (this.NotificationList.Count + 1) * 70, 64, 64);
     AudioManager.PlayCue("sd_troop_march_01");
     lock (GlobalStats.NotificationLocker)
     {
         this.NotificationList.Add(cNote);
     }
 }