Exemplo n.º 1
0
        private void Shoot()
        {
            GeneralTransform objGeneralTransform = BulletOrigin.TransformToVisual(Application.Current.RootVisual);

            Bullet bullet = new Bullet(Bullet(), 180 - ProjectoryAngle, objGeneralTransform.Transform(new Point(0, 0)), this.ImpactDamage, ttLive);

            bullet.Position += BulletProjectory();
            if (CollisionTargets != null)
            {
                bullet.AddCollisionTargets(CollisionTargets);
            }
            BulletEngine.Add <Bullet>(bullet);

            _bulletLastFired = DateTime.Now;
        }