public StandardPlayer(Texture2D playerTexture, Texture2D bulletTexture, Keybindings keys) : base(playerTexture, new Color(40, 200, 40), Battle.BattleManager.PlayerBounds.Center, Scale * RadiusPerScale, keys, Battle.BattleManager.BulletBounds, VelocityFocused, 150, VelocityFocused * 0.03F, Scale) { BulletSpawners.Add(new BulletSpawner(a => { return(new Bullet(bulletTexture, BulletColor, BulletRadius, Position, Utils.VectorFromSize(BulletSpeed, Math.PI * 1.5), new Vector2(0, 0), BulletScale, (float)Math.PI * 2.0F)); }, Bullets, BulletsHowOften)); BulletSpawners.Add(new BulletSpawner(a => { return(new Bullet(bulletTexture, BulletColor, BulletRadius, Position, Utils.VectorFromSize(BulletSpeed, Math.PI * 1.55), new Vector2(0, 0), BulletScale, (float)Math.PI * 2.05F)); }, Bullets, BulletsHowOften)); BulletSpawners.Add(new BulletSpawner(a => { return(new Bullet(bulletTexture, BulletColor, BulletRadius, Position, Utils.VectorFromSize(BulletSpeed, Math.PI * 1.45), new Vector2(0, 0), BulletScale, (float)Math.PI * 1.95F)); }, Bullets, BulletsHowOften)); BulletSpawners.Add(new BulletSpawner(a => { return(new Bullet(bulletTexture, BulletColor, BulletRadius, Position, Utils.VectorFromSize(BulletSpeed, Math.PI * 1.40), new Vector2(0, 0), BulletScale, (float)Math.PI * 1.90F)); }, Bullets, BulletsHowOften)); BulletSpawners.Add(new BulletSpawner(a => { return(new Bullet(bulletTexture, BulletColor, BulletRadius, Position, Utils.VectorFromSize(BulletSpeed, Math.PI * 1.60), new Vector2(0, 0), BulletScale, (float)Math.PI * 2.1F)); }, Bullets, BulletsHowOften)); }
public Player(Texture2D texture, Color color, Vector2 position, float radius, Keybindings bindings, RectangleF bulletDestroyBounds, float movementVelocityUnfocused, float movementVelocityFocused, float angularVelocity, float scale = DefaultScale, float rotation = DefaultRotation) : base(texture, position, radius, scale, rotation, false) { Bullets = new BulletGroup(bulletDestroyBounds); BulletSpawners = new List <BulletSpawner>(); _angularVelocity = angularVelocity; Bindings = bindings; _movementVelocityUnfocusedSize = movementVelocityUnfocused; _movementVelocityFocusedSize = movementVelocityFocused; Sprite.Color = color; }