Exemplo n.º 1
0
 internal void InitPrefabs(PrefabCollection prefabsCollection)
 {
     foreach (var item in this)
     {
         Dictionary <int, int> prefabs = prefabsCollection.ToDictionary(a => a.Key, a => a.Value.Count);
         var p = new PrefabLimitNotifier(prefabs);
         item.Value.PrefabLimitNotifier = p;
         p.CountChanged += new EventHandler <(int key, int count)>((o, e) => this.PrefabCountChanged?.Invoke(this, (item.Key, e.key, e.count)));
     }
 }