Truncate lathe announcement lists (#36945)
This commit is contained in:
committed by
GitHub
parent
f74b1c35bb
commit
b7d020570f
@@ -385,10 +385,17 @@ namespace Content.Server.Lathe
|
||||
if (recipeNames.Count == 0)
|
||||
return;
|
||||
|
||||
var message = Loc.GetString(
|
||||
"lathe-unlock-recipe-radio-broadcast",
|
||||
("items", ContentLocalizationManager.FormatList(recipeNames))
|
||||
);
|
||||
var message =
|
||||
recipeNames.Count > ent.Comp.MaximumItems ?
|
||||
Loc.GetString(
|
||||
"lathe-unlock-recipe-radio-broadcast-overflow",
|
||||
("items", ContentLocalizationManager.FormatList(recipeNames.GetRange(0, ent.Comp.MaximumItems))),
|
||||
("count", recipeNames.Count)
|
||||
) :
|
||||
Loc.GetString(
|
||||
"lathe-unlock-recipe-radio-broadcast",
|
||||
("items", ContentLocalizationManager.FormatList(recipeNames))
|
||||
);
|
||||
|
||||
foreach (var channel in ent.Comp.Channels)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user