MenuRecipe¶
Namespace Nfty.Ticket in assembly Nfty.Ticket.
One recipe, as a Menu records it.
Constructors¶
MenuRecipe(string, string, double, IReadOnlyList<string>, IReadOnlyList<MenuLayer>, IReadOnlyList<IncompatibilityRule>, IReadOnlyDictionary<string, double>)¶
public MenuRecipe(string Id, string Name, double Weight, IReadOnlyList<string> LayerOrder, IReadOnlyList<MenuLayer> Layers, IReadOnlyList<IncompatibilityRule> Rules, IReadOnlyDictionary<string, double> AbsentPercent);
Parameters
Id(string) - The recipe id.Name(string) - Its display name, published as theTypetrait.Weight(double) - Its weight against the book's other recipes.LayerOrder(IReadOnlyList<string>) - Bottom-to-top paint order — and the order the roll consumes the RNG in, which is why it travels rather than being inferred fromLayers.Layers(IReadOnlyList<MenuLayer>) - Its layers, keyed by the ids inLayerOrder.Rules(IReadOnlyList<IncompatibilityRule>) - Its incompatibility rules.AbsentPercent(IReadOnlyDictionary<string, double>) - How often each layer is left out, keyed by ingredient id. A layer absent from this map always appears.
Properties¶
AbsentPercent¶
How often each layer is left out, keyed by ingredient id. A layer absent from this map always appears.
Id¶
The recipe id.
LayerOrder¶
Bottom-to-top paint order — and the order the roll consumes the RNG in, which is why it travels rather than being inferred from Layers.
Layers¶
Its layers, keyed by the ids in LayerOrder.
Name¶
Its display name, published as the Type trait.
Rules¶
Its incompatibility rules.
Weight¶
Its weight against the book's other recipes.
Methods¶
AbsentPercentOf(string)¶
How often ingredientId is left out of this recipe, 0..100.
Parameters
ingredientId(string) - The layer to ask about.
Returns. The recorded percent, or zero when the recipe records none.