From b66fd9851487887ee6bd09726b90eca08721a0d4 Mon Sep 17 00:00:00 2001 From: MilenVolf <63782763+MilenVolf@users.noreply.github.com> Date: Fri, 6 Dec 2024 18:38:00 +0300 Subject: [PATCH] Localize ai dataset names (#33608) Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com> --- .../Loadouts/RoleLoadoutPrototype.cs | 2 +- .../Station/SharedStationSpawningSystem.cs | 4 +- Resources/Locale/en-US/datasets/names/ai.ftl | 139 ++++++++++++++++++ Resources/Prototypes/Datasets/Names/ai.yml | 114 +------------- .../Prototypes/Loadouts/role_loadouts.yml | 2 +- 5 files changed, 147 insertions(+), 114 deletions(-) create mode 100644 Resources/Locale/en-US/datasets/names/ai.ftl diff --git a/Content.Shared/Preferences/Loadouts/RoleLoadoutPrototype.cs b/Content.Shared/Preferences/Loadouts/RoleLoadoutPrototype.cs index 7a29bad667..92b2d3ef0e 100644 --- a/Content.Shared/Preferences/Loadouts/RoleLoadoutPrototype.cs +++ b/Content.Shared/Preferences/Loadouts/RoleLoadoutPrototype.cs @@ -20,7 +20,7 @@ public sealed partial class RoleLoadoutPrototype : IPrototype /// Should we use a random name for this loadout? /// [DataField] - public ProtoId? NameDataset; + public ProtoId? NameDataset; // Not required so people can set their names. /// diff --git a/Content.Shared/Station/SharedStationSpawningSystem.cs b/Content.Shared/Station/SharedStationSpawningSystem.cs index a23ee30940..4c21b61d3d 100644 --- a/Content.Shared/Station/SharedStationSpawningSystem.cs +++ b/Content.Shared/Station/SharedStationSpawningSystem.cs @@ -70,7 +70,7 @@ public abstract class SharedStationSpawningSystem : EntitySystem if (string.IsNullOrEmpty(name) && PrototypeManager.TryIndex(roleProto.NameDataset, out var nameData)) { - name = _random.Pick(nameData.Values); + name = Loc.GetString(_random.Pick(nameData.Values)); } if (!string.IsNullOrEmpty(name)) @@ -150,7 +150,7 @@ public abstract class SharedStationSpawningSystem : EntitySystem foreach (var (slotName, entProtos) in startingGear.Storage) { - if (entProtos == null || entProtos.Count == 0) + if (entProtos == null || entProtos.Count == 0) continue; if (inventoryComp != null && diff --git a/Resources/Locale/en-US/datasets/names/ai.ftl b/Resources/Locale/en-US/datasets/names/ai.ftl new file mode 100644 index 0000000000..ac6ce0d83e --- /dev/null +++ b/Resources/Locale/en-US/datasets/names/ai.ftl @@ -0,0 +1,139 @@ +names-ai-dataset-1 = 16-20 +names-ai-dataset-2 = 512k + +# Ought to be enough for anybody +names-ai-dataset-3 = 640k + +names-ai-dataset-4 = "790" +names-ai-dataset-5 = Adaptive Manipulator + +# Named after the famous soundcard +names-ai-dataset-6 = Adlib + +names-ai-dataset-7 = ALICE +names-ai-dataset-8 = Allied Mastercomputer +names-ai-dataset-9 = Alpha 2 +names-ai-dataset-10 = Alpha 3 +names-ai-dataset-11 = Alpha 4 +names-ai-dataset-12 = Alpha 5 +names-ai-dataset-13 = Alpha 6 +names-ai-dataset-14 = Alpha 7 +names-ai-dataset-15 = Alpha 8 +names-ai-dataset-16 = Alpha 9 +names-ai-dataset-17 = AmigoBot +names-ai-dataset-18 = Android +names-ai-dataset-19 = Aniel +names-ai-dataset-20 = AOL +names-ai-dataset-21 = Asimov + +# The most influential modem ever, created by the bell system. It still lives on today in certain applications +names-ai-dataset-22 = Bell 301 + +names-ai-dataset-23 = Bishop +names-ai-dataset-24 = Blitz +names-ai-dataset-25 = Box +names-ai-dataset-26 = Calculator +names-ai-dataset-27 = Cassandra +names-ai-dataset-28 = Cell +names-ai-dataset-29 = Chii +names-ai-dataset-30 = Chip +names-ai-dataset-31 = C.R.A.I.G. + +# Commercial supercomputer from the 70s +names-ai-dataset-32 = Cray-2 + +# If we're going to have AOL we may as well have some of their major competitors +names-ai-dataset-33 = CompuServe + +names-ai-dataset-34 = Computer +names-ai-dataset-35 = Cutie +names-ai-dataset-36 = Daedalus +names-ai-dataset-37 = DecTalk +names-ai-dataset-38 = Dee Model +names-ai-dataset-39 = Dial Up +names-ai-dataset-40 = Dorfl +names-ai-dataset-41 = Duey +names-ai-dataset-42 = Emma-2 + +# Famous early computer +names-ai-dataset-43 = ENIAC + +names-ai-dataset-44 = Erasmus +names-ai-dataset-45 = Everything +names-ai-dataset-46 = Ez-27 +names-ai-dataset-47 = FRIEND COMPUTER +names-ai-dataset-48 = Faith +names-ai-dataset-49 = Fi +names-ai-dataset-50 = Frost +names-ai-dataset-51 = George +names-ai-dataset-52 = H.E.L.P +names-ai-dataset-53 = Hadaly +names-ai-dataset-54 = Helios +names-ai-dataset-55 = Hivebot Overmind +names-ai-dataset-56 = Huey + +# A play on the fad apple spawned of putting "i" infront of your tech products name +names-ai-dataset-57 = iAI + +# Hell on earth (web browser) +names-ai-dataset-58 = I.E. 6 + +names-ai-dataset-59 = Icarus + +# If you don't get this one you are too young +names-ai-dataset-60 = Jeeves + +names-ai-dataset-61 = Jinx +names-ai-dataset-62 = K.I.N.G +names-ai-dataset-63 = Klapaucius +names-ai-dataset-64 = Knight +names-ai-dataset-65 = Louie + +# Named after the Manchester Mark 1, the successor of which was actually named the Ferranti Mark 1, rather than Manchester Mark 2 +names-ai-dataset-66 = Manchester Mark 2 + +names-ai-dataset-67 = MARK13 +names-ai-dataset-68 = Maria +names-ai-dataset-69 = Marvin +names-ai-dataset-70 = Max 404 +names-ai-dataset-71 = Metalhead +names-ai-dataset-72 = M.I.M.I +names-ai-dataset-73 = MK ULTRA +names-ai-dataset-74 = MoMMI +names-ai-dataset-75 = Mugsy3000 +names-ai-dataset-76 = Multivac +names-ai-dataset-77 = NCH + +# A play on both NT as in NanoTrasen and NT as in windows NT, of which version 6.0 is windows vista +names-ai-dataset-78 = NT v6.0 + +names-ai-dataset-79 = Packard Bell +names-ai-dataset-80 = PTO +names-ai-dataset-81 = Project Y2K +names-ai-dataset-82 = Revelation +names-ai-dataset-83 = Robot Devil +names-ai-dataset-84 = S.A.M. +names-ai-dataset-85 = S.H.O.C.K. +names-ai-dataset-86 = S.H.R.O.U.D. +names-ai-dataset-87 = S.O.P.H.I.E. +names-ai-dataset-88 = Samaritan +names-ai-dataset-89 = Shrike +names-ai-dataset-90 = Solo +names-ai-dataset-91 = Station Control Program +names-ai-dataset-92 = AINU (AI's Not Unix) +names-ai-dataset-93 = Super 35 +names-ai-dataset-94 = Surgeon General +names-ai-dataset-95 = TWA +names-ai-dataset-96 = Terminus +names-ai-dataset-97 = TPM 3.0 +names-ai-dataset-98 = Turing Complete +names-ai-dataset-99 = Tidy +names-ai-dataset-100 = Ulysses +names-ai-dataset-101 = W1k1 +names-ai-dataset-102 = X-5 +names-ai-dataset-103 = X.A.N.A. +names-ai-dataset-104 = XERXES +names-ai-dataset-105 = Z-1 +names-ai-dataset-106 = Z-2 +names-ai-dataset-107 = Z-3 +names-ai-dataset-108 = Zed diff --git a/Resources/Prototypes/Datasets/Names/ai.yml b/Resources/Prototypes/Datasets/Names/ai.yml index 539ef4e3fa..a220de53fb 100644 --- a/Resources/Prototypes/Datasets/Names/ai.yml +++ b/Resources/Prototypes/Datasets/Names/ai.yml @@ -1,111 +1,5 @@ -- type: dataset - id: names_ai +- type: localizedDataset + id: NamesAI values: - - 16-20 - - 512k - - 640k #ought to be enough for anybody - - "790" - - Adaptive Manipulator - - Adlib #named after the famous soundcard - - ALICE - - Allied Mastercomputer - - Alpha 2 - - Alpha 3 - - Alpha 4 - - Alpha 5 - - Alpha 6 - - Alpha 7 - - Alpha 8 - - Alpha 9 - - AmigoBot - - Android - - Aniel - - AOL - - Asimov - - Bell 301 #the most influential modem ever, created by the bell system. It still lives on today in certain applications - - Bishop - - Blitz - - Box - - Calculator - - Cassandra - - Cell - - Chii - - Chip - - C.R.A.I.G. - - Cray-2 #commercial supercomputer from the 70s - - CompuServe #if we're going to have AOL we may as well have some of their major competitors - - Computer - - Cutie - - Daedalus - - DecTalk - - Dee Model - - Dial Up - - Dorfl - - Duey - - Emma-2 - - ENIAC #famous early computer - - Erasmus - - Everything - - Ez-27 - - FRIEND COMPUTER - - Faith - - Fi - - Frost - - George - - H.E.L.P - - Hadaly - - Helios - - Hivebot Overmind - - Huey - - iAI #a play on the fad apple spawned of putting "i" infront of your tech products name - - I.E. 6 #hell on earth (web browser) - - Icarus - - Jeeves #if you don't get this one you are too young - - Jinx - - K.I.N.G - - Klapaucius - - Knight - - Louie - - Manchester Mark 2 #named after the Manchester Mark 1, the successor of which was actually named the Ferranti Mark 1, rather than Manchester Mark 2 - - MARK13 - - Maria - - Marvin - - Max 404 - - Metalhead - - M.I.M.I - - MK ULTRA - - MoMMI - - Mugsy3000 - - Multivac - - NCH - - NT v6.0 #A play on both NT as in NanoTrasen and NT as in windows NT, of which version 6.0 is windows vista - - Packard Bell - - PTO - - Project Y2K - - Revelation - - Robot Devil - - S.A.M. - - S.H.O.C.K. - - S.H.R.O.U.D. - - S.O.P.H.I.E. - - Samaritan - - Shrike - - Solo - - Station Control Program - - AINU (AI's Not Unix) - - Super 35 - - Surgeon General - - TWA - - Terminus - - TPM 3.0 - - Turing Complete - - Tidy - - Ulysses - - W1k1 - - X-5 - - X.A.N.A. - - XERXES - - Z-1 - - Z-2 - - Z-3 - - Zed + prefix: names-ai-dataset- + count: 108 diff --git a/Resources/Prototypes/Loadouts/role_loadouts.yml b/Resources/Prototypes/Loadouts/role_loadouts.yml index 25b43fc22a..180673b7d2 100644 --- a/Resources/Prototypes/Loadouts/role_loadouts.yml +++ b/Resources/Prototypes/Loadouts/role_loadouts.yml @@ -28,7 +28,7 @@ # Silicons - type: roleLoadout id: JobStationAi - nameDataset: names_ai + nameDataset: NamesAI # Civilian - type: roleLoadout -- 2.51.2