private void AddUnitsToArea(Area area, Units.UnitType unitType, int number) { if (area.units.unallocated[unitType] == null) { area.units.unallocated[unitType] = Units.NewUnitGroup(unitType, number); } else { var unitGroup = area.units.unallocated[unitType]; unitGroup.number += number; } }
public UnitGroup(Units.UnitType type, int number, int tier) : base() { this.type = (int)type; this.number = number; this.tier = tier; }