From df61452e94b1f3ddf041c121adecbd3bc673ea13 Mon Sep 17 00:00:00 2001 From: Jamie D <993128+JamieD1@users.noreply.github.com> Date: Sat, 19 Jun 2021 20:07:55 +0100 Subject: [PATCH] Revert "Fixed and Tweaked Some Stuff With the Crew Console Interface (#11570)" This reverts commit b754ba1a8ded706f11f3fc7d2dfd577fd4d1ed9e. --- code/game/machinery/computer/crew.dm | 19 ++++++++------ tgui/packages/tgui/constants.js | 1 - tgui/packages/tgui/interfaces/CrewConsole.js | 26 +++++++++++++++----- 3 files changed, 31 insertions(+), 15 deletions(-) diff --git a/code/game/machinery/computer/crew.dm b/code/game/machinery/computer/crew.dm index c8d067f17013..44c1a72e11cc 100644 --- a/code/game/machinery/computer/crew.dm +++ b/code/game/machinery/computer/crew.dm @@ -42,16 +42,12 @@ GLOBAL_DATUM_INIT(crewmonitor, /datum/crewmonitor, new) jobs["Geneticist"] = 22 jobs["Virologist"] = 23 jobs["Medical Doctor"] = 24 - jobs["Paramedic"] = 25 //Yogs: Added IDs for this job - jobs["Psychiatrist"] = 26 //Yogs: Added IDs for this job - jobs["Mining Medic"] = 27 //Yogs: Added IDs for this job jobs["Research Director"] = 30 jobs["Scientist"] = 31 jobs["Roboticist"] = 32 jobs["Chief Engineer"] = 40 jobs["Station Engineer"] = 41 jobs["Atmospheric Technician"] = 42 - jobs["Signal Technician"] = 43 //Yogs: Added IDs for this job jobs["Quartermaster"] = 51 jobs["Shaft Miner"] = 52 jobs["Cargo Technician"] = 53 @@ -64,9 +60,6 @@ GLOBAL_DATUM_INIT(crewmonitor, /datum/crewmonitor, new) jobs["Mime"] = 67 jobs["Janitor"] = 68 jobs["Lawyer"] = 69 - jobs["Clerk"] = 71 //Yogs: Added IDs for this job, also need to skip 70 or it clerk would be considered a head job - jobs["Tourist"] = 72 //Yogs: Added IDs for this job - jobs["Artist"] = 73 //Yogs: Added IDs for this job jobs["Admiral"] = 200 jobs["CentCom Commander"] = 210 jobs["Custodian"] = 211 @@ -103,7 +96,17 @@ GLOBAL_DATUM_INIT(crewmonitor, /datum/crewmonitor, new) if(!z) var/turf/T = get_turf(user) z = T.z + var/list/zdata = update_data(z) . = list() + var/datum/minimap/M = SSmapping.station_minimaps[1] + .["sensors"] = zdata + .["link_allowed"] = isAI(user) + .["z"] = z + .["minx"] = M.minx + .["miny"] = M.miny + .["maxx"] = M.maxx + .["maxy"] = M.maxy + .["map_filename"] = SSassets.transport.get_asset_url("minimap-1.png") /datum/crewmonitor/proc/update_data(z) if(data_by_z["[z]"] && last_update["[z]"] && world.time <= last_update["[z]"] + SENSORS_UPDATE_PERIOD) @@ -198,4 +201,4 @@ GLOBAL_DATUM_INIT(crewmonitor, /datum/crewmonitor, new) if ("select_person") AI.ai_camera_track(params["name"]) -#undef SENSORS_UPDATE_PERIOD +#undef SENSORS_UPDATE_PERIOD \ No newline at end of file diff --git a/tgui/packages/tgui/constants.js b/tgui/packages/tgui/constants.js index 26424dae50f3..92c1f80e6c04 100644 --- a/tgui/packages/tgui/constants.js +++ b/tgui/packages/tgui/constants.js @@ -20,7 +20,6 @@ export const COLORS = { science: '#9b59b6', engineering: '#f1c40f', cargo: '#f39c12', - civilian: '#535353', // Yogs: Added new civilian color centcom: '#00c100', other: '#c38312', }, diff --git a/tgui/packages/tgui/interfaces/CrewConsole.js b/tgui/packages/tgui/interfaces/CrewConsole.js index a607024f0e4e..e3c184078c1b 100644 --- a/tgui/packages/tgui/interfaces/CrewConsole.js +++ b/tgui/packages/tgui/interfaces/CrewConsole.js @@ -33,15 +33,9 @@ const jobToColor = jobId => { if (jobId >= 50 && jobId < 60) { return COLORS.department.cargo; } - if (jobId >= 60 && jobId < 80) { // Yogs: Extended this to 80 as we have more than 9 civilian jobs - return COLORS.department.civilian; // Yogs: Also added a new civilian color - } if (jobId >= 200 && jobId < 230) { return COLORS.department.centcom; } - if (jobId === 999) { // Yogs Start: Assistants need the new color too - return COLORS.department.civilian; - } // Yogs End return COLORS.department.other; }; @@ -76,6 +70,26 @@ export const CrewConsole = (props, context) => { resizable> + +
+ {data.z === 2 && ( +
+ {data["sensors"].map(sensor => ( + sensor.pos_x && ( +
+ ) + ))} + +
+ )} +
+