Example #1
0
        public Minigun(Player owner)
            : base(owner)
        {
            Damage = -15;

            Game.Sounds.Prepare(ref SFX_Shoot, "PistolShot", 100, 0.5f);
        }
Example #2
0
        public Bullet(Player owner, Vector direction, double damage)
            : base(Sorting.Group, "Bullets", 3)
        {
            Shape = new CircleShape(BodyRadius, 3);
            Shape.FillColor = BodyColor;
            Shape.Origin = new Vector2f(BodyRadius, BodyRadius);

            Direction = direction;
            Position = owner.Position + direction * Player.BodyRadius;
            Damage = damage;
        }
Example #3
0
        public Flame(Player owner, Vector direction, double damage)
            : base(Sorting.Group, "Flames", 0)
        {
            Owner = owner;
            BodyShape = new CircleShape(BodyRadius, 5);
            BodyShape.FillColor = BodyColor;
            BodyShape.Origin = new Vector2f(BodyRadius, BodyRadius);

            Direction = direction;
            Position = owner.Position + direction * Player.BodyRadius;
            Damage = damage;

            Game.Sounds.Prepare(ref SFX_FireLoop, "Campfire");
        }
Example #4
0
 public Flamer(Player owner)
     : base(owner)
 {
     Damage = -0.5;
     Game.Sounds.Prepare(ref SFX_Shoot, "LargeFireball", 25);
 }
Example #5
0
 private void ApplyEffect(Player player)
 {
     switch (Type)
     {
         case PowerupType.Health:
             player.OffsetHealth(Amount);
             break;
         default:
             break;
     }
 }
Example #6
0
 public Weapon(Player owner)
 {
     Owner = owner;
 }