using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework;
using ShootingHero.Components.Bullets.BossBullet;

namespace ShootingHero.Components.Monsters.Bosses
{
	public class HugeSquirrel : Boss
	{
		static Texture2D texture;

		float shootAngle;

		public HugeSquirrel ( Game game, float timeUnit )
			: base ( game, timeUnit, 400 )
		{
			if ( texture == null || texture.IsDisposed )
				texture = Game.Content.Load<Texture2D> ( "Boss/squirrel" );
			Texture = texture;
			TadaPosition = 120;
			Width = texture.Height / 2 - 40;
			Timer.Delay = 100;
		}

		protected override void ShootBullet ( Manager.BulletManager bulletManager )
		{
			bulletManager.Add ( new SquirrelBullet ( Game, X, Y, shootAngle ) );
			bulletManager.Add ( new SquirrelBullet ( Game, X, Y, shootAngle + 3.141592f / 2 ) );
			bulletManager.Add ( new SquirrelBullet ( Game, X, Y, shootAngle + 3.141592f ) );
			bulletManager.Add ( new SquirrelBullet ( Game, X, Y, shootAngle + 3.141592f + 3.141592f / 2 ) );
		}

		protected override void MoveLogic ( GameTime gameTime )
		{

		}

		public override void Update ( GameTime gameTime )
		{
			shootAngle += gameTime.ElapsedGameTime.Milliseconds / 500.0f;
			base.Update ( gameTime );
		}
	}
}
