public void AddUnit(UnitBase unit) { _army.Add(unit); }
public void MoveUnit(UnitBase unit, int y, int x) { _army.Move(unit, y, x); }
public Army(params IUnit[] units) { _units = units.ToDictionary(o => UnitBase.GetPositionKey(o.Y, o.X)); }
public void ApplyDamage(UnitBase unit, int damageValue) { unit.ApplyDamage(damageValue); }
public void Remove(IUnit unit) { var key = UnitBase.GetPositionKey(unit.Y, unit.X); _units.Remove(key); }