private void InnerSettlementGenThread(Kingdom k, SettlementGenerator g) { Dictionary <Settlement, Dictionary <Vec2i, ChunkData> > dc = g.GenerateAllSettlements(); lock (ThreadComplete) { ThreadComplete.Add(dc); } foreach (KeyValuePair <Settlement, Dictionary <Vec2i, ChunkData> > kpv in dc) { k.AddSettlement(kpv.Key); //kpv.Key.SetKingdomID(k.KingdomID); } }