diff --git a/Content.Server/_CP14/Farming/CP14FarmingSystem.cs b/Content.Server/_CP14/Farming/CP14FarmingSystem.cs index 47653c6828..9bc93e82bc 100644 --- a/Content.Server/_CP14/Farming/CP14FarmingSystem.cs +++ b/Content.Server/_CP14/Farming/CP14FarmingSystem.cs @@ -8,6 +8,7 @@ using Content.Shared._CP14.Farming; using Content.Shared.Chemistry.EntitySystems; using Content.Shared.Damage; using Content.Shared.Tag; +using Content.Shared.Examine; using Content.Shared.Whitelist; using Robust.Server.Audio; using Robust.Server.GameObjects; @@ -46,6 +47,7 @@ public sealed partial class CP14FarmingSystem : CP14SharedFarmingSystem SubscribeLocalEvent(OnUnpaused); SubscribeLocalEvent(OnMapInit); SubscribeLocalEvent(OnAutoRootMapInit); + SubscribeLocalEvent(OnExamine); } public override void Update(float frameTime) @@ -86,6 +88,15 @@ public sealed partial class CP14FarmingSystem : CP14SharedFarmingSystem plant.Comp.NextUpdateTime = _timing.CurTime + TimeSpan.FromSeconds(newTime); } + private void OnExamine(EntityUid uid, CP14PlantComponent component, ExaminedEvent args) + { + if (component.Energy <= 0) + args.PushMarkup(Loc.GetString("cp14-farming-low-energy")); + + if (component.Resource <= 0) + args.PushMarkup(Loc.GetString("cp14-farming-low-resources")); + } + private void OnAutoRootMapInit(Entity autoRoot, ref MapInitEvent args) { var grid = Transform(autoRoot).GridUid; diff --git a/Resources/Locale/en-US/_CP14/farming/farming.ftl b/Resources/Locale/en-US/_CP14/farming/farming.ftl index c6dcebdf30..e140a27a11 100644 --- a/Resources/Locale/en-US/_CP14/farming/farming.ftl +++ b/Resources/Locale/en-US/_CP14/farming/farming.ftl @@ -1 +1,3 @@ -cp14-farming-soil-interact-plant-exist = There's already something planted here! \ No newline at end of file +cp14-farming-soil-interact-plant-exist = There's already something planted here! +cp14-farming-low-energy = The plant looks wilted and shriveled. +cp14-farming-low-resources = The plant looks dry. diff --git a/Resources/Locale/ru-RU/_CP14/farming/farming.ftl b/Resources/Locale/ru-RU/_CP14/farming/farming.ftl index 69ca0b04ea..bc52e8aab8 100644 --- a/Resources/Locale/ru-RU/_CP14/farming/farming.ftl +++ b/Resources/Locale/ru-RU/_CP14/farming/farming.ftl @@ -1 +1,3 @@ -cp14-farming-soil-interact-plant-exist = Здесь уже что-то посажено! \ No newline at end of file +cp14-farming-soil-interact-plant-exist = Здесь уже что-то посажено! +cp14-farming-low-energy = Растение выглядит увядшим и сморщенным. +cp14-farming-low-resources = Растение выглядит сухим.