public override void Attack(Entity holder, Vector position, Vector direction)
        {
            Projectile projectile;

            if (ProjectileSpawner.AnimationBasedProjectile(holder, Holder, out projectile))
            {
            }
        }
Example #2
0
        public override void Attack(Entity holder, Vector position, Vector direction)
        {
            Projectile projectile;

            if (ProjectileSpawner.AnimationBasedProjectile(holder, Holder, out projectile))
            {
                if (holder.Name == "Enemy")
                {
                    if (direction.X > 0)
                    {
                        holder.GetComponent <Sprite>().SpriteEffects = SpriteEffects.None;
                    }
                    else
                    {
                        holder.GetComponent <Sprite>().SpriteEffects = SpriteEffects.FlipHorizontally;
                    }
                }
            }
        }