Ejemplo n.º 1
0
        /// <summary>
        /// Gets a barbarian from the village.
        /// </summary>
        /// <returns></returns>
        private static Barbarian GetBarbarian(Unit explorer)
        {
            GameRoot  root        = GameRoot.Instance;
            UnitBase  baseUnit    = root.Ruleset.Units[0];
            Point     coordinates = explorer.Coordinates;
            GridCell  cell        = root.Grid.GetCell(coordinates);
            GridCell  location    = cell.FindClosestEmptyLandCell();
            Barbarian b           = new Barbarian(location.Coordinates, baseUnit);

            return(b);
        }
Ejemplo n.º 2
0
 /// <summary>
 /// Initializes a new instance of the <c>BarbarianGoody</c> class.
 /// </summary>
 /// <param name="tribeName"></param>
 /// <param name="enemy"></param>
 public BarbarianGoody(string tribeName, Barbarian enemy) : base(tribeName)
 {
     this.barbarian = enemy;
 }