Beispiel #1
0
 /// <summary>
 /// Claims the territory.
 /// </summary>
 /// <param name="territoryList">Territory list.</param>
 /// <param name="account">Current Account.</param>
 /// <param name="entityRegionPos">Entity region position.</param>
 /// <param name="regionMan">Region man.</param>
 public void ClaimTerritory(HashSet<PositionI> territoryList, Account account, RegionPosition entityRegionPos, RegionManager regionMan)
 {
     foreach (var position in territoryList)
     {
         if (!regionMan.GetRegion(position.RegionPosition).m_territory.ContainsKey(position))
         {
             regionMan.GetRegion(position.RegionPosition).m_territory.Add(position, account);
         }
     }
 }
Beispiel #2
0
 /// <summary>
 /// Claims the territory.
 /// </summary>
 /// <param name="territoryList">Territory list.</param>
 /// <param name="account">Current Account.</param>
 /// <param name="entityRegionPos">Entity region position.</param>
 /// <param name="regionMan">Region man.</param>
 public void ClaimTerritory(HashSet <PositionI> territoryList, Account account, RegionPosition entityRegionPos, RegionManager regionMan)
 {
     foreach (var position in territoryList)
     {
         if (!regionMan.GetRegion(position.RegionPosition).m_territory.ContainsKey(position))
         {
             regionMan.GetRegion(position.RegionPosition).m_territory.Add(position, account);
         }
     }
 }
Beispiel #3
0
 /// <summary>
 /// Prevents a default instance of the <see cref="Core.Models.World"/> class from being created.
 /// </summary>
 private World()
 {
     RegionManager = new RegionManager();
     DefinitionManager = new DefinitionManager();
     AccountManager = new AccountManager();
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="Core.Controllers.RegionManagerController"/> class.
 /// </summary>
 public RegionManagerController()
 {
     m_regionManager = World.Instance.RegionManager;
 }