Added localization of groups and types: damage, metabolism (#27368)
* Added localization of groups and types: damage, metabolism (displayed in the guide book). The text for the health analyzer, weapon damage inspection is now taken from damage prototypes * fix damage tests * fix damage test yml * fix damage test prototypes * Update Content.Shared/Damage/Prototypes/DamageGroupPrototype.cs * Update Content.Shared/Damage/Prototypes/DamageTypePrototype.cs --------- Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
f5b8b5fbdc
commit
3fcbbc0732
@@ -1,4 +1,4 @@
|
||||
using Content.Server.Body.Components;
|
||||
using Content.Server.Body.Components;
|
||||
using Content.Shared.Body.Prototypes;
|
||||
using Content.Shared.Chemistry.Reagent;
|
||||
using Robust.Shared.Prototypes;
|
||||
@@ -35,7 +35,7 @@ namespace Content.Server.Chemistry.ReagentEffectConditions
|
||||
public override string GuidebookExplanation(IPrototypeManager prototype)
|
||||
{
|
||||
return Loc.GetString("reagent-effect-condition-guidebook-organ-type",
|
||||
("name", prototype.Index<MetabolizerTypePrototype>(Type).Name),
|
||||
("name", prototype.Index<MetabolizerTypePrototype>(Type).LocalizedName),
|
||||
("shouldhave", ShouldHave));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using Content.Shared.Chemistry.Reagent;
|
||||
using Content.Shared.Chemistry.Reagent;
|
||||
using Content.Shared.FixedPoint;
|
||||
using Robust.Shared.Prototypes;
|
||||
|
||||
@@ -43,7 +43,7 @@ namespace Content.Server.Chemistry.ReagentEffectConditions
|
||||
prototype.TryIndex(Reagent, out reagentProto);
|
||||
|
||||
return Loc.GetString("reagent-effect-condition-guidebook-reagent-threshold",
|
||||
("reagent", reagentProto?.LocalizedName ?? "this reagent"),
|
||||
("reagent", reagentProto?.LocalizedName ?? Loc.GetString("reagent-effect-condition-guidebook-this-reagent")),
|
||||
("max", Max == FixedPoint2.MaxValue ? (float) int.MaxValue : Max.Float()),
|
||||
("min", Min.Float()));
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using Content.Shared.Body.Prototypes;
|
||||
using Content.Shared.Body.Prototypes;
|
||||
using Content.Shared.Chemistry.Reagent;
|
||||
using Content.Shared.FixedPoint;
|
||||
using JetBrains.Annotations;
|
||||
@@ -74,7 +74,7 @@ namespace Content.Server.Chemistry.ReagentEffects
|
||||
return Loc.GetString("reagent-effect-guidebook-adjust-reagent-group",
|
||||
("chance", Probability),
|
||||
("deltasign", MathF.Sign(Amount.Float())),
|
||||
("group", groupProto.ID),
|
||||
("group", groupProto.LocalizedName),
|
||||
("amount", MathF.Abs(Amount.Float())));
|
||||
}
|
||||
|
||||
|
||||
@@ -74,7 +74,7 @@ namespace Content.Server.Chemistry.ReagentEffects
|
||||
|
||||
damages.Add(
|
||||
Loc.GetString("health-change-display",
|
||||
("kind", group.ID),
|
||||
("kind", group.LocalizedName),
|
||||
("amount", MathF.Abs(amount.Float())),
|
||||
("deltasign", sign)
|
||||
));
|
||||
@@ -96,7 +96,7 @@ namespace Content.Server.Chemistry.ReagentEffects
|
||||
|
||||
damages.Add(
|
||||
Loc.GetString("health-change-display",
|
||||
("kind", kind),
|
||||
("kind", prototype.Index<DamageTypePrototype>(kind).LocalizedName),
|
||||
("amount", MathF.Abs(amount.Float())),
|
||||
("deltasign", sign)
|
||||
));
|
||||
|
||||
Reference in New Issue
Block a user