diff --git a/Content.Client/Administration/UI/Tabs/AdminTab/AdminTab.xaml b/Content.Client/Administration/UI/Tabs/AdminTab/AdminTab.xaml index 8b68487547f..b558d6114ed 100644 --- a/Content.Client/Administration/UI/Tabs/AdminTab/AdminTab.xaml +++ b/Content.Client/Administration/UI/Tabs/AdminTab/AdminTab.xaml @@ -3,6 +3,7 @@ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:cc="clr-namespace:Content.Client.Administration.UI.CustomControls" xmlns:at="clr-namespace:Content.Client.Administration.UI.Tabs.AdminTab" + xmlns:cdAdmin="clr-namespace:Content.Client._CD.Admin.UI" Margin="4" MinSize="50 50"> @@ -16,6 +17,8 @@ + + diff --git a/Content.Client/Humanoid/HumanoidAppearanceSystem.cs b/Content.Client/Humanoid/HumanoidAppearanceSystem.cs index 5bae35da5ba..f0b30601176 100644 --- a/Content.Client/Humanoid/HumanoidAppearanceSystem.cs +++ b/Content.Client/Humanoid/HumanoidAppearanceSystem.cs @@ -1,8 +1,10 @@ +using System.Numerics; using Content.Shared.Humanoid; using Content.Shared.Humanoid.Markings; using Content.Shared.Humanoid.Prototypes; using Content.Shared.Preferences; using Robust.Client.GameObjects; +using Robust.Client.Console; using Robust.Shared.Prototypes; using Robust.Shared.Utility; @@ -12,6 +14,8 @@ public sealed class HumanoidAppearanceSystem : SharedHumanoidAppearanceSystem { [Dependency] private readonly IPrototypeManager _prototypeManager = default!; [Dependency] private readonly MarkingManager _markingManager = default!; + [Dependency] private readonly IEntityManager _entityManager = default!; + [Dependency] private readonly IClientConsoleHost _consoleHost = default!; public override void Initialize() { @@ -30,6 +34,11 @@ private void UpdateSprite(HumanoidAppearanceComponent component, SpriteComponent UpdateLayers(component, sprite); ApplyMarkingSet(component, sprite); + var speciesPrototype = _prototypeManager.Index(component.Species); + var height = Math.Clamp(MathF.Round(component.Height, 1), speciesPrototype.MinHeight, speciesPrototype.MaxHeight); // should NOT be locked, at all + + sprite.Scale = new Vector2(speciesPrototype.ScaleHeight ? height : 1f, height); + sprite[sprite.LayerMapReserveBlank(HumanoidVisualLayers.Eyes)].Color = component.EyeColor; } @@ -194,6 +203,7 @@ public override void LoadProfile(EntityUid uid, HumanoidCharacterProfile profile humanoid.Species = profile.Species; humanoid.SkinColor = profile.Appearance.SkinColor; humanoid.EyeColor = profile.Appearance.EyeColor; + humanoid.Height = profile.Height; UpdateSprite(humanoid, Comp(uid)); } diff --git a/Content.Client/Preferences/UI/HumanoidProfileEditor.xaml b/Content.Client/Preferences/UI/HumanoidProfileEditor.xaml index d0dd02a58ad..15ce473c6ff 100644 --- a/Content.Client/Preferences/UI/HumanoidProfileEditor.xaml +++ b/Content.Client/Preferences/UI/HumanoidProfileEditor.xaml @@ -67,6 +67,14 @@ + + +