Exemplo n.º 1
0
 /// <summary>
 /// Create and spawn the projectile(s) from a firing from this weapon.
 /// </summary>
 /// <param name="direction">The direction that the projectile will move.</param>
 protected override void CreateProjectiles(Vector2 direction)
 {
     // create the new projectile
     MineProjectile projectile = new MineProjectile(owner.World, owner,
         direction);
     // move the mine out from the ship
     projectile.Position = owner.Position +
         direction * (owner.Radius + projectile.Radius + mineSpawnDistance);
     // spawn the projectile
     projectile.Spawn(false);
 }
Exemplo n.º 2
0
        /// <summary>
        /// Create and spawn the projectile(s) from a firing from this weapon.
        /// </summary>
        /// <param name="direction">The direction that the projectile will move.</param>
        protected override void CreateProjectiles(Vector2 direction)
        {
            // create the new projectile
            MineProjectile projectile = new MineProjectile(owner.World, owner,
                                                           direction);

            // move the mine out from the ship
            projectile.Position = owner.Position +
                                  direction * (owner.Radius + projectile.Radius + mineSpawnDistance);
            // spawn the projectile
            projectile.Spawn(false);
        }