From: lzk <124214523+lzk228@users.noreply.github.com> Date: Fri, 18 Apr 2025 02:32:03 +0000 (+0200) Subject: Allow clown mime and borg customize names (#35170) X-Git-Url: https://git.smokeofanarchy.ru/gitweb.cgi?a=commitdiff_plain;h=8ff7767c853a74633c24bf0d81af7d225afc50a9;p=space-station-14.git Allow clown mime and borg customize names (#35170) * Allow clown mime and borg customize name * how * uh * 3 * good commit --- diff --git a/Content.Server/Station/Systems/StationSpawningSystem.cs b/Content.Server/Station/Systems/StationSpawningSystem.cs index a77716eddf..d9c80c19dd 100644 --- a/Content.Server/Station/Systems/StationSpawningSystem.cs +++ b/Content.Server/Station/Systems/StationSpawningSystem.cs @@ -162,6 +162,17 @@ public sealed class StationSpawningSystem : SharedStationSpawningSystem profile = HumanoidCharacterProfile.RandomWithSpecies(speciesId); } + if (profile != null) + { + _humanoidSystem.LoadProfile(entity.Value, profile); + _metaSystem.SetEntityName(entity.Value, profile.Name); + + if (profile.FlavorText != "" && _configurationManager.GetCVar(CCVars.FlavorText)) + { + AddComp(entity.Value).Content = profile.FlavorText; + } + } + if (loadout != null) { EquipRoleLoadout(entity.Value, loadout, roleProto!); @@ -176,17 +187,9 @@ public sealed class StationSpawningSystem : SharedStationSpawningSystem var gearEquippedEv = new StartingGearEquippedEvent(entity.Value); RaiseLocalEvent(entity.Value, ref gearEquippedEv); - if (profile != null) + if (prototype != null && TryComp(entity.Value, out var metaData)) { - if (prototype != null) - SetPdaAndIdCardData(entity.Value, profile.Name, prototype, station); - - _humanoidSystem.LoadProfile(entity.Value, profile); - _metaSystem.SetEntityName(entity.Value, profile.Name); - if (profile.FlavorText != "" && _configurationManager.GetCVar(CCVars.FlavorText)) - { - AddComp(entity.Value).Content = profile.FlavorText; - } + SetPdaAndIdCardData(entity.Value, metaData.EntityName, prototype, station); } DoJobSpecials(job, entity.Value); diff --git a/Resources/Prototypes/Loadouts/role_loadouts.yml b/Resources/Prototypes/Loadouts/role_loadouts.yml index c2e154798b..a304adeb3a 100644 --- a/Resources/Prototypes/Loadouts/role_loadouts.yml +++ b/Resources/Prototypes/Loadouts/role_loadouts.yml @@ -26,10 +26,10 @@ - GroupSpeciesBreathTool # Silicons -#- type: roleLoadout -# id: JobBorg -# nameDataset: roleloadout doesn't support both so need to update that first. -# canCustomizeName: true +- type: roleLoadout + id: JobBorg + nameDataset: NamesBorg + canCustomizeName: true - type: roleLoadout id: JobStationAi @@ -159,6 +159,7 @@ - type: roleLoadout id: JobClown + canCustomizeName: true groups: - GroupTankHarness - ClownHead @@ -172,6 +173,7 @@ - type: roleLoadout id: JobMime + canCustomizeName: true groups: - GroupTankHarness - MimeHead