Exemplo n.º 1
0
 public EngineerOperation(BlueprintCategory category,
                          string blueprintName,
                          string type,
                          string slot,
                          string engineer,
                          int?grade,
                          string experimentalEffect)
 {
     Category           = category;
     BlueprintName      = blueprintName;
     TechnicalType      = type?.ToLowerInvariant();
     TechnicalSlot      = slot?.ToLowerInvariant();
     Engineer           = engineer;
     Grade              = grade;
     ExperimentalEffect = experimentalEffect;
 }
Exemplo n.º 2
0
        public ShoppingListBlock(string label, string tooltip, List <Tuple <Blueprint, int> > composition, BlueprintCategory category, bool showAllGrades)
        {
            Label       = label;
            Tooltip     = tooltip;
            Composition = new SortedObservableCollection <Tuple <Blueprint, int> >((b1, b2) => b1.Item1.Grade.GetValueOrDefault().CompareTo(b2.Item1.Grade.GetValueOrDefault()));
            foreach (var blueprint in composition)
            {
                Composition.Add(blueprint);
            }
            ShowAllGrades = showAllGrades;

            Category = category;

            foreach (var blueprint in Composition)
            {
                blueprint.Item1.PropertyChanged += (o, e) =>
                {
                    if (e.PropertyName == "ShoppingListHighlighted")
                    {
                        this.Highlighted = ((Blueprint)o).ShoppingListHighlighted;
                    }
                };
            }
        }
Exemplo n.º 3
0
 public void OnBlueprintCrafted(BlueprintCategory category, string technicalName, List <BlueprintIngredient> ingredientsConsumed)
 {
     BlueprintCrafted?.Invoke(this, Tuple.Create(category, technicalName, ingredientsConsumed));
 }
Exemplo n.º 4
0
 public CategoryFilter(BlueprintCategory category, string uniqueName) : base(uniqueName)
 {
     Category = category;
     Checked  = true;
 }
Exemplo n.º 5
0
 public EngineerOperation(BlueprintCategory category, string technicalName)
 {
     Category      = category;
     TechnicalName = technicalName;
 }