From de81fdd4ac4d766bc0742d8c0a85704aa098fefd Mon Sep 17 00:00:00 2001 From: Mark Aherne Date: Sat, 19 Jul 2014 03:38:50 +0100 Subject: [PATCH] Added PDA check in wear_id slot to get any potential id rank. --- code/game/machinery/computer/crew.dm | 16 +++++++--- nano/css/icons.css | 48 ++++++++++++++++++++++++++++ 2 files changed, 60 insertions(+), 4 deletions(-) diff --git a/code/game/machinery/computer/crew.dm b/code/game/machinery/computer/crew.dm index 01d02128616..81ea44b5bd3 100644 --- a/code/game/machinery/computer/crew.dm +++ b/code/game/machinery/computer/crew.dm @@ -84,10 +84,18 @@ crewmemberData["tox"] = round(H.getToxLoss(), 1) crewmemberData["fire"] = round(H.getFireLoss(), 1) crewmemberData["brute"] = round(H.getBruteLoss(), 1) - crewmemberData["name"] = (H.wear_id ? H.wear_id.name : "Unknown") - crewmemberData["rank"] = "Unknown" - if(H.wear_id && istype(H.wear_id, /obj/item/weapon/card/id)) - crewmemberData["rank"] = H.wear_id:rank + + crewmemberData["name"] = "Unknown" + crewmemberData["rank"] = "Unknown" + if(H.wear_id && istype(H.wear_id, /obj/item/weapon/card/id) ) + var/obj/item/weapon/card/id/I = H.wear_id + crewmemberData["name"] = I.name + crewmemberData["rank"] = I.rank + else if(H.wear_id && istype(H.wear_id, /obj/item/device/pda) ) + var/obj/item/device/pda/P = H.wear_id + crewmemberData["name"] = (P.id ? P.id.name : "Unknown") + crewmemberData["rank"] = (P.id ? P.id.rank : "Unknown") + crewmemberData["area"] = get_area(H) crewmemberData["x"] = pos.x crewmemberData["y"] = pos.y diff --git a/nano/css/icons.css b/nano/css/icons.css index 830474518ab..e7a9e919a6e 100644 --- a/nano/css/icons.css +++ b/nano/css/icons.css @@ -239,6 +239,8 @@ .mapIcon16.dead { background-image: url(uiIcons16Red.png); } + +/* Command Positions */ .mapIcon16.rank-captain { background-position: -224px -112px; } @@ -258,4 +260,50 @@ background-position: -32px -128px; } +/* Engineering Positions */ +.mapIcon16.rank-stationengineer { + background-position: -176px -112px; +} +.mapIcon16.rank-atmospherictechnician { + background-position: -176px -112px; +} + +/* Medical Positions */ +.mapIcon16.rank-medicaldoctor { + background-position: -32px -128px; +} +.mapIcon16.rank-geneticist { + background-position: -32px -128px; +} +.mapIcon16.rank-psychiatrist { + background-position: -32px -128px; +} +.mapIcon16.rank-chemist { + background-position: -32px -128px; +} + +/* Science Positions */ +.mapIcon16.rank-scientist { + background-position: -128px -128px; +} +.mapIcon16.rank-geneticist { + background-position: -128px -128px; +} +.mapIcon16.rank-roboticist { + background-position: -128px -128px; +} +.mapIcon16.rank-xenobiologist { + background-position: -128px -128px; +} + +/* Security Positions */ +.mapIcon16.rank-warden { + background-position: -112px -128px; +} +.mapIcon16.rank-detective { + background-position: -112px -128px; +} +.mapIcon16.rank-securityofficer { + background-position: -112px -128px; +}