Esempio n. 1
0
        /* Fire a new Projectile*/
        public override Projectile FireProjectile(Vector2 position)
        {
            projectileTexture = textureManager.Instance.useTexture("novaBall");
            soundManager.Instance.PlaySound("novaShot");

            Projectile bullet = new nova(projectileTexture,
                    new Vector2(projectileTexture.Width / 2, projectileTexture.Height / 2),
                    new Vector2(position.X, position.Y - 32),
                    new Rectangle(0, 0, projectileTexture.Width, projectileTexture.Height));            

            if (bullet != null)
            {
                return bullet;
            }

            return null;
        }
Esempio n. 2
0
        /* Fire a new Projectile*/
        public override Projectile FireProjectile(Vector2 position)
        {
            projectileTexture = textureManager.Instance.useTexture("novaBall");
            soundManager.Instance.PlaySound("novaShot");

            Projectile bullet = new nova(projectileTexture,
                                         new Vector2(projectileTexture.Width / 2, projectileTexture.Height / 2),
                                         new Vector2(position.X, position.Y - 32),
                                         new Rectangle(0, 0, projectileTexture.Width, projectileTexture.Height));

            if (bullet != null)
            {
                return(bullet);
            }

            return(null);
        }