Exemplo n.º 1
0
        public AntiAirCannon(IPoorWeaponHolder owner)
            : base(owner)
        {
            firstBurst = true;
            bulletsThisBurst = 0;
            _burstTimer = new Stopwatch();
            _burstTimer.Start();

            _muzzleFlashBig = new MuzzleFlashBig(EngineManager.Game, 4);
            EngineManager.Game.Components.Add(_muzzleFlashBig);
            _muzzleFlash = new MuzzleFlash(EngineManager.Game, 4);
            EngineManager.Game.Components.Add(_muzzleFlash);

            setGunLength(45f);

            /*
            gunOffset = new Vector2[4];
            gunOffset[0] = new Vector2(0, -3);
            gunOffset[1] = new Vector2(-3, 0);
            gunOffset[2] = new Vector2(-6, 3);
            gunOffset[3] = new Vector2(3, -6);
            GunLength = 45f;
            */
        }
Exemplo n.º 2
0
 public override void Initialize()
 {
     base.Initialize();
     _explosionParticles = new ExplosionParticleSystem(EngineManager.Game, 3);
     _groundExplosion = new GroundExplosion(EngineManager.Game, 8);
     _projectileHit = new ProjectileHit(EngineManager.Game, 5);
     _shrapnelExplosion = new ShrapnelExplosion(EngineManager.Game, 3);
     _blackSmoke = new BlackSmoke(EngineManager.Game, 3);
     _whiteSmoke = new WhiteSmoke(EngineManager.Game, 3);
     _groundDust = new GroundDust(EngineManager.Game, 3);
     _muzzleFlash = new MuzzleFlash(EngineManager.Game, 3);
     _fire = new Fire(EngineManager.Game, 3);
     _explosionParticles.Initialize();
     _groundExplosion.Initialize();
     _projectileHit.Initialize();
     _shrapnelExplosion.Initialize();
     _blackSmoke.Initialize();
     _whiteSmoke.Initialize();
     _groundDust.Initialize();
     _muzzleFlash.Initialize();
     _fire.Initialize();
 }