private boolean characterStillHasCorrespondingSpecialty(IEquipmentStatsOption option) {
   try {
     AbilityType trait = AbilityType.valueOf(option.getType());
     INamedGenericTrait[] specialties = dataProvider.getSpecialties(trait);
     ArrayUtilities.indexOf(specialties, option.getUnderlyingTrait());
     return true;
   } catch (IllegalArgumentException e) {
     return false;
   }
 }
Beispiel #2
0
 private ITraitType[] getAllCoreTraitTypes() {
   if (allPrerequisiteTypeList.isEmpty()) {
     for (ITraitType type : AbilityType.values()) {
       allPrerequisiteTypeList.add(type);
     }
     for (ITraitType type : AttributeType.values()) {
       allPrerequisiteTypeList.add(type);
     }
     for (ITraitType type : VirtueType.values()) {
       allPrerequisiteTypeList.add(type);
     }
     for (ITraitType type : YoziType.values()) allPrerequisiteTypeList.add(type);
     for (ITraitType type : OtherTraitType.values()) {
       allPrerequisiteTypeList.add(type);
     }
   }
   return allPrerequisiteTypeList.toArray(new ITraitType[allPrerequisiteTypeList.size()]);
 }