@@ -31,6 +31,8 @@ public class Scoring
3131 private static CheckBox bronze_traits = new CheckBox ( ) ;
3232 private static CheckBox carryCheck = new CheckBox ( ) ;
3333 private static CheckBox carryCheck_unspecified = new CheckBox ( ) ;
34+ private static CheckBox mustMaxOutTraitLevel = new CheckBox ( ) ;
35+ private static CheckBox mustMaxOutTraitLevelCurrent = new CheckBox ( ) ;
3436
3537
3638 public static ListBox include_spatula = new ListBox ( ) ;
@@ -59,7 +61,9 @@ public static void SetFromScoring(
5961 ListBox include_spatula_ ,
6062 CheckBox bronze_traits_ ,
6163 CheckBox carryCheck_ ,
62- CheckBox carryCheck_unspecified_
64+ CheckBox carryCheck_unspecified_ ,
65+ CheckBox mustMaxOutTraitLevel_ ,
66+ CheckBox mustMaxOutTraitLevelCurrent_
6367 )
6468 {
6569 Master = M ;
@@ -88,6 +92,8 @@ CheckBox carryCheck_unspecified_
8892 carryCheck = carryCheck_ ;
8993 carryCheck_unspecified = carryCheck_unspecified_ ;
9094
95+ mustMaxOutTraitLevel = mustMaxOutTraitLevel_ ;
96+ mustMaxOutTraitLevelCurrent = mustMaxOutTraitLevelCurrent_ ;
9197 }
9298
9399 /// <summary>
@@ -335,19 +341,23 @@ public static bool CheckCompValidity(List<string> comp, List<string> excluded_co
335341 if ( include_champion . Items . Count > 0 && carryCheck . Checked )
336342 {
337343 List < string > carry = new List < string > ( ) ;
338- foreach ( string champion in include_champion . Items )
344+ foreach ( string champion in include_champion . Items )
339345 {
340346 carry . Add ( champion ) ;
341347 }
342348 if ( ! CarryWorth3 ( JTraits , carry ) ) { return false ; }
349+
350+ //
351+
352+
343353 }
344354
345- if ( carryCheck_unspecified . Checked )
355+ if ( carryCheck_unspecified . Checked )
346356 {
347- if ( ! isCarryPresent ( JTraits , comp ) )
357+ if ( ! isCarryPresent ( JTraits , comp ) )
348358 return false ;
349359 }
350-
360+
351361 // Only comps with at least one trait that reaches BP 3 (gold) are considered valid.
352362 // Note: traits that only have 2 BP (therefore gold at 2) are ignored
353363 if ( goldTrait . Checked )
@@ -403,12 +413,25 @@ public static bool CheckCompValidity(List<string> comp, List<string> excluded_co
403413 }
404414
405415
406-
407416 // Included / Excluded trait check
408417 foreach ( string Trait in include_trait . Items )
409418 {
410419 if ( ! isTraitActive ( JTraits , Trait ) )
411420 return false ;
421+
422+ if ( mustMaxOutTraitLevel . Checked )
423+ {
424+ // compute max potential without a spatula
425+ List < string > wantedTraitList = new List < string > ( ) ;
426+
427+ foreach ( dynamic item in include_trait . Items )
428+ {
429+ wantedTraitList . Add ( item . ToString ( ) ) ;
430+ }
431+ if ( ! isTraitMaxedOutNoSpatula ( JTraits , wantedTraitList ) )
432+ return false ;
433+ //int amount = JTraitsMaster["TraitChampions"]
434+ }
412435 }
413436
414437 foreach ( string Trait in exclude_trait . Items )
@@ -427,9 +450,9 @@ public static bool CheckCompValidity(List<string> comp, List<string> excluded_co
427450 }
428451 }
429452
430-
431453
432-
454+
455+
433456
434457 // Ensure specified emblems are used
435458 foreach ( string Trait in include_spatula . Items )
@@ -450,7 +473,7 @@ public static bool CheckCompValidity(List<string> comp, List<string> excluded_co
450473 if ( bronze_traits . Checked )
451474 {
452475 int BP = CheckBreakPointAmount ( JTraits , Trait ) ;
453- if ( BP > 1 ) { return false ; }
476+ if ( BP > 1 ) { return false ; }
454477 }
455478
456479 if ( isTraitActive ( JTraits , Trait ) )
0 commit comments