Skip to content

Commit 25312af

Browse files
authored
1 parent 1b89586 commit 25312af

File tree

4 files changed

+21
-5
lines changed

4 files changed

+21
-5
lines changed

code/modules/mob/living/carbon/human/human_update_icons.dm

+16
Original file line numberDiff line numberDiff line change
@@ -227,10 +227,26 @@ There are several things that need to be remembered:
227227

228228
if(!gloves_overlay)
229229
return
230+
230231
if(!handled_by_bodytype && (OFFSET_GLOVES in dna.species.offset_features))
231232
gloves_overlay.pixel_x += dna.species.offset_features[OFFSET_GLOVES][1]
232233
gloves_overlay.pixel_y += dna.species.offset_features[OFFSET_GLOVES][2]
234+
235+
// We dont have any >2 hands human species (and likely wont ever), so theres no point in splitting this because:
236+
// It will only run if the left hand OR the right hand is missing, and it wont run if both are missing because you cant wear gloves with no arms
237+
// (unless admins mess with this then its their fault)
238+
if(num_hands < default_num_hands)
239+
var/static/atom/movable/alpha_filter_target
240+
if(isnull(alpha_filter_target))
241+
alpha_filter_target = new(null)
242+
alpha_filter_target.icon = 'icons/masks/handless.dmi'
243+
alpha_filter_target.icon_state = "missing[!has_left_hand(check_disabled = FALSE) ? "l" : "r"]"
244+
alpha_filter_target.render_target = "*MissGlove [REF(src)] [!has_left_hand(check_disabled = FALSE) ? "L" : "R"]"
245+
gloves_overlay.add_overlay(alpha_filter_target)
246+
gloves_overlay.filters += filter(type="alpha", render_source=alpha_filter_target.render_target, flags=MASK_INVERSE)
247+
233248
overlays_standing[GLOVES_LAYER] = gloves_overlay
249+
234250
apply_overlay(GLOVES_LAYER)
235251

236252

code/modules/mob/living/carbon/human/species.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -758,7 +758,7 @@ GLOBAL_LIST_EMPTY(features_by_species)
758758
return H.equip_delay_self_check(I, bypass_equip_delay_self)
759759

760760
if(ITEM_SLOT_GLOVES)
761-
if(H.num_hands < 2)
761+
if(H.num_hands == 0)
762762
return FALSE
763763
return H.equip_delay_self_check(I, bypass_equip_delay_self)
764764

code/modules/surgery/bodyparts/dismemberment.dm

+4-4
Original file line numberDiff line numberDiff line change
@@ -281,10 +281,10 @@
281281
var/atom/movable/screen/inventory/hand/associated_hand = arm_owner.hud_used.hand_slots["[held_index]"]
282282
if(associated_hand)
283283
associated_hand.update_appearance()
284-
if(arm_owner.gloves)
285-
arm_owner.dropItemToGround(arm_owner.gloves, TRUE)
286-
arm_owner.update_worn_gloves() //to remove the bloody hands overlay
287-
return ..()
284+
. = ..()
285+
if(arm_owner.num_hands == 0)
286+
arm_owner.dropItemToGround(arm_owner.gloves, TRUE)
287+
arm_owner.update_worn_gloves() //to remove the bloody hands overlay
288288

289289
/obj/item/bodypart/leg/drop_limb(special)
290290
if(owner && !special)

icons/masks/handless.dmi

261 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)