Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
TheGamerdk committed Aug 3, 2023
1 parent fda753f commit 420ff15
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 12 deletions.
2 changes: 0 additions & 2 deletions code/modules/cm_marines/overwatch.dm
Original file line number Diff line number Diff line change
Expand Up @@ -236,8 +236,6 @@

if(!istype(marine_human.head, /obj/item/clothing/head/helmet/marine))
has_helmet = FALSE
else
var/obj/item/clothing/head/helmet/marine

if(!marine_human.key || !marine_human.client)
if(marine_human.stat != DEAD)
Expand Down
24 changes: 14 additions & 10 deletions tgui/packages/tgui/interfaces/OverwatchConsole.js
Original file line number Diff line number Diff line change
Expand Up @@ -240,8 +240,8 @@ const RoleTable = (props, context) => {
{(squad_leader && (
<Table.Cell textAlign="center">
{squad_leader.name ? squad_leader.name : 'NONE'}
<Box color={leaders_alive ? 'green' : 'red'}>
{leaders_alive ? 'ALIVE' : 'DEAD'}
<Box color={squad_leader.state !== 'Dead' ? 'green' : 'red'}>
{squad_leader.state !== 'Dead' ? 'ALIVE' : 'DEAD'}
</Box>
</Table.Cell>
)) || (
Expand Down Expand Up @@ -461,8 +461,10 @@ const SquadMonitor = (props, context) => {
return marine;
})
.map((marine, index) => {
if (marine.role === 'Squad Leader' || marine.acting_sl) {
return;
if (squad_leader) {
if (marine.ref === squad_leader.ref) {
return;
}
}
if (hidden_marines.includes(marine.ref) && !showHiddenMarines) {
return;
Expand All @@ -474,12 +476,14 @@ const SquadMonitor = (props, context) => {
return (
<Table.Row key="index">
<Table.Cell p="2px">
<Button
onClick={() =>
act('watch_camera', { target_ref: marine.ref })
}>
{marine.name}
</Button>
{(marine.has_helmet && (
<Button
onClick={() =>
act('watch_camera', { target_ref: marine.ref })
}>
{marine.name}
</Button>
)) || <Box color="red">{marine.name} (NO HELMET)</Box>}
</Table.Cell>
<Table.Cell p="2px">{marine.role}</Table.Cell>
<Table.Cell
Expand Down

0 comments on commit 420ff15

Please sign in to comment.