Merge pull request #6180 from Citadel-Station-13/upstream-merge-36781

[MIRROR] Get_Flat_Human_Icon no longer draws asses that nobody wants
This commit is contained in:
LetterJay
2018-03-31 18:39:15 -05:00
committed by GitHub
3 changed files with 16 additions and 27 deletions
+9 -5
View File
@@ -199,6 +199,7 @@
/datum/datacore/proc/manifest_inject(mob/living/carbon/human/H, client/C)
set waitfor = FALSE
var/static/list/show_directions = list(SOUTH, WEST)
if(H.mind && (H.mind.assigned_role != H.mind.special_role))
var/assignment
if(H.mind.assigned_role)
@@ -212,11 +213,14 @@
var/id = num2hex(record_id_num++,6)
if(!C)
C = H.client
var/image = get_id_photo(H, C)
var/image = get_id_photo(H, C, show_directions)
var/obj/item/photo/photo_front = new()
var/obj/item/photo/photo_side = new()
photo_front.photocreate(null, icon(image, dir = SOUTH))
photo_side.photocreate(null, icon(image, dir = WEST))
for(var/D in show_directions)
if(D == SOUTH)
photo_front.photocreate(null, icon(image, dir = D))
if(D == WEST || D == EAST)
photo_side.photocreate(null, icon(image, dir = D))
//These records should ~really~ be merged or something
//General Record
@@ -279,11 +283,11 @@
locked += L
return
/datum/datacore/proc/get_id_photo(mob/living/carbon/human/H, client/C)
/datum/datacore/proc/get_id_photo(mob/living/carbon/human/H, client/C, show_directions = list(SOUTH))
var/datum/job/J = SSjob.GetJob(H.mind.assigned_role)
var/datum/preferences/P
if(!C)
C = H.client
if(C)
P = C.prefs
return get_flat_human_icon(null, J, P, DUMMY_HUMAN_SLOT_MANIFEST)
return get_flat_human_icon(null, J, P, DUMMY_HUMAN_SLOT_MANIFEST, show_directions)