Beispiel #1
0
 // ***************************************************************************
 // Clont Object
 public Visier Clone()
 {
     Visier v = new Visier( TypeId, Group, Name, Accuracy, Weight, Description, LocationBehavior.Clone() );
     v.Renderer = Renderer;
     v.RequiredLiquid = RequiredLiquid;
     return v;
 }
Beispiel #2
0
 // ***************************************************************************
 // Konstruktor
 public Weapon( Visier visier, Antrieb antrieb, Stabilisator stabilisator, Hauptteil hauptteil, int id, EGroup group, String name, float weight, string description, ILocationBehavior locationBehavior )
     : base(id, group, name, description, weight, locationBehavior)
 {
     this.Visier = visier;
     this.Antrieb = antrieb;
     this.Stabilisator = stabilisator;
     this.Hauptteil = hauptteil;
 }
Beispiel #3
0
 public void SetVisierIcon( Visier visier )
 {
     visierCraftingIcon = visier.CraftingItem;
 }
Beispiel #4
0
 private void DrawVisier( Microsoft.Xna.Framework.Graphics.SpriteBatch sb, Visier visier )
 {
     sb.DrawString( UIButton.FONT_DEFAULT, visier.Name, new Vector2( TEXT_PADDING + textX, TEXT_PADDING + textY ), Color.Black );
     sb.DrawString( UIButton.FONT_DEFAULT, "Accuracy: " + visier.Accuracy, new Vector2( TEXT_PADDING + textX, TEXT_PADDING + textY + TEXT_LINE_HEIGHT * 2 ), Color.Black );
     sb.DrawString( UIButton.FONT_DEFAULT, "Gewicht: " + visier.Weight, new Vector2( TEXT_PADDING + textX, TEXT_PADDING + textY + TEXT_LINE_HEIGHT * 3 ), Color.Black );
 }
Beispiel #5
0
        private void DrawVisier(Microsoft.Xna.Framework.Graphics.SpriteBatch sb, Visier visier)
        {
            int x = (int)(GetPosition().X);
            int y = (int)(GetPosition().Y);

            sb.DrawString(UIButton.FONT_DEFAULT, visier.Name, new Vector2(padding + x, padding + y), Color.Black);
            sb.DrawString(UIButton.FONT_DEFAULT, "Accuracy: " + visier.Accuracy, new Vector2(padding + x, padding + y + lineHeight), Color.Black);
            sb.DrawString(UIButton.FONT_DEFAULT, "Gewicht: " + visier.Weight, new Vector2(padding + x, padding + y + lineHeight * 2), Color.Black);
        }
Beispiel #6
0
        public void SetVisier(Visier newVisier)
        {
            DecrimentRequired(Visier);
            IncrementRequired(newVisier);

            Visier = newVisier;
            visierButton.BackgroundTextur = newVisier.Icon;
            visierButton.BackgroundColor = Color.White;
            weaponPanel.SetVisierIcon(newVisier);
            accuracyButton.Text = accuracy + GetTotalAccuracy();
        }
Beispiel #7
0
        public void ResetPanel()
        {
            var pixel = Main.ContentManager.Load<Texture2D>("images/pixelTransparent");

            weaponPanel.ResetPanel();
            nameButton.Text = "Name der Waffe";
            antriebButton.BackgroundTextur = pixel;
            stabilisatorButton.BackgroundTextur = pixel;
            visierButton.BackgroundTextur = pixel;

            demageButton.Text = demage;
            accuracyButton.Text = accuracy;
            rateOfFireButton.Text = rateOfFire;

            Hauptteil = null;
            Antrieb = null;
            Stabilisator = null;
            Visier = null;

            bar1.Required = 0;
            bar2.Required = 0;
            bar3.Required = 0;

            bar1.Progress = player.Liquids.X;
            bar2.Progress = player.Liquids.Y;
            bar3.Progress = player.Liquids.Z;
        }