fix-lathe-recipe-dupes (#17473)
This commit is contained in:
parent
8610249277
commit
910c2da9bb
|
|
@ -101,7 +101,7 @@ namespace Content.Server.Lathe
|
|||
{
|
||||
var ev = new LatheGetRecipesEvent(uid)
|
||||
{
|
||||
Recipes = component.StaticRecipes
|
||||
Recipes = new List<string>(component.StaticRecipes)
|
||||
};
|
||||
RaiseLocalEvent(uid, ev);
|
||||
return ev.Recipes;
|
||||
|
|
@ -195,7 +195,7 @@ namespace Content.Server.Lathe
|
|||
|
||||
foreach (var recipe in latheComponent.DynamicRecipes)
|
||||
{
|
||||
if (!component.UnlockedRecipes.Contains(recipe))
|
||||
if (!component.UnlockedRecipes.Contains(recipe) || args.Recipes.Contains(recipe))
|
||||
continue;
|
||||
args.Recipes.Add(recipe);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue