-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathMainWindow.xaml.vb
More file actions
2476 lines (2190 loc) · 126 KB
/
Copy pathMainWindow.xaml.vb
File metadata and controls
2476 lines (2190 loc) · 126 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
'--- DNA Keycards Economy Editor
'-- ------------------------------------------------------------------------------------------
'--
'-- This Is free software, And you are welcome to redistribute it with certain conditions.
'--
'-- --------------------- Creative Commons Attribution-NonCommercial-ShareAlike 3.0 IGO License ------------------------------------
'-
'--This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 3.0 IGO License.
'-To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/3.0/igo/
'
'or
'
'-send a letter to Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
'
'--
'-- This program Is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
'-- without even the implied warranty of MERCHANTABILITY Or FITNESS FOR A PARTICULAR PURPOSE.
'--
'-Any person or entity obtaining any Syncfusion code, licensed assemblies, Or dependencies As a result Of the Open Source Project must
'-obtain their own licensed copy Of the Licensed Product from Syncfusion.
'--
'-- You should have received a copy of the Creative Commons Attribution-NonCommercial-ShareAlike 3.0 IGO License in the downloaded program folder.
'--
'-- Copyright (C) 2023 Gh0st - This program comes with ABSOLUTELY NO WARRANTY
'-- ------------------------------------------------------------------------------------------
Imports System
Imports System.Collections.Generic
Imports System.Collections.ObjectModel
Imports System.Linq
Imports System.Text
Imports System.Windows
Imports System.Windows.Controls
Imports System.Windows.Data
Imports System.Windows.Documents
Imports System.Windows.Input
Imports System.Windows.Media
Imports System.Windows.Media.Imaging
Imports System.Windows.Navigation
Imports System.Windows.Shapes
Imports Syncfusion.SfSkinManager
Imports Syncfusion.Windows.Shared
Imports System.Threading.Tasks
Imports Microsoft.Win32
Imports System.Windows.Threading
Imports DNA_Keycard_Editor.Classes
Imports System.IO
Imports System.Reflection
Imports System.Text.RegularExpressions
Imports System.Windows.Forms
Imports Syncfusion.UI.Xaml.Grid
Imports Newtonsoft.Json
Imports Syncfusion.UI.Xaml.TreeGrid
Imports Syncfusion.Data
Imports Syncfusion.UI.Xaml.TreeView
Imports Syncfusion.UI.Xaml.TreeView.Engine
Imports Syncfusion.Windows.Controls.Input
Imports Syncfusion.Windows.Tools.Controls
''' <summary>
''' Interaction logic for MainWindow.xaml
''' </summary>
Partial Public Class MainWindow
Inherits ChromelessWindow
Private currentVisualStyle As String
Private currentSizeMode As String
Private random As New Random()
''' <summary>
''' Property for Visual Style
'''</summary>
Public Property CurrentVisualStyleProperty As String
Get
Return currentVisualStyle
End Get
Set(ByVal value As String)
currentVisualStyle = value
OnVisualStyleChanged()
End Set
End Property
''' <summary>
''' Property for Size Mode
'''</summary>
Public Property CurrentSizeModeProperty As String
Get
Return currentSizeMode
End Get
Set(ByVal value As String)
currentSizeMode = value
OnSizeModeChanged()
End Set
End Property
Public Sub New()
InitializeComponent()
AddHandler Me.Loaded, AddressOf OnLoaded
seedItemSources()
seedWeaponKitSettings()
seedHandlers()
End Sub
''' <summary>
''' Method for onload
'''</summary>
Private Sub OnLoaded(ByVal sender As Object, ByVal e As RoutedEventArgs)
CurrentVisualStyleProperty = "Windows11Dark"
CurrentSizeModeProperty = "Default"
End Sub
''' <summary>
''' Method for Visual Style
'''</summary>
Private Sub OnVisualStyleChanged()
Dim visualStyle As VisualStyles = VisualStyles.[Default]
[Enum].TryParse(CurrentVisualStyleProperty, visualStyle)
If visualStyle <> VisualStyles.[Default] Then
SfSkinManager.ApplyStylesOnApplication = True
SfSkinManager.SetVisualStyle(Me, visualStyle)
SfSkinManager.ApplyStylesOnApplication = False
End If
End Sub
''' <summary>
''' Method for Size Mode
'''</summary>
Private Sub OnSizeModeChanged()
Dim sizeMode As Syncfusion.SfSkinManager.SizeMode = Syncfusion.SfSkinManager.SizeMode.[Default]
[Enum].TryParse(CurrentSizeModeProperty, sizeMode)
If sizeMode <> Syncfusion.SfSkinManager.SizeMode.[Default] Then
SfSkinManager.ApplyStylesOnApplication = True
SfSkinManager.SetSizeMode(Me, sizeMode)
SfSkinManager.ApplyStylesOnApplication = False
End If
End Sub
Private Async Sub B_ImportTypes_Click(sender As Object, e As RoutedEventArgs) Handles B_ImportTypes.Click
Dim results As String() = Await FileSelectionHelper.SelectMultipleFilesAsync()
For Each resultPath As String In results
Dim temp As New GlobalVariables.Types.File(resultPath, IO.Path.GetFileName(resultPath), "types")
GlobalVariables.Types.TypeFiles.Add(temp)
Dim results2 = Await FileSelectionHelper.LoadDataFromXml(resultPath)
Next
End Sub
Private Sub Kit_ColorChoice_SelectionChanged(sender As Object, e As Windows.Controls.SelectionChangedEventArgs) _
Handles Kit_ColorChoice.SelectionChanged
Dim SelectedItems = e.AddedItems
Dim SelectedText = SelectedItems.Item(0).Content
Select Case SelectedText
Case "Red Kit"
SetGridBackgroundColor(G_KitType, 131, 14, 14, 30)
SetGridBackgroundColor(G_ClothesSettings, 131, 14, 14, 30)
SetGridBackgroundColor(G_LootSettings, 131, 14, 14, 30)
Case "Purple Kit"
SetGridBackgroundColor(G_KitType, 238, 51, 229, 20)
SetGridBackgroundColor(G_ClothesSettings, 238, 51, 229, 20)
SetGridBackgroundColor(G_LootSettings, 238, 51, 229, 20)
Case "Blue Kit"
SetGridBackgroundColor(G_KitType, 48, 67, 225, 20)
SetGridBackgroundColor(G_ClothesSettings, 48, 67, 225, 20)
SetGridBackgroundColor(G_LootSettings, 48, 67, 225, 20)
Case "Green Kit"
SetGridBackgroundColor(G_KitType, 80, 255, 71, 20)
SetGridBackgroundColor(G_ClothesSettings, 80, 255, 71, 20)
SetGridBackgroundColor(G_LootSettings, 80, 255, 71, 20)
Case "Yellow Kit"
SetGridBackgroundColor(G_KitType, 255, 243, 0, 30)
SetGridBackgroundColor(G_ClothesSettings, 255, 243, 0, 30)
SetGridBackgroundColor(G_LootSettings, 255, 243, 0, 30)
Case Else
SetGridBackgroundColor(G_KitType, 83, 83, 83, 20)
SetGridBackgroundColor(G_ClothesSettings, 83, 83, 83, 20)
SetGridBackgroundColor(G_LootSettings, 83, 83, 83, 20)
End Select
End Sub
Public Sub SetGridBackgroundColor(grid As Grid, r As Byte, g As Byte, b As Byte, alpha As Byte)
Dim color As Color = Color.FromArgb(alpha, r, g, b)
Dim brush As New SolidColorBrush(color)
grid.Background = brush
End Sub
Private Async Function DragImportExpansionMarket(resultPath As String, sender As SfTextBoxExt) As Task
Dim foundTypes As List(Of String)
foundTypes = New List(Of String)()
foundTypes = Await FileSelectionHelper.GetUniqueClassnamesAndVariants(resultPath) _
'.Add(FileSelectionHelper.GetUniqueClassnamesAndVariants(resultPath))
foundTypes = Await FileSelectionHelper.RemoveDuplicates(foundTypes)
Select Case True
'dna_Helm
Case sender Is Clothes_Helmets
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Helmets)
UpdateTextBoxWithStrings(Clothes_Helmets, GlobalVariables.ClothingMarket.Helmets)
'dna_Shirt
Case sender Is Clothes_Shirts
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Shirts)
UpdateTextBoxWithStrings(Clothes_Shirts, GlobalVariables.ClothingMarket.Shirts)
'dna_Vest
Case sender Is Clothes_Vests
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Vests)
UpdateTextBoxWithStrings(Clothes_Vests, GlobalVariables.ClothingMarket.Vests)
'dna_Pants
Case sender Is Clothes_Pants
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Pants)
UpdateTextBoxWithStrings(Clothes_Pants, GlobalVariables.ClothingMarket.Pants)
'dna_Shoes
Case sender Is Clothes_Shoes
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Shoes)
UpdateTextBoxWithStrings(Clothes_Shoes, GlobalVariables.ClothingMarket.Shoes)
'dna_Backpack
Case sender Is Clothes_Backpacks
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Backpacks)
UpdateTextBoxWithStrings(Clothes_Backpacks, GlobalVariables.ClothingMarket.Backpacks)
'dna_Gloves
Case sender Is Clothes_Gloves
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Gloves)
UpdateTextBoxWithStrings(Clothes_Gloves, GlobalVariables.ClothingMarket.Gloves)
'dna_Belt
Case sender Is Clothes_Belts
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Belts)
UpdateTextBoxWithStrings(Clothes_Belts, GlobalVariables.ClothingMarket.Belts)
'dna_Facewear
Case sender Is Clothes_Facewear
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Facewears)
UpdateTextBoxWithStrings(Clothes_Facewear, GlobalVariables.ClothingMarket.Facewears)
'dna_Eyewear
Case sender Is Clothes_Eyewear
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Eyewears)
UpdateTextBoxWithStrings(Clothes_Eyewear, GlobalVariables.ClothingMarket.Eyewears)
'dna_Armband
Case sender Is Clothes_Armbands
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Armbands)
UpdateTextBoxWithStrings(Clothes_Armbands, GlobalVariables.ClothingMarket.Armbands)
End Select
End Function
Private Async Sub ButtonImportExpansionMarketClick(sender As Object, e As RoutedEventArgs) _
Handles Kits_ImportRestricted.Click, Clothes_Helmets_Import.Click, Clothes_Pants_Import.Click,
Clothes_Gloves_Import.Click, Clothes_Eyewear_Import.Click, Clothes_Shirts_Import.Click,
Clothes_Shoes_Import.Click, Clothes_Belts_Import.Click, Clothes_Armbands_Import.Click,
Clothes_Vests_Import.Click, Clothes_Backpacks_Import.Click, Clothes_Facewear_Import.Click, Loot_proprietary_Import.Click, Loot_medical_Import.Click, Loot_food_Import.Click, Loot_drink_Import.Click, Loot_tools_Import.Click, Loot_material_Import.Click, Loot_misc_Import.Click, Loot_valuable_Import.Click
Dim results As String() = Await FileSelectionHelper.SelectMultipleFilesAsync()
Dim foundTypes As List(Of String)
For Each resultPath As String In results
foundTypes = New List(Of String)()
foundTypes = Await FileSelectionHelper.GetUniqueClassnamesAndVariants(resultPath) _
'.Add(FileSelectionHelper.GetUniqueClassnamesAndVariants(resultPath))
foundTypes = Await FileSelectionHelper.RemoveDuplicates(foundTypes)
Select Case True
'Sidearms
Case sender Is Kits_ImportSidearm
AddMissingTypes(foundTypes, GlobalVariables.SideArms)
UpdateTextBoxWithStrings(Kits_SideArms, GlobalVariables.SideArms)
'Restricted
Case sender Is Kits_ImportRestricted
AddMissingTypes(foundTypes, GlobalVariables.RestrictedTypes)
UpdateTextBoxWithStrings(Kits_Restricted, GlobalVariables.RestrictedTypes)
'Clothing Market
'dna_Helm
Case sender Is Clothes_Helmets_Import
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Helmets)
UpdateTextBoxWithStrings(Clothes_Helmets, GlobalVariables.ClothingMarket.Helmets)
'dna_Shirt
Case sender Is Clothes_Shirts_Import
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Shirts)
UpdateTextBoxWithStrings(Clothes_Shirts, GlobalVariables.ClothingMarket.Shirts)
'dna_Vest
Case sender Is Clothes_Vests_Import
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Vests)
UpdateTextBoxWithStrings(Clothes_Vests, GlobalVariables.ClothingMarket.Vests)
'dna_Pants
Case sender Is Clothes_Pants_Import
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Pants)
UpdateTextBoxWithStrings(Clothes_Pants, GlobalVariables.ClothingMarket.Pants)
'dna_Shoes
Case sender Is Clothes_Shoes_Import
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Shoes)
UpdateTextBoxWithStrings(Clothes_Shoes, GlobalVariables.ClothingMarket.Shoes)
'dna_Backpack
Case sender Is Clothes_Backpacks_Import
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Backpacks)
UpdateTextBoxWithStrings(Clothes_Backpacks, GlobalVariables.ClothingMarket.Backpacks)
'dna_Gloves
Case sender Is Clothes_Gloves_Import
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Gloves)
UpdateTextBoxWithStrings(Clothes_Gloves, GlobalVariables.ClothingMarket.Gloves)
'dna_Belt
Case sender Is Clothes_Belts_Import
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Belts)
UpdateTextBoxWithStrings(Clothes_Belts, GlobalVariables.ClothingMarket.Belts)
'dna_Facewear
Case sender Is Clothes_Facewear_Import
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Facewears)
UpdateTextBoxWithStrings(Clothes_Facewear, GlobalVariables.ClothingMarket.Facewears)
'dna_Eyewear
Case sender Is Clothes_Eyewear_Import
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Eyewears)
UpdateTextBoxWithStrings(Clothes_Eyewear, GlobalVariables.ClothingMarket.Eyewears)
'dna_Armband
Case sender Is Clothes_Armbands_Import
AddMissingTypes(foundTypes, GlobalVariables.ClothingMarket.Armbands)
UpdateTextBoxWithStrings(Clothes_Armbands, GlobalVariables.ClothingMarket.Armbands)
'Loot Market
Case sender Is Loot_proprietary_Import
AddMissingTypes(foundTypes, GlobalVariables.LootMarket.proprietary)
UpdateTextBoxWithStrings(Loot_proprietary, GlobalVariables.LootMarket.proprietary)
Case sender Is Loot_medical_Import
AddMissingTypes(foundTypes, GlobalVariables.LootMarket.medical)
UpdateTextBoxWithStrings(Loot_medical, GlobalVariables.LootMarket.medical)
Case sender Is Loot_food_Import
AddMissingTypes(foundTypes, GlobalVariables.LootMarket.food)
UpdateTextBoxWithStrings(Loot_food, GlobalVariables.LootMarket.food)
Case sender Is Loot_drink_Import
AddMissingTypes(foundTypes, GlobalVariables.LootMarket.drink)
UpdateTextBoxWithStrings(Loot_drink, GlobalVariables.LootMarket.drink)
Case sender Is Loot_tools_Import
AddMissingTypes(foundTypes, GlobalVariables.LootMarket.tools)
UpdateTextBoxWithStrings(Loot_tools, GlobalVariables.LootMarket.tools)
Case sender Is Loot_material_Import
AddMissingTypes(foundTypes, GlobalVariables.LootMarket.material)
UpdateTextBoxWithStrings(Loot_material, GlobalVariables.LootMarket.material)
Case sender Is Loot_misc_Import
AddMissingTypes(foundTypes, GlobalVariables.LootMarket.misc)
UpdateTextBoxWithStrings(Loot_misc, GlobalVariables.LootMarket.misc)
Case sender Is Loot_valuable_Import
AddMissingTypes(foundTypes, GlobalVariables.LootMarket.valuable)
UpdateTextBoxWithStrings(Loot_valuable, GlobalVariables.LootMarket.valuable)
End Select
Next
End Sub
Sub AddMissingTypes(foundTypes As List(Of String), collect_ As ObservableCollection(Of String))
Dim uniqueTypes As HashSet(Of String) = New HashSet(Of String)(collect_)
For Each item In foundTypes
If Not uniqueTypes.Contains(item) Then
uniqueTypes.Add(item)
End If
Next
collect_.Clear()
For Each item In uniqueTypes
collect_.Add(item)
Next
End Sub
Public Sub UpdateTextBoxWithStrings(textBox As SfTextBoxExt, strings As ObservableCollection(Of String))
textBox.Clear() ' Clear the existing contents of the textbox
For Each str As String In strings
textBox.Text += str & Environment.NewLine ' Append each string followed by a new line character
Next
End Sub
Public Sub UpdateGlobalsWithTextBox(textBox As SfTextBoxExt, strings As ObservableCollection(Of String))
strings.Clear() ' Clear the existing strings in the collection
Dim lines() As String = textBox.Text.Split({Environment.NewLine}, StringSplitOptions.RemoveEmptyEntries)
For Each line As String In lines
strings.Add(line) ' Add each line as a string to the collection
Next
End Sub
Private Sub ClearTB_Click(sender As Object, e As RoutedEventArgs)
'Dim clickedButton As ButtonAdv = DirectCast(sender, ButtonAdv)
Select Case True
' Sidearms
Case sender Is Kits_ClearSidearms
GlobalVariables.SideArms.Clear()
Kits_SideArms.Clear()
' Restricted
Case sender Is Kits_ClearRestricted
GlobalVariables.RestrictedTypes.Clear()
Kits_Restricted.Clear()
' Clothing Market
Case sender Is Clothes_Helmets_Clear
GlobalVariables.ClothingMarket.Helmets.Clear()
Clothes_Helmets.Clear()
Case sender Is Clothes_Shirts_Clear
GlobalVariables.ClothingMarket.Shirts.Clear()
Clothes_Shirts.Clear()
Case sender Is Clothes_Vests_Clear
GlobalVariables.ClothingMarket.Vests.Clear()
Clothes_Vests.Clear()
Case sender Is Clothes_Pants_Clear
GlobalVariables.ClothingMarket.Pants.Clear()
Clothes_Pants.Clear()
Case sender Is Clothes_Shoes_Clear
GlobalVariables.ClothingMarket.Shoes.Clear()
Clothes_Shoes.Clear()
Case sender Is Clothes_Backpacks_Clear
GlobalVariables.ClothingMarket.Backpacks.Clear()
Clothes_Backpacks.Clear()
Case sender Is Clothes_Gloves_Clear
GlobalVariables.ClothingMarket.Gloves.Clear()
Clothes_Gloves.Clear()
Case sender Is Clothes_Belts_Clear
GlobalVariables.ClothingMarket.Belts.Clear()
Clothes_Belts.Clear()
Case sender Is Clothes_Facewear_Clear
GlobalVariables.ClothingMarket.Facewears.Clear()
Clothes_Facewear.Clear()
Case sender Is Clothes_Eyewear_Clear
GlobalVariables.ClothingMarket.Eyewears.Clear()
Clothes_Eyewear.Clear()
Case sender Is Clothes_Armbands_Clear
GlobalVariables.ClothingMarket.Armbands.Clear()
Clothes_Armbands.Clear()
' Loot Market
Case sender Is Loot_proprietary_Clear
GlobalVariables.LootMarket.proprietary.Clear()
Loot_proprietary.Clear()
Case sender Is Loot_medical_Clear
GlobalVariables.LootMarket.medical.Clear()
Loot_medical.Clear()
Case sender Is Loot_food_Clear
GlobalVariables.LootMarket.food.Clear()
Loot_food.Clear()
Case sender Is Loot_drink_Clear
GlobalVariables.LootMarket.drink.Clear()
Loot_drink.Clear()
Case sender Is Loot_tools_Clear
GlobalVariables.LootMarket.tools.Clear()
Loot_tools.Clear()
Case sender Is Loot_material_Clear
GlobalVariables.LootMarket.material.Clear()
Loot_material.Clear()
Case sender Is Loot_misc_Clear
GlobalVariables.LootMarket.misc.Clear()
Loot_misc.Clear()
Case sender Is Loot_valuable_Clear
GlobalVariables.LootMarket.valuable.Clear()
Loot_valuable.Clear()
End Select
End Sub
'Private Sub ClearTB_Click(sender As Object, e As RoutedEventArgs)
' 'GlobalVariables.SideArms.Clear()
' 'Kits_SideArms.Clear()
' Select Case True
' 'Sidearms
' Case sender Is Kits_ClearSidearms
' GlobalVariables.SideArms.Clear()
' Kits_SideArms.Clear()
' 'Restricted
' Case sender Is Kits_ClearRestricted
' GlobalVariables.RestrictedTypes.Clear()
' Kits_Restricted.Clear()
' 'Clothing Market
' 'dna_Helm
' Case sender Is Clothes_Helmets_Import
' GlobalVariables.ClothingMarket.Helmets.Clear()
' Clothes_Helmets.Clear()
' 'dna_Shirt
' Case sender Is Clothes_Shirts_Import
' GlobalVariables.ClothingMarket.Shirts.Clear()
' Clothes_Shirts.Clear()
' 'dna_Vest
' Case sender Is Clothes_Vests_Import
' GlobalVariables.ClothingMarket.Vests.Clear()
' Clothes_Vests.Clear()
' 'dna_Pants
' Case sender Is Clothes_Pants_Import
' GlobalVariables.ClothingMarket.Pants.Clear()
' Clothes_Pants.Clear()
' 'dna_Shoes
' Case sender Is Clothes_Shoes_Import
' GlobalVariables.ClothingMarket.Shoes.Clear()
' Clothes_Shoes.Clear()
' 'dna_Backpack
' Case sender Is Clothes_Backpacks_Import
' GlobalVariables.ClothingMarket.Backpacks.Clear()
' Clothes_Backpacks.Clear()
' 'dna_Gloves
' Case sender Is Clothes_Gloves_Import
' GlobalVariables.ClothingMarket.Gloves.Clear()
' Clothes_Gloves.Clear()
' 'dna_Belt
' Case sender Is Clothes_Belts_Import
' GlobalVariables.ClothingMarket.Belts.Clear()
' Clothes_Belts.Clear()
' 'dna_Facewear
' Case sender Is Clothes_Facewear_Import
' GlobalVariables.ClothingMarket.Facewears.Clear()
' Clothes_Facewear.Clear()
' 'dna_Eyewear
' Case sender Is Clothes_Eyewear_Import
' GlobalVariables.ClothingMarket.Eyewears.Clear()
' Clothes_Eyewear.Clear()
' 'dna_Armband
' Case sender Is Clothes_Armbands_Import
' GlobalVariables.ClothingMarket.Armbands.Clear()
' Clothes_Armbands.Clear()
' 'Loot Market
' Case sender Is Loot_proprietary_Import
' GlobalVariables.LootMarket.proprietary.Clear()
' Loot_proprietary.Clear()
' Case sender Is Loot_medical_Import
' GlobalVariables.LootMarket.medical.Clear()
' Loot_medical.Clear()
' Case sender Is Loot_food_Import
' GlobalVariables.LootMarket.food.Clear()
' Loot_food.Clear()
' Case sender Is Loot_drink_Import
' GlobalVariables.LootMarket.drink.Clear()
' Loot_drink.Clear()
' Case sender Is Loot_tools_Import
' GlobalVariables.LootMarket.tools.Clear()
' Loot_tools.Clear()
' Case sender Is Loot_material_Import
' GlobalVariables.LootMarket.material.Clear()
' Loot_material.Clear()
' Case sender Is Loot_misc_Import
' GlobalVariables.LootMarket.misc.Clear()
' Loot_misc.Clear()
' Case sender Is Loot_valuable_Import
' GlobalVariables.LootMarket.valuable.Clear()
' Loot_valuable.Clear()
' End Select
'End Sub
Public Function GetRandomString(ByVal percentChance As Integer, ByVal obcoll As ObservableCollection(Of String)) _
As String
If obcoll.Count = 0 Then Return String.Empty
If percentChance = 0 Then Return String.Empty
If percentChance = 100 Then
If obcoll.Count = 1 Then Return obcoll.First()
Dim index As Integer = random.Next(0, obcoll.Count - 1) _
' Generate a random index within the range of the collection
Return obcoll(index)
End If
Dim success As Boolean = SimulateIfStatement_PercentChance(percentChance)
If success Then
If obcoll.Count = 1 Then Return obcoll.First()
Dim index As Integer = random.Next(0, obcoll.Count - 1) _
' Generate a random index within the range of the collection
Return obcoll(index) ' Return the random string from the collection
Else
Return String.Empty ' Return an empty string if the roll is not successful
End If
End Function
Public Function SimulateIfStatement_PercentChance(ByVal percentChance As Integer) As Boolean
Dim roll As Integer = random.Next(1, 101) ' Generate a random number between 1 and 100
Return roll <= percentChance
End Function
Private Async Sub ClothingKits_Generate_Click(sender As Object, e As RoutedEventArgs) _
Handles ClothingKits_Generate.Click, ClothingKits_Generate_Copy.Click
Dim colorTier As String
If IsNothing(Kit_ColorChoice.SelectedItem) Then
Windows.MessageBox.Show("Please select a color tier", "Alert", MessageBoxButtons.OK,
MessageBoxIcon.Information)
Else
colorTier = Kit_ColorChoice.SelectedItem.Content
colorTier = colorTier.Replace(" Kit", "")
Dim tHelmets As New ObservableCollection(Of String)()
Dim tShirts As New ObservableCollection(Of String)()
Dim tVests As New ObservableCollection(Of String)()
Dim tPants As New ObservableCollection(Of String)()
Dim tShoes As New ObservableCollection(Of String)()
Dim tBackpacks As New ObservableCollection(Of String)()
Dim tGloves As New ObservableCollection(Of String)()
Dim tBelts As New ObservableCollection(Of String)()
Dim tFacewears As New ObservableCollection(Of String)()
Dim tEyewears As New ObservableCollection(Of String)()
Dim tArmbands As New ObservableCollection(Of String)()
Dim tNVG As New ObservableCollection(Of String)()
tNVG.Add("NVGoggles")
Dim tClothingParts As New ObservableCollection(Of ObservableCollection(Of String))()
With tClothingParts
.Add(tHelmets)
.Add(tShirts)
.Add(tVests)
.Add(tPants)
.Add(tBackpacks)
.Add(tGloves)
.Add(tBelts)
.Add(tFacewears)
.Add(tEyewears)
.Add(tArmbands)
.Add(tNVG)
.Add(tShoes)
End With
Dim NumSetsToGen As Integer = ClothingKits_GenNum.Text
Dim Helmet_Chance = TB_Helmet_Chance.Text
Dim Shirt_Chance = TB_Shirt_Chance.Text
Dim Vest_Chance = TB_Vest_Chance.Text
Dim Pants_Chance = TB_Pants_Chance.Text
Dim Shoes_Chance = TB_Shoes_Chance.Text
Dim Backpack_Chance = TB_Backpack_Chance.Text
Dim Gloves_Chance = TB_Gloves_Chance.Text
Dim Belt_Chance = TB_Belt_Chance.Text
Dim Facewear_Chance = TB_Facewear_Chance.Text
Dim Eyewear_Chance = TB_Eyewear_Chance.Text
Dim Armband_Chance = TB_Armband_Chance.Text
Dim NVG_Chance = TB_NVG_Chance.Text
For Each type In GlobalVariables.Types.Types
checkedAddArgs = Await determineIfAdd(type)
If checkedAddArgs = True Then
If IsStringPresentInTextBox(Clothes_Helmets, type.typename) Then tHelmets.Add(type.typename)
If IsStringPresentInTextBox(Clothes_Shirts, type.typename) Then tShirts.Add(type.typename)
If IsStringPresentInTextBox(Clothes_Vests, type.typename) Then tVests.Add(type.typename)
If IsStringPresentInTextBox(Clothes_Pants, type.typename) Then tPants.Add(type.typename)
If IsStringPresentInTextBox(Clothes_Shoes, type.typename) Then tShoes.Add(type.typename)
If IsStringPresentInTextBox(Clothes_Backpacks, type.typename) Then tBackpacks.Add(type.typename)
If IsStringPresentInTextBox(Clothes_Gloves, type.typename) Then tGloves.Add(type.typename)
If IsStringPresentInTextBox(Clothes_Belts, type.typename) Then tBelts.Add(type.typename)
If IsStringPresentInTextBox(Clothes_Facewear, type.typename) Then tFacewears.Add(type.typename)
If IsStringPresentInTextBox(Clothes_Eyewear, type.typename) Then tEyewears.Add(type.typename)
If IsStringPresentInTextBox(Clothes_Armbands, type.typename) Then tArmbands.Add(type.typename)
'If GlobalVariables.ClothingMarket.Helmets.Contains(type.typename) Then
'If _
' GlobalVariables.ClothingMarket.Helmets.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tHelmets.Add(type.typename)
'If _
' GlobalVariables.ClothingMarket.Shirts.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tShirts.Add(type.typename)
'If _
' GlobalVariables.ClothingMarket.Vests.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tVests.Add(type.typename)
'If _
' GlobalVariables.ClothingMarket.Pants.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tPants.Add(type.typename)
'If _
' GlobalVariables.ClothingMarket.Shoes.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tShoes.Add(type.typename)
'If _
' GlobalVariables.ClothingMarket.Backpacks.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tBackpacks.Add(type.typename)
'If _
' GlobalVariables.ClothingMarket.Gloves.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tGloves.Add(type.typename)
'If _
' GlobalVariables.ClothingMarket.Belts.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tBelts.Add(type.typename)
'If _
' GlobalVariables.ClothingMarket.Facewears.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tFacewears.Add(type.typename)
'If _
' GlobalVariables.ClothingMarket.Eyewears.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tEyewears.Add(type.typename)
'If _
' GlobalVariables.ClothingMarket.Armbands.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tArmbands.Add(type.typename)
End If
Next
Dim clothesKits As New ObservableCollection(Of GenerateConfigs.Clothes.ClothesInfo)
For i = 1 To NumSetsToGen
Dim tClothesKit As New GenerateConfigs.Clothes.ClothesInfo()
tClothesKit.dna_Tier = colorTier.ToLower()
For Each tSlot As ObservableCollection(Of String) In tClothingParts
If tSlot Is tHelmets Then tClothesKit.dna_Helm = GetRandomString(Helmet_Chance, tSlot)
If tSlot Is tShirts Then tClothesKit.dna_Shirt = GetRandomString(Shirt_Chance, tSlot)
If tSlot Is tVests Then tClothesKit.dna_Vest = GetRandomString(Vest_Chance, tSlot)
If tSlot Is tPants Then tClothesKit.dna_Pants = GetRandomString(Pants_Chance, tSlot)
If tSlot Is tShoes Then tClothesKit.dna_Shoes = GetRandomString(Shoes_Chance, tSlot)
If tSlot Is tBackpacks Then tClothesKit.dna_Backpack = GetRandomString(Backpack_Chance, tSlot)
If tSlot Is tGloves Then tClothesKit.dna_Gloves = GetRandomString(Gloves_Chance, tSlot)
If tSlot Is tBelts Then tClothesKit.dna_Belt = GetRandomString(Belt_Chance, tSlot)
If tSlot Is tFacewears Then tClothesKit.dna_Facewear = GetRandomString(Facewear_Chance, tSlot)
If tSlot Is tEyewears Then tClothesKit.dna_Eyewear = GetRandomString(Eyewear_Chance, tSlot)
If tSlot Is tArmbands Then tClothesKit.dna_Armband = GetRandomString(Armband_Chance, tSlot)
If tSlot Is tNVG Then tClothesKit.dna_NVG = GetRandomString(NVG_Chance, tSlot)
Next
clothesKits.Add(tClothesKit)
Next i
Select Case colorTier
Case "Red"
GenerateConfigs.Clothes.RedClothesKits = clothesKits
Case "Purple"
GenerateConfigs.Clothes.PurpleClothesKits = clothesKits
Case "Blue"
GenerateConfigs.Clothes.BlueClothesKits = clothesKits
Case "Green"
GenerateConfigs.Clothes.GreenClothesKits = clothesKits
Case "Yellow"
GenerateConfigs.Clothes.YellowClothesKits = clothesKits
End Select
UpdateGeneratedClothingKits()
End If
End Sub
Private Async Sub LootKits_Generate_Click(sender As Object, e As RoutedEventArgs) _
Handles LootKits_Generate_Copy.Click, LootKits_Generate.Click
Dim colorTier As String
If IsNothing(Kit_ColorChoice.SelectedItem) Then
Windows.MessageBox.Show("Please select a color tier", "Alert", MessageBoxButtons.OK,
MessageBoxIcon.Information)
Else
colorTier = Kit_ColorChoice.SelectedItem.Content
colorTier = colorTier.Replace(" Kit", "")
Dim tproprietary As New ObservableCollection(Of String)()
Dim tmedical As New ObservableCollection(Of String)()
Dim tfood As New ObservableCollection(Of String)()
Dim tdrink As New ObservableCollection(Of String)()
Dim ttools As New ObservableCollection(Of String)()
Dim tmaterial As New ObservableCollection(Of String)()
Dim tmisc As New ObservableCollection(Of String)()
Dim tvaluable As New ObservableCollection(Of String)()
Dim collection As New ObservableCollection(Of ObservableCollection(Of String))()
With collection
.Add(tproprietary)
.Add(tmedical)
.Add(tfood)
.Add(tdrink)
.Add(ttools)
.Add(tmaterial)
.Add(tmisc)
.Add(tvaluable)
End With
For Each type In GlobalVariables.Types.Types
checkedAddArgs = Await determineIfAdd(type, False)
If checkedAddArgs = True Then
'If GlobalVariables.ClothingMarket.Helmets.Contains(type.typename) Then
If IsStringPresentInTextBox(Loot_proprietary, type.typename) Then tproprietary.Add(type.typename)
If IsStringPresentInTextBox(Loot_medical, type.typename) Then tmedical.Add(type.typename)
If IsStringPresentInTextBox(Loot_food, type.typename) Then tfood.Add(type.typename)
If IsStringPresentInTextBox(Loot_drink, type.typename) Then tdrink.Add(type.typename)
If IsStringPresentInTextBox(Loot_tools, type.typename) Then ttools.Add(type.typename)
If IsStringPresentInTextBox(Loot_material, type.typename) Then tmaterial.Add(type.typename)
If IsStringPresentInTextBox(Loot_misc, type.typename) Then tmisc.Add(type.typename)
If IsStringPresentInTextBox(Loot_valuable, type.typename) Then tvaluable.Add(type.typename)
'If _
' GlobalVariables.LootMarket.medical.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tmedical.Add(type.typename)
' If _
' GlobalVariables.LootMarket.food.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tfood.Add(type.typename)
' If _
' GlobalVariables.LootMarket.drink.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tdrink.Add(type.typename)
' If _
' GlobalVariables.LootMarket.tools.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' ttools.Add(type.typename)
' If _
' GlobalVariables.LootMarket.material.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tmaterial.Add(type.typename)
' If _
' GlobalVariables.LootMarket.misc.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tmisc.Add(type.typename)
' If _
' GlobalVariables.LootMarket.valuable.Any(
' Function(t_) String.Equals(t_, type.typename, StringComparison.OrdinalIgnoreCase)) Then _
' tvaluable.Add(type.typename)
End If
Next
Dim tempLootInfo As New GenerateConfigs.Loot.LootInfoCats With {
.proprietary = New Collection(Of GenerateConfigs.Loot.LootInfoType),
.medical = New Collection(Of GenerateConfigs.Loot.LootInfoType),
.food = New Collection(Of GenerateConfigs.Loot.LootInfoType),
.drink = New Collection(Of GenerateConfigs.Loot.LootInfoType),
.tools = New Collection(Of GenerateConfigs.Loot.LootInfoType),
.material = New Collection(Of GenerateConfigs.Loot.LootInfoType),
.misc = New Collection(Of GenerateConfigs.Loot.LootInfoType),
.valuable = New Collection(Of GenerateConfigs.Loot.LootInfoType)
}
For Each tSlot As ObservableCollection(Of String) In collection
If tSlot Is tproprietary Then
For Each tType In tSlot
Dim info As New GenerateConfigs.Loot.LootInfoType With {
.dna_Tier = colorTier.ToLower(),
.dna_Category = "proprietary",
.dna_Type = tType
}
tempLootInfo.proprietary.Add(info)
Next
End If
If tSlot Is tmedical Then
For Each tType In tSlot
Dim info As New GenerateConfigs.Loot.LootInfoType()
info.dna_Tier = colorTier.ToLower()
info.dna_Category = "medical"
info.dna_Type = tType
tempLootInfo.medical.Add(info)
Next
End If
If tSlot Is tfood Then
For Each tType In tSlot
Dim info As New GenerateConfigs.Loot.LootInfoType()
info.dna_Tier = colorTier.ToLower()
info.dna_Category = "food"
info.dna_Type = tType
tempLootInfo.food.Add(info)
Next
End If
If tSlot Is tdrink Then
For Each tType In tSlot
Dim info As New GenerateConfigs.Loot.LootInfoType()
info.dna_Tier = colorTier.ToLower()
info.dna_Category = "drink"
info.dna_Type = tType
tempLootInfo.drink.Add(info)
Next
End If
If tSlot Is ttools Then
For Each tType In tSlot
Dim info As New GenerateConfigs.Loot.LootInfoType()
info.dna_Tier = colorTier.ToLower()
info.dna_Category = "tools"
info.dna_Type = tType
tempLootInfo.tools.Add(info)
Next
End If
If tSlot Is tmaterial Then
For Each tType In tSlot
Dim info As New GenerateConfigs.Loot.LootInfoType()
info.dna_Tier = colorTier.ToLower()
info.dna_Category = "material"
info.dna_Type = tType
tempLootInfo.material.Add(info)
Next
End If
If tSlot Is tmisc Then
For Each tType In tSlot
Dim info As New GenerateConfigs.Loot.LootInfoType()
info.dna_Tier = colorTier.ToLower()
info.dna_Category = "misc"
info.dna_Type = tType
tempLootInfo.misc.Add(info)
Next
End If
If tSlot Is tvaluable Then
For Each tType In tSlot
Dim info As New GenerateConfigs.Loot.LootInfoType()
info.dna_Tier = colorTier.ToLower()
info.dna_Category = "valuable "
info.dna_Type = tType
tempLootInfo.valuable.Add(info)
Next
End If
Next
Select Case colorTier
Case "Red"
GenerateConfigs.Loot.RedLootKits = tempLootInfo
Case "Purple"
GenerateConfigs.Loot.PurpleLootKits = tempLootInfo
Case "Blue"
GenerateConfigs.Loot.BlueLootKits = tempLootInfo
Case "Green"
GenerateConfigs.Loot.GreenLootKits = tempLootInfo
Case "Yellow"
GenerateConfigs.Loot.YellowLootKits = tempLootInfo
End Select
UpdateGeneratedLootKits()
End If
End Sub
Private Async Sub WeaponKits_Generate_Click(sender As Object, e As RoutedEventArgs) _
Handles WeaponKits_Generate.Click
Dim WeaponColorTier As String
If IsNothing(Kit_ColorChoice.SelectedItem) Then
Windows.MessageBox.Show("Please select a color tier", "Alert", MessageBoxButtons.OK,
MessageBoxIcon.Information)
Else
WeaponColorTier = Kit_ColorChoice.SelectedItem.Content
WeaponColorTier = WeaponColorTier.Replace(" Kit", "")
Dim weaponList As New ObservableCollection(Of GenerateConfigs.Weapons.WeaponInfo)()
For Each type In GlobalVariables.Types.Types
''''''''FLAGS
checkedAddArgs = Await determineIfAdd(type)
If checkedAddArgs = True Then
Dim weapon As New GenerateConfigs.Weapons.WeaponInfo()
weapon.dna_Tier = WeaponColorTier
weapon.dna_TheChosenOne = type.typename
Dim exists As Boolean = StringExistsInCollection(type.typename, GlobalVariables.SideArms)
If exists Then
weapon.dna_WeaponCategory = "side"
End If
weaponList.Add(weapon)
End If
Next
Select Case WeaponColorTier
Case "Red"
GenerateConfigs.Weapons.RedWeaponKits = weaponList
Case "Purple"
GenerateConfigs.Weapons.PurpleWeaponKits = weaponList
Case "Blue"
GenerateConfigs.Weapons.BlueWeaponKits = weaponList
Case "Green"
GenerateConfigs.Weapons.GreenWeaponKits = weaponList
Case "Yellow"
GenerateConfigs.Weapons.YellowWeaponKits = weaponList
End Select
UpdateGeneratedWeaponKits()
End If
End Sub
Sub UpdateGeneratedClothingKits()
Tab_KitsGenerated.IsSelected = True
Tab_ClothingKits.IsSelected = True
'Red Update
If GenerateConfigs.Clothes.RedClothesKits IsNot Nothing Then
TV_ClothingKit_Generated_Red.Nodes.Clear()
For Each Clotheset_ As GenerateConfigs.Clothes.ClothesInfo In GenerateConfigs.Clothes.RedClothesKits
Dim tCount = TV_ClothingKit_Generated_Red.Nodes.Count
TV_ClothingKit_Generated_Red.Nodes.Add(CreateNodeSetClothes(Clotheset_, tCount))
Next