Exemplo n.º 1
0
 public void PostDeserialize(ProjectManager sender)
 {
     m_manager = sender;
     if (TileTypes == null)
     {
         TileTypes = new ObservableCollection<TileType>();
     }
     foreach (var tileType in TileTypes)
     {
         tileType.PostDeserialize(sender);
     }
     if (TileUnitPlacements == null)
     {
         TileUnitPlacements = new ObservableCollection<TileUnitPlacement>();
     }
     foreach (var tileUnitPlacement in TileUnitPlacements)
     {
         tileUnitPlacement.PostDeserialize(sender);
     }
     if (TileContents == null)
     {
         TileContents = new ObservableCollection<TileContent>();
     }
     foreach (var tileContent in TileContents)
     {
         tileContent.PostDeserialize(sender);
     }
     if (Scenarios == null)
     {
         Scenarios = new ObservableCollection<Scenario>();
     }
     foreach (var scenario in Scenarios)
     {
         scenario.PostDeserialize(sender);
     }
     SortTileTypes();
 }
Exemplo n.º 2
0
 public virtual void PostDeserialize(ProjectManager sender)
 {
     m_manager = sender;
 }
Exemplo n.º 3
0
 public void PostDeserialize(ProjectManager sender)
 {
     m_manager = sender;
     m_initialized = true;
     foreach (var tileType in m_manager.CurrentCampaign.TileTypes)
     {
         if (tileType.Name.Equals(m_tileTypeKey))
         {
             Tile = tileType;
             break;
         }
     }
     foreach (var unitPlacement in m_manager.CurrentCampaign.TileUnitPlacements)
     {
         if (unitPlacement.Name.Equals(m_unitPlacementKey))
         {
             UnitPlacement = unitPlacement;
             break;
         }
     }
     foreach (var tileContent in m_manager.CurrentCampaign.TileContents)
     {
         if (tileContent.Name.Equals(m_tileContentKey))
         {
             Content = tileContent;
             break;
         }
     }
 }
Exemplo n.º 4
0
 public void PostDeserialize(ProjectManager sender)
 {
     m_manager = sender;
     if (TileSlots == null)
     {
         TileSlots = new ObservableCollection<TileSlot>();
     }
     foreach (var tileSlot in TileSlots)
     {
         tileSlot.PostDeserialize(sender);
     }
     NotifyPropertyChanged("TileSlotGridHeight");
     NotifyPropertyChanged("TileSlotGridWidth");
 }
Exemplo n.º 5
0
 private void InitializeMembers()
 {
     m_projectManager = new ProjectManager();
     DataContext = m_projectManager;
 }