]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Fix some locale strings and make some code for them looks better (#32003)
authorlzk <124214523+lzk228@users.noreply.github.com>
Mon, 21 Apr 2025 20:15:20 +0000 (22:15 +0200)
committerGitHub <noreply@github.com>
Mon, 21 Apr 2025 20:15:20 +0000 (22:15 +0200)
* Fix a lot locale strings

add functions using
fix identity for meat spike and creaming

* comma

* fixes for fixes

* yeah

* fuck

Content.Server/Kitchen/EntitySystems/KitchenSpikeSystem.cs
Content.Server/Nutrition/EntitySystems/CreamPieSystem.cs
Content.Shared/Cuffs/SharedCuffableSystem.cs
Content.Shared/Strip/SharedStrippableSystem.cs
Resources/Locale/en-US/cuffs/components/handcuff-component.ftl
Resources/Locale/en-US/kitchen/components/kitchen-spike-component.ftl
Resources/Locale/en-US/nutrition/components/cream-pied-component.ftl
Resources/Locale/en-US/nutrition/components/food-component.ftl
Resources/Locale/en-US/strip/strippable-component.ftl

index 6f28331ade4a6b13589667f17b0c8b40fa2a9e63..4ed05a3f1620faffa0965c166ff12d1c7f08a975 100644 (file)
@@ -74,10 +74,13 @@ namespace Content.Server.Kitchen.EntitySystems
                 return;
 
             _suicide.ApplyLethalDamage((args.Victim, damageableComponent), "Piercing");
-            var othersMessage = Loc.GetString("comp-kitchen-spike-suicide-other", ("victim", args.Victim));
+            var othersMessage = Loc.GetString("comp-kitchen-spike-suicide-other",
+                                                ("victim", Identity.Entity(args.Victim, EntityManager)),
+                                                ("this", entity));
             _popupSystem.PopupEntity(othersMessage, args.Victim, Filter.PvsExcept(args.Victim), true);
 
-            var selfMessage = Loc.GetString("comp-kitchen-spike-suicide-self");
+            var selfMessage = Loc.GetString("comp-kitchen-spike-suicide-self",
+                                            ("this", entity));
             _popupSystem.PopupEntity(selfMessage, args.Victim, args.Victim);
             args.Handled = true;
         }
@@ -160,7 +163,11 @@ namespace Content.Server.Kitchen.EntitySystems
 
             UpdateAppearance(uid, null, component);
 
-            _popupSystem.PopupEntity(Loc.GetString("comp-kitchen-spike-kill", ("user", Identity.Entity(userUid, EntityManager)), ("victim", victimUid)), uid, PopupType.LargeCaution);
+            _popupSystem.PopupEntity(Loc.GetString("comp-kitchen-spike-kill",
+                                                    ("user", Identity.Entity(userUid, EntityManager)),
+                                                    ("victim", Identity.Entity(victimUid, EntityManager)),
+                                                    ("this", uid)),
+                                    uid, PopupType.LargeCaution);
 
             _transform.SetCoordinates(victimUid, Transform(uid).Coordinates);
             // THE WHAT?
index cdcfcc1f21199d15a55948d6c60fe65b2fde91bd..108280f088582ed6f21a21fff739a829b298fd0e 100644 (file)
@@ -93,13 +93,19 @@ namespace Content.Server.Nutrition.EntitySystems
 
         protected override void CreamedEntity(EntityUid uid, CreamPiedComponent creamPied, ThrowHitByEvent args)
         {
-            _popup.PopupEntity(Loc.GetString("cream-pied-component-on-hit-by-message", ("thrower", args.Thrown)), uid, args.Target);
+            _popup.PopupEntity(Loc.GetString("cream-pied-component-on-hit-by-message",
+                                            ("thrower", Identity.Entity(args.Thrown, EntityManager))),
+                                            uid, args.Target);
+
             var otherPlayers = Filter.Empty().AddPlayersByPvs(uid);
             if (TryComp<ActorComponent>(args.Target, out var actor))
             {
                 otherPlayers.RemovePlayer(actor.PlayerSession);
             }
-            _popup.PopupEntity(Loc.GetString("cream-pied-component-on-hit-by-message-others", ("owner", Identity.Name(uid, EntityManager)), ("thrower", args.Thrown)), uid, otherPlayers, false);
+            _popup.PopupEntity(Loc.GetString("cream-pied-component-on-hit-by-message-others",
+                                            ("owner", Identity.Entity(uid, EntityManager)),
+                                            ("thrower", Identity.Entity(args.Thrown, EntityManager))),
+                                            uid, otherPlayers, false);
         }
 
         private void OnRejuvenate(Entity<CreamPiedComponent> entity, ref RejuvenateEvent args)
index 99a4dad510d7c9cb8313c4240ecf3f3fd9f84405..9c38667399802385928ecda819b0882422b9c0db 100644 (file)
@@ -381,7 +381,8 @@ namespace Content.Shared.Cuffs
                     _popup.PopupClient(Loc.GetString("handcuff-component-cuff-interrupt-message",
                         ("targetName", Identity.Name(target, EntityManager, user))), user, user);
                     _popup.PopupClient(Loc.GetString("handcuff-component-cuff-interrupt-other-message",
-                        ("otherName", Identity.Name(user, EntityManager, target))), target, target);
+                        ("otherName", Identity.Name(user, EntityManager, target)),
+                        ("otherEnt", user)), target, target);
                 }
             }
         }
index d851f46060da294929c1906104a7bb59c91c42ed..2b971ae7bbf2310552103c3e46b970dc03dd7f2c 100644 (file)
@@ -210,7 +210,10 @@ public abstract class SharedStrippableSystem : EntitySystem
         var (time, stealth) = GetStripTimeModifiers(user, target, held, slotDef.StripTime);
 
         if (!stealth)
-            _popupSystem.PopupEntity(Loc.GetString("strippable-component-alert-owner-insert", ("user", Identity.Entity(user, EntityManager)), ("item", user.Comp.ActiveHandEntity!.Value)), target, target, PopupType.Large);
+            _popupSystem.PopupEntity(Loc.GetString("strippable-component-alert-owner-insert",
+                                                        ("user", Identity.Entity(user, EntityManager)),
+                                                        ("item", user.Comp.ActiveHandEntity!.Value)),
+                                                        target, target, PopupType.Large);
 
         var prefix = stealth ? "stealthily " : "";
         _adminLogger.Add(LogType.Stripping, LogImpact.Low, $"{ToPrettyString(user):actor} is trying to {prefix}place the item {ToPrettyString(held):item} in {ToPrettyString(target):target}'s {slot} slot");
@@ -302,7 +305,10 @@ public abstract class SharedStrippableSystem : EntitySystem
             if (IsStripHidden(slotDef, user))
                 _popupSystem.PopupEntity(Loc.GetString("strippable-component-alert-owner-hidden", ("slot", slot)), target, target, PopupType.Large);
             else
-                _popupSystem.PopupEntity(Loc.GetString("strippable-component-alert-owner", ("user", Identity.Entity(user, EntityManager)), ("item", item)), target, target, PopupType.Large);
+                _popupSystem.PopupEntity(Loc.GetString("strippable-component-alert-owner",
+                                                            ("user", Identity.Entity(user, EntityManager)),
+                                                            ("item", item)),
+                                                            target, target, PopupType.Large);
         }
 
         var prefix = stealth ? "stealthily " : "";
@@ -408,7 +414,10 @@ public abstract class SharedStrippableSystem : EntitySystem
         var (time, stealth) = GetStripTimeModifiers(user, target, null, targetStrippable.HandStripDelay);
 
         if (!stealth)
-            _popupSystem.PopupEntity(Loc.GetString("strippable-component-alert-owner-insert-hand", ("user", Identity.Entity(user, EntityManager)), ("item", user.Comp.ActiveHandEntity!.Value)), target, target, PopupType.Large);
+            _popupSystem.PopupEntity(Loc.GetString("strippable-component-alert-owner-insert-hand",
+                                                        ("user", Identity.Entity(user, EntityManager)),
+                                                        ("item", user.Comp.ActiveHandEntity!.Value)),
+                                                        target, target, PopupType.Large);
 
         var prefix = stealth ? "stealthily " : "";
         _adminLogger.Add(LogType.Stripping, LogImpact.Low, $"{ToPrettyString(user):actor} is trying to {prefix}place the item {ToPrettyString(held):item} in {ToPrettyString(target):target}'s hands");
@@ -510,7 +519,10 @@ public abstract class SharedStrippableSystem : EntitySystem
         var (time, stealth) = GetStripTimeModifiers(user, target, null, targetStrippable.HandStripDelay);
 
         if (!stealth)
-            _popupSystem.PopupEntity(Loc.GetString("strippable-component-alert-owner", ("user", Identity.Entity(user, EntityManager)), ("item", item)), target, target);
+            _popupSystem.PopupEntity(Loc.GetString("strippable-component-alert-owner",
+                                                        ("user", Identity.Entity(user, EntityManager)),
+                                                        ("item", item)),
+                                                        target, target);
 
         var prefix = stealth ? "stealthily " : "";
         _adminLogger.Add(LogType.Stripping, LogImpact.Low, $"{ToPrettyString(user):actor} is trying to {prefix}strip the item {ToPrettyString(item):item} from {ToPrettyString(target):target}'s hands");
index 0f3c7cfd522f62ace6fe62ae1417fc89fc42ff28..ba4a6a967e3534ec40fa6a924ea2628408b0903a 100644 (file)
@@ -13,8 +13,8 @@ handcuff-component-cuff-other-success-message = You successfully restrain {$othe
 handcuff-component-cuff-by-other-success-message = You have been restrained by {$otherName}!
 handcuff-component-cuff-self-success-message = You restrain yourself.
 handcuff-component-cuff-interrupt-message = You were interrupted while restraining {$targetName}!
-handcuff-component-cuff-interrupt-other-message = You interrupt {$otherName} while they are restraining you!
+handcuff-component-cuff-interrupt-other-message = You interrupt {$otherName} while { SUBJECT($otherEnt) } { CONJUGATE-BE($otherEnt) } restraining you!
 handcuff-component-cuff-interrupt-self-message = You were interrupted while restraining yourself.
 handcuff-component-cuff-interrupt-buckled-message = You can't buckle while restrained!
 handcuff-component-cuff-interrupt-unbuckled-message = You can't unbuckle while restrained!
-handcuff-component-cannot-drop-cuffs = You are unable to put the restraints on {$target}
+handcuff-component-cannot-drop-cuffs = You are unable to put the restraints on {$target}.
index b2ceffc6aa346d8915a2356a8014b64660e762f2..aa555b24ae2f90023e91dd7c1d957fadf2dfa98b 100644 (file)
@@ -6,10 +6,10 @@ comp-kitchen-spike-deny-not-dead = { CAPITALIZE(THE($victim)) } can't be butcher
 comp-kitchen-spike-begin-hook-victim = { CAPITALIZE(THE($user)) } begins dragging you onto { THE($this) }!
 comp-kitchen-spike-begin-hook-self = You begin dragging yourself onto { THE($this) }!
 
-comp-kitchen-spike-kill = { CAPITALIZE(THE($user)) } has forced { THE($victim) } onto the spike, killing them instantly!
+comp-kitchen-spike-kill = { CAPITALIZE(THE($user)) } has forced { THE($victim) } onto { THE($this) }, killing { OBJECT($victim) } instantly!
 
-comp-kitchen-spike-suicide-other = { CAPITALIZE(THE($victim)) } has thrown themselves on a meat spike!
-comp-kitchen-spike-suicide-self = You throw yourself on a meat spike!
+comp-kitchen-spike-suicide-other = { CAPITALIZE(THE($victim)) } threw { REFLEXIVE($victim) } on { THE($this) }!
+comp-kitchen-spike-suicide-self = You throw yourself on { THE($this) }!
 
 comp-kitchen-spike-knife-needed = You need a knife to do this.
 comp-kitchen-spike-remove-meat = You remove some meat from { THE($victim) }.
index 2322d20162596d791528baad25efaba27d866f40..a75f163adb7d988f31390267a68ef50bb86977b7 100644 (file)
@@ -1,2 +1,2 @@
 cream-pied-component-on-hit-by-message =  You have been creamed by {$thrower}!
-cream-pied-component-on-hit-by-message-others = {$owner} has been creamed by {$thrower}!
\ No newline at end of file
+cream-pied-component-on-hit-by-message-others = {$owner} has been creamed by {$thrower}!
index 3de156fdef441470c5b4602faf6948042fedd3b0..2247ef6fd48dcd16b0500aba869303585f41289b 100644 (file)
@@ -2,12 +2,12 @@
 ### Interaction Messages
 
 # When trying to eat food without the required utensil... but you gotta hold it
-food-you-need-to-hold-utensil = You need to be holding a {$utensil} to eat that!
+food-you-need-to-hold-utensil = You need to be holding {INDEFINITE($utensil)} {$utensil} to eat that!
 
 food-nom = Nom. {$flavors}
-food-swallow = You swallow the {$food}. {$flavors}
+food-swallow = You swallow { THE($food) }. {$flavors}
 
-food-has-used-storage = You cannot eat the {$food} with an item stored inside.
+food-has-used-storage = You cannot eat { THE($food) } with an item stored inside.
 
 food-system-remove-mask = You need to take off the {$entity} first.
 
index 7654369c295ac9c53cb0a106fb7875a45d47b6f8..7022319d220dddbf8f5f45a3246552176e29574d 100644 (file)
@@ -8,8 +8,8 @@ strippable-component-cannot-unequip-message = {CAPITALIZE(THE($owner))} cannot u
 strippable-component-cannot-drop-message = {CAPITALIZE(THE($owner))} cannot drop that!
 strippable-component-alert-owner = {CAPITALIZE(THE($user))} is removing your {$item}!
 strippable-component-alert-owner-hidden = You feel someone fumbling in your {$slot}!
-strippable-component-alert-owner-insert = {CAPITALIZE(THE($user))} is putting {$item} on you!
-strippable-component-alert-owner-insert-hand = {CAPITALIZE(THE($user))} is putting {$item} in your hand!
+strippable-component-alert-owner-insert = {CAPITALIZE(THE($user))} is putting {INDEFINITE($item)} {$item} on you!
+strippable-component-alert-owner-insert-hand = {CAPITALIZE(THE($user))} is putting {INDEFINITE($item)} {$item} in your hand!
 
 # generic warning for when a user interacts with your equipped items.
 strippable-component-alert-owner-interact = {CAPITALIZE(THE($user))} is fumbling around with your {$item}!