From 86334bbc9cfd157fb82c69e5934874a445b7652d Mon Sep 17 00:00:00 2001 From: Zonespace <41448081+Zonespace27@users.noreply.github.com> Date: Fri, 28 Apr 2023 16:18:21 -0700 Subject: [PATCH] Allows the surgery body zone selector to use other UI themes (#74957) ## About The Pull Request Allows uses of the body zone selector for non-base TGUI themes (that look good, that is), doesn't add any to the asset cache, however, as this is just groundwork ## Why It's Good For The Game The potential of things for looking better for other TGUI themes ## Changelog Nothing player-facing --- code/modules/asset_cache/assets/body_zones.dm | 2 +- tgui/packages/tgui/components/BodyZoneSelector.tsx | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/code/modules/asset_cache/assets/body_zones.dm b/code/modules/asset_cache/assets/body_zones.dm index 10f384aa0e5..cbdf268f6c1 100644 --- a/code/modules/asset_cache/assets/body_zones.dm +++ b/code/modules/asset_cache/assets/body_zones.dm @@ -5,7 +5,7 @@ /datum/asset/simple/body_zones /datum/asset/simple/body_zones/register() - assets["body_zones.base.png"] = icon('icons/hud/screen_midnight.dmi', "zone_sel") + assets["body_zones.base_midnight.png"] = icon('icons/hud/screen_midnight.dmi', "zone_sel") add_limb(BODY_ZONE_HEAD) add_limb(BODY_ZONE_CHEST) diff --git a/tgui/packages/tgui/components/BodyZoneSelector.tsx b/tgui/packages/tgui/components/BodyZoneSelector.tsx index c9248bf9095..cf8dc430e2b 100644 --- a/tgui/packages/tgui/components/BodyZoneSelector.tsx +++ b/tgui/packages/tgui/components/BodyZoneSelector.tsx @@ -57,6 +57,7 @@ type BodyZoneSelectorProps = { onClick?: (zone: BodyZone) => void; scale?: number; selectedZone: BodyZone | null; + theme?: string; }; type BodyZoneSelectorState = { @@ -74,7 +75,7 @@ export class BodyZoneSelector extends Component< render() { const { hoverZone } = this.state; - const { scale = 3, selectedZone } = this.props; + const { scale = 3, selectedZone, theme = 'midnight' } = this.props; return (
{ const onClick = this.props.onClick; if (onClick && this.state.hoverZone) {