using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
using StrategicCombat.Maps;
using StrategicCombat.CombatUnits;

namespace StrategicCombat.Teams
{
    /// <summary>
    /// This class represent a team.
    /// </summary>
    public class Team
    {
        #region Variables

        public List<CombatUnit> combatUnits;

        #endregion

        #region Constructors

        public Team()
        {
            // Nothing here yet.
        }

        #endregion

        #region Methods

        /// <summary>
        /// Update the team on the board.
        /// </summary>
        /// <param name="gameTime"></param>
        /// <param name="currentMap"></param>
        public void UpdateTeamOnBoard(GameTime gameTime, Map currentMap)
        {
            foreach (CombatUnit combatUnit in this.combatUnits)
            {
                // Update the combat unit on the board
                combatUnit.UpdateOnBoard(currentMap);

            }

        } // End of the UpdateTeamOnBoard method

        /// <summary>
        /// Draw the team on the board.
        /// </summary>
        /// <param name="spriteBatch"></param>
        public void DrawTeamOnBoard(SpriteBatch spriteBatch)
        {
            foreach (CombatUnit combatUnit in this.combatUnits)
            {
                // Draw the combat unit on the board
                combatUnit.DrawOnBoard(spriteBatch); 

            }

        } // End of the DrawTeamOnBoard method.

        #endregion

    } // End of class

} // End of namespace
