Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions code/datums/greyscale/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -143,12 +143,12 @@ Building on this, if your obj and worn sprites have the same amount of component

```c
/datum/greyscale_config/trek
name = "Trek Uniform"
name = "Retro Department Uniform"
icon_file = 'icons/obj/clothing/under/trek.dmi'
json_config = 'code/datums/greyscale/json_configs/trek.json'

/datum/greyscale_config/trek/worn
name = "Worn Trek Uniform"
name = "Worn Retro Department Uniform"
icon_file = 'icons/mob/clothing/under/trek.dmi'
//The worn json is exactly the same, and both icon files use identically-named component states; so, we can just inherit the json!
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -304,13 +304,13 @@
icon_file = 'icons/mob/clothing/under/ethereal.dmi'

/datum/greyscale_config/trek
name = "Trek Uniform"
name = "Retro Department Uniform"
icon_file = 'icons/obj/clothing/under/trek.dmi'
json_config = 'code/datums/greyscale/json_configs/trek.json'
//All Trek uniforms are different icon_states in the same json so we dont have seperate jsons for all the different types
// All retro department uniforms are different icon_states in the same json, so we do not have separate jsons for each type.

/datum/greyscale_config/trek/worn
name = "Trek Uniform (Worn)"
name = "Retro Department Uniform (Worn)"
icon_file = 'icons/mob/clothing/under/trek.dmi'

// DRESSES AND SKIRTS
Expand Down
28 changes: 14 additions & 14 deletions code/modules/clothing/under/trek.dm
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
//Just some alt-uniforms themed around Star Trek - Pls don't sue, Mr Roddenberry ;_;
// Retro department uniforms for themed away sites and costume crates.

/obj/item/clothing/under/trek
can_adjust = FALSE
icon = 'icons/obj/clothing/under/trek.dmi'
worn_icon = 'icons/mob/clothing/under/trek.dmi'

/*
* The Original Series (Technically not THE original because these have a black undershirt while the very-original didn't but IDC)
* Classic three-division pattern
*/
/obj/item/clothing/under/trek/command
name = "command uniform"
desc = "An outdated uniform worn by command officers."
name = "retro command uniform"
desc = "An outdated gold uniform worn by command officers."
inhand_icon_state = "y_suit"
icon = 'icons/map_icons/clothing/under/_under.dmi'
icon_state = "/obj/item/clothing/under/trek/command"
Expand All @@ -20,19 +20,19 @@
greyscale_colors = "#fab342"

/obj/item/clothing/under/trek/engsec
name = "engsec uniform"
desc = "An outdated uniform worn by engineering/security officers."
name = "retro engineering-security uniform"
desc = "An outdated slate uniform worn by engineering and security officers."
icon = 'icons/map_icons/clothing/under/_under.dmi'
icon_state = "/obj/item/clothing/under/trek/engsec"
post_init_icon_state = "trek_tos_sec"
inhand_icon_state = "r_suit"
inhand_icon_state = "bl_suit"
greyscale_config = /datum/greyscale_config/trek
greyscale_config_worn = /datum/greyscale_config/trek/worn
greyscale_colors = "#B72B2F"
greyscale_colors = "#4E6F78"

/obj/item/clothing/under/trek/medsci
name = "medsci uniform"
desc = "An outdated worn by medical/science officers."
name = "retro medical-science uniform"
desc = "An outdated blue uniform worn by medical and science officers."
icon = 'icons/map_icons/clothing/under/_under.dmi'
icon_state = "/obj/item/clothing/under/trek/medsci"
post_init_icon_state = "trek_tos"
Expand All @@ -42,11 +42,11 @@
greyscale_colors = "#5FA4CC"

/*
* The Next Generation
* Later split-front pattern
*/
/obj/item/clothing/under/trek/command/next
icon_state = "/obj/item/clothing/under/trek/command/next"
post_init_icon_state = "trek_next" //Technically TNG had Command wearing red, but bc gold is closer to command roles for SS13 we're taking some liberties
post_init_icon_state = "trek_next"

/obj/item/clothing/under/trek/engsec/next
icon_state = "/obj/item/clothing/under/trek/engsec/next"
Expand All @@ -57,7 +57,7 @@
post_init_icon_state = "trek_next"

/*
* Voyager
* Away-fleet pattern
*/
/obj/item/clothing/under/trek/command/voy
icon_state = "/obj/item/clothing/under/trek/command/voy"
Expand All @@ -72,7 +72,7 @@
post_init_icon_state = "trek_voy"

/*
* Enterprise
* Utility jumpsuit pattern
*/
/obj/item/clothing/under/trek/command/ent
icon_state = "/obj/item/clothing/under/trek/command/ent"
Expand Down
Binary file modified icons/map_icons/clothing/under/_under.dmi
Binary file not shown.
2 changes: 1 addition & 1 deletion tgui/packages/tgui-dev-server/link/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ function serializeObject(obj: Record<string, any>): string {
// Error object
const isError =
value instanceof Error ||
(value.code && value.message && value.message.includes('Error'));
(value.code && value.message?.includes('Error'));
if (isError) {
return {
__error__: true,
Expand Down
4 changes: 2 additions & 2 deletions tgui/packages/tgui/interfaces/AtmosControlConsole.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export const AtmosControlConsole = (props) => {
<Section
title={selectedChamber ? selectedChamber.name : 'Chamber Reading'}
buttons={
!!data.reconnecting && (
data.reconnecting && (
<Button
icon="undo"
content="Reconnect"
Expand All @@ -70,7 +70,7 @@ export const AtmosControlConsole = (props) => {
)
}
>
{!!selectedChamber && !!selectedChamber.gasmix ? (
{selectedChamber?.gasmix ? (
<GasmixParser
gasmix={selectedChamber.gasmix}
gasesOnClick={setActiveGasId}
Expand Down
2 changes: 1 addition & 1 deletion tgui/packages/tgui/interfaces/Cargo/CargoCart.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ function CheckoutItems(props) {
<Table.Cell>{entry.object}</Table.Cell>

<Table.Cell width={11}>
{!!can_send && !!entry.can_be_cancelled ? (
{can_send && entry.can_be_cancelled ? (
<>
<Button
icon="minus"
Expand Down
2 changes: 1 addition & 1 deletion tgui/packages/tgui/interfaces/Cargo/CargoStatus.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export function CargoStatus(props) {
>
<LabeledList>
<LabeledList.Item label="Shuttle">
{!!docked && !requestonly && !!can_send ? (
{docked && !requestonly && can_send ? (
<Button
color={grocery ? 'orange' : 'green'}
tooltip={
Expand Down
2 changes: 1 addition & 1 deletion tgui/packages/tgui/interfaces/Flatpacker.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ const BoardPreview = (props: BoardPreviewProps) => {
icon="cog"
fontSize={1.2}
textAlign="center"
disabled={!design || design.disableReason !== ''}
disabled={design?.disableReason !== ''}
tooltip={design.disableReason}
tooltipPosition="bottom"
onClick={() => onPrint()}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { NtosWindow } from '../layouts';
import { useBackend } from '../backend';
import { SeedTable, SeedData, TraitData } from './SeedTable';
import { SeedTable, type SeedData, type TraitData } from './SeedTable';

type Data = {
seeds: SeedData[];
Expand Down
2 changes: 1 addition & 1 deletion tgui/packages/tgui/interfaces/NtosRadar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ const TargetDisplay = (props) => {
if (!selected || !target) {
return null;
}
if (!Object.keys(target).length && !!selected) {
if (!Object.keys(target).length && selected) {
return (
<NoticeBox
position="absolute"
Expand Down
2 changes: 1 addition & 1 deletion tgui/packages/tgui/interfaces/Orbit/OrbitBlade.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ function OrbitInfo(props) {
const { name, full_name, health, job } = orbiting;

let department;
if ('job' in orbiting && !!job) {
if ('job' in orbiting && job) {
department = getDepartmentByJob(job);
}

Expand Down
2 changes: 1 addition & 1 deletion tgui/packages/tgui/interfaces/Orbit/OrbitTooltip.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export function OrbitTooltip(props: Props) {
}

const extraInfo = extra?.split(':');
const displayHealth = !!health && health >= 0 ? `${health}%` : 'Critical';
const displayHealth = health && health >= 0 ? `${health}%` : 'Critical';
const showAFK = 'client' in item && !item.client;
const displayJob = realNameDisplay ? mind_job : job;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { sortBy } from 'es-toolkit';
import { type PropsWithChildren, type ReactNode, useState } from 'react';
import { useBackend } from 'tgui/backend';
import {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ export const ServerPrefs = createContext<ServerData | undefined>({
jobs: {
departments: {},
jobs: {},
jobs_sorted: [],
},
names: {
types: {},
Expand Down
2 changes: 1 addition & 1 deletion tgui/packages/tgui/interfaces/PrisonerManagement.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ const AllImplantDisplay = (props: { implants: ImplantInfo[] }) => {
</Tabs>
</Stack.Item>
<Stack.Item>
{implantTab && implantsByCategory && implantsByCategory[implantTab] ? (
{implantTab && implantsByCategory?.[implantTab] ? (
implantsByCategory[implantTab].map((implant) => (
<ImplantDisplay key={implant.ref} implant={implant} />
))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ const CrimeDisplay = ({ item }: { item: Crime }) => {
const { current_user, higher_access } = data;
const { author, crime_ref, details, fine, name, paid, time, valid, voider } =
item;
const showFine = !!fine && fine > 0 ? `: ${fine} cr` : ': PAID OFF';
const showFine = fine && fine > 0 ? `: ${fine} cr` : ': PAID OFF';

let collapsibleColor = '';
if (!valid) {
Expand Down
2 changes: 1 addition & 1 deletion tgui/packages/tgui/interfaces/StationAlertConsole.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export const StationAlertConsoleContent = (props) => {
<Stack.Item grow>
<li className="color-average">
{alert.name}{' '}
{!!cameraView && alert.sources > 1
{cameraView && alert.sources > 1
? ` (${alert.sources} sources)`
: ''}
</li>
Expand Down
2 changes: 1 addition & 1 deletion tgui/packages/tgui/interfaces/Techweb/nodes/TechNode.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ export function TechNode(props: Props) {
!nocontrols && (
<>
{tier > 0 &&
(!!can_unlock && (is_free || queue_nodes.length === 0) ? (
(can_unlock && (is_free || queue_nodes.length === 0) ? (
<Button
icon="lightbulb"
disabled={!can_unlock || tier > 1 || queue_nodes.length > 0}
Expand Down
Loading