예제 #1
0
        private void FillGeneralTab()
        {
            ShipName.Text = selectedShip.Name;
            FlagImage.Load(Commons.GetFlagURL(selectedShip.Country));
            FlagImage.Tag = selectedShip.Country;
            ShipImage.Load(selectedShip.Images.Small);
            DescriptionBox.Text = selectedShip.Description;
            lblPremium.Text     = "Premium: " + Commons.TranslateTrueFalse(selectedShip.Premium);;
            lblDemo.Text        = "Demo: " + Commons.TranslateTrueFalse(selectedShip.DemoProfile);
            lblID.Text          = "ID: " + selectedShip.ID.ToString() + " (" + selectedShip.ShipId + ")";
            lblCostCredits.Text = "Cost: " + selectedShip.PriceCredits.ToString();
            lblCostGold.Text    = "Cost (gold): " + selectedShip.PriceGold.ToString();
            lblSlots.Text       = "Number of slots: " + selectedShip.NumberOfSlots.ToString();
            lblSpecial.Text     = "Special: " + Commons.TranslateTrueFalse(selectedShip.Special);
            lblTier.Text        = "Tier: " + selectedShip.Tier.ToString();
            lblShipType.Text    = "Shiptype: " + selectedShip.ShipType;

            lblTurningRadius.Text = "Turning Radius: " + selectedShip.Profile.Mobility.TurningRadius.ToString() + " m";
            lblTurningSpeed.Text  = "Ruddershift: " + selectedShip.Profile.Mobility.RudderTime.ToString() + " sec";

            lblAirDet.Text     = selectedShip.Profile.Concealment.AirDetection.ToString() + " km";
            lblSurfaceDet.Text = selectedShip.Profile.Concealment.SurfaceDetection.ToString() + " km";

            addConsumablesImages(selectedShip);
        }
예제 #2
0
        private void RandomizeShip()
        {
            Ship ThisShip = GetRandomShip();

            if (ThisShip != null)
            {
                RandomizedShip = ThisShip;
                FlagImage.Load(Commons.GetFlagURL(ThisShip.Country));
                ShipImage.Load(ThisShip.Images.Small);
                SetShipName(ThisShip.Name);
                SetDescription(ThisShip.Description);
                ShipLoaded = true;
                if (ThisShip.Premium)
                {
                    ShipImage.BackColor = SystemColors.Info;
                }
                else
                {
                    ShipImage.BackColor = SystemColors.Control;
                }
                AlreadyRandomizedShips.Add(ThisShip.ID);
            }
            else
            {
                ShipLoaded = false;
            }
        }