diff --git a/code/modules/clothing/suits/_suits.dm b/code/modules/clothing/suits/_suits.dm index 6806f73c65..27fca5a335 100644 --- a/code/modules/clothing/suits/_suits.dm +++ b/code/modules/clothing/suits/_suits.dm @@ -27,10 +27,11 @@ if(ishuman(M) && M.w_uniform) var/obj/item/clothing/under/U = M.w_uniform //SANDSTORM EDIT - if(istype(U) && length(U.attached_accessories)) + if(istype(U) && !CHECK_BITFIELD(U.flags_inv, HIDEACCESSORY)) for(var/obj/item/clothing/accessory/attached in U.attached_accessories) - if(attached.above_suit) - . += U.accessory_overlays + if(CHECK_BITFIELD(attached.flags_inv, HIDEACCESSORY) || attached.above_suit) + continue + . += attached.build_worn_icon() //SANDSTORM EDIT END /obj/item/clothing/suit/update_clothes_damaged_state() diff --git a/code/modules/clothing/under/_under.dm b/code/modules/clothing/under/_under.dm index 7914dc0e72..cd558d2978 100644 --- a/code/modules/clothing/under/_under.dm +++ b/code/modules/clothing/under/_under.dm @@ -24,8 +24,7 @@ var/dummy_thick = FALSE // is able to hold accessories on its item //SANDSTORM EDIT - Removed the old attached accessory system. We use a list of accessories instead. var/max_accessories = 3 - var/list/obj/item/clothing/accessory/attached_accessories = list() - var/list/mutable_appearance/accessory_overlays = list() + var/list/obj/item/clothing/accessory/attached_accessories //SANDSTORM EDIT END /obj/item/clothing/under/worn_overlays(isinhands = FALSE, icon_file, used_state, style_flags = NONE) @@ -36,8 +35,12 @@ . += mutable_appearance('icons/effects/item_damage.dmi', "damageduniform") if(blood_DNA) . += mutable_appearance('icons/effects/blood.dmi', "uniformblood", color = blood_DNA_to_color(), blend_mode = blood_DNA_to_blend()) - if(length(accessory_overlays)) - . += accessory_overlays + if(CHECK_BITFIELD(flags_inv, HIDEACCESSORY)) + return + for(var/obj/item/clothing/accessory/attached_accessory as anything in attached_accessories) + if(CHECK_BITFIELD(attached_accessory.flags_inv, HIDEACCESSORY)) + continue + . += attached_accessory.build_worn_icon() /obj/item/clothing/under/attackby(obj/item/I, mob/user, params) if((sensordamage || (has_sensor < HAS_SENSORS && has_sensor != NO_SENSORS)) && istype(I, /obj/item/stack/cable_coil)) @@ -125,68 +128,60 @@ body_parts_covered |= CHEST // Sandstorm edit - for(var/obj/item/clothing/accessory/attached_accessory in attached_accessories) - if(attached_accessory && slot != ITEM_SLOT_HANDS && ishuman(user)) - var/mob/living/carbon/human/H = user + var/must_update = FALSE + for(var/obj/item/clothing/accessory/attached_accessory as anything in attached_accessories) + if(attached_accessory && slot == ITEM_SLOT_ICLOTHING && ishuman(user)) attached_accessory.on_uniform_equip(src, user) - if(attached_accessory.above_suit) - H.update_inv_wear_suit() + if(attached_accessory.above_suit) + must_update = TRUE + if(must_update) + user.update_inv_wear_suit() // /obj/item/clothing/under/dropped(mob/user) // Sandstorm edit - for(var/obj/item/clothing/accessory/attached_accessory in attached_accessories) + var/must_update = FALSE + for(var/obj/item/clothing/accessory/attached_accessory as anything in attached_accessories) attached_accessory.on_uniform_dropped(src, user) - if(ishuman(user)) - var/mob/living/carbon/human/H = user - if(attached_accessory.above_suit) - H.update_inv_wear_suit() + if(attached_accessory.above_suit) + must_update = TRUE + if(must_update) + user.update_inv_wear_suit() // ..() -/obj/item/clothing/under/proc/attach_accessory(obj/item/I, mob/user, notifyAttach = 1) +/obj/item/clothing/under/proc/attach_accessory(obj/item/clothing/accessory/accessory, mob/user, notifyAttach = 1) . = FALSE - if(istype(I, /obj/item/clothing/accessory) && !istype(I, /obj/item/clothing/accessory/ring)) - var/obj/item/clothing/accessory/A = I - if(length(attached_accessories) >= max_accessories) - if(user) - to_chat(user, "[src] already has [length(attached_accessories)] accessories.") - return - if(dummy_thick) - if(user) - to_chat(user, "[src] is too bulky and cannot have accessories attached to it!") - return - else - if(user && !user.temporarilyRemoveItemFromInventory(I)) - return - if(!A.attach(src, user)) - return + if(!istype(accessory)) + return + if(istype(accessory, /obj/item/clothing/accessory/ring)) + return + if(length(attached_accessories) >= max_accessories) + if(user) + to_chat(user, span_warning("[src] already has [length(attached_accessories)] accessories.")) + return + if(dummy_thick) + if(user) + to_chat(user, span_warning("[src] is too bulky and cannot have accessories attached to it!")) + return + if(user && !user.temporarilyRemoveItemFromInventory(accessory)) + return + if(!accessory.attach(src, user)) + return - if(user && notifyAttach) - to_chat(user, "You attach [I] to [src].") + if(user && notifyAttach) + to_chat(user, span_notice("You attach [accessory] to [src].")) - if((flags_inv & HIDEACCESSORY) || (A.flags_inv & HIDEACCESSORY)) - return TRUE + if((flags_inv & HIDEACCESSORY) || (accessory.flags_inv & HIDEACCESSORY)) + return TRUE - //SANDSTORM EDIT - accessory_overlays = list(mutable_appearance('icons/mob/clothing/accessories.dmi', "blank")) - for(var/obj/item/clothing/accessory/attached_accessory in attached_accessories) - var/datum/element/polychromic/polychromic = LAZYACCESS(attached_accessory.comp_lookup, "item_worn_overlays") - if(!polychromic) - var/mutable_appearance/accessory_overlay = mutable_appearance(attached_accessory.mob_overlay_icon, attached_accessory.item_state || attached_accessory.icon_state, ABOVE_HUD_LAYER) - accessory_overlay.alpha = attached_accessory.alpha - accessory_overlay.color = attached_accessory.color - accessory_overlays += accessory_overlay - else - polychromic.apply_worn_overlays(attached_accessory, FALSE, attached_accessory.mob_overlay_icon, attached_accessory.item_state || attached_accessory.icon_state, NONE, accessory_overlays) - //SANDSTORM EDIT END + if(ishuman(loc)) + var/mob/living/carbon/human/H = loc + H.update_inv_w_uniform() + if(accessory.above_suit) + H.update_inv_wear_suit() - if(ishuman(loc)) - var/mob/living/carbon/human/H = loc - H.update_inv_w_uniform() - H.update_inv_wear_suit() - - return TRUE + return TRUE /obj/item/clothing/under/proc/remove_accessory(mob/user) if(!isliving(user)) @@ -194,22 +189,21 @@ if(!can_use(user)) return - //SKYRAT EDIT - if(length(attached_accessories)) - var/obj/item/clothing/accessory/A = attached_accessories[length(attached_accessories)] - //SKYRAT EDIT END - A.detach(src, user) - if(user.put_in_hands(A)) - to_chat(user, "You detach [A] from [src].") - else - to_chat(user, "You detach [A] from [src] and it falls on the floor.") + if(!LAZYLEN(attached_accessories)) + return + var/obj/item/clothing/accessory/accessory = attached_accessories[length(attached_accessories)] + accessory.detach(src, user) + if(user.put_in_hands(accessory)) + to_chat(user, span_notice("You detach [accessory] from [src].")) + else + to_chat(user, span_notice("You detach [accessory] from [src] and it falls on the floor.")) - if(ishuman(loc)) - var/mob/living/carbon/human/H = loc - H.update_inv_w_uniform() + if(ishuman(loc)) + var/mob/living/carbon/human/H = loc + H.update_inv_w_uniform() + if(accessory.above_suit) H.update_inv_wear_suit() - /obj/item/clothing/under/examine(mob/user) . = ..() if(can_adjust) @@ -234,10 +228,9 @@ . += "Its vital tracker appears to be enabled." if(SENSOR_COORDS) . += "Its vital tracker and tracking beacon appear to be enabled." - if(length(attached_accessories)) - for(var/obj/item/clothing/accessory/attached_accessory in attached_accessories) - . += "\A [attached_accessory] is attached to it." - //SKYRAT EDIT END + for(var/obj/item/clothing/accessory/attached_accessory as anything in attached_accessories) + . += "\A [attached_accessory] is attached to it." + //SANDSTORM EDIT END /obj/item/clothing/under/verb/toggle() set name = "Adjust Suit Sensors" diff --git a/code/modules/clothing/under/accessories.dm b/code/modules/clothing/under/accessories.dm index 011f64d3ec..cbfb9baf90 100644 --- a/code/modules/clothing/under/accessories.dm +++ b/code/modules/clothing/under/accessories.dm @@ -2,7 +2,7 @@ name = "Accessory" desc = "Something has gone wrong!" icon = 'icons/obj/clothing/accessories.dmi' - //skyrat edit + //sandstorm edit mob_overlay_icon = 'icons/mob/clothing/accessories.dmi' // icon_state = "plasma" @@ -13,48 +13,41 @@ var/above_suit = FALSE var/minimize_when_attached = TRUE // TRUE if shown as a small icon in corner, FALSE if overlayed var/datum/component/storage/detached_pockets - //skyrat edit - var/current_uniform = null - // -/obj/item/clothing/accessory/proc/attach(obj/item/clothing/under/U, user) +/obj/item/clothing/accessory/proc/attach(obj/item/clothing/under/uniform, user) var/datum/component/storage/storage = GetComponent(/datum/component/storage) if(storage) - if(SEND_SIGNAL(U, COMSIG_CONTAINS_STORAGE)) + if(SEND_SIGNAL(uniform, COMSIG_CONTAINS_STORAGE)) return FALSE - U.TakeComponent(storage) + uniform.TakeComponent(storage) detached_pockets = storage - //SKYRAT EDIT - U.attached_accessories |= src - force_unto(U) - current_uniform = U - //SKYRAT EDIT END - forceMove(U) + //SANDSTORM EDIT + LAZYADD(uniform.attached_accessories, src) + force_unto(uniform) + //SANDSTORM EDIT END + forceMove(uniform) - if (islist(U.armor) || isnull(U.armor)) // This proc can run before /obj/Initialize has run for U and src, - U.armor = getArmor(arglist(U.armor)) // we have to check that the armor list has been transformed into a datum before we try to call a proc on it + if (islist(uniform.armor) || isnull(uniform.armor)) // This proc can run before /obj/Initialize has run for uniform and src, + uniform.armor = getArmor(arglist(uniform.armor)) // we have to check that the armor list has been transformed into a datum before we try to call a proc on it // This is safe to do as /obj/Initialize only handles setting up the datum if actually needed. if (islist(armor) || isnull(armor)) armor = getArmor(arglist(armor)) - U.armor = U.armor.attachArmor(armor) + uniform.armor = uniform.armor.attachArmor(armor) if(isliving(user)) - on_uniform_equip(U, user) + on_uniform_equip(uniform, user) return TRUE -/obj/item/clothing/accessory/proc/detach(obj/item/clothing/under/U, user) - if(detached_pockets && detached_pockets.parent == U) +/obj/item/clothing/accessory/proc/detach(obj/item/clothing/under/uniform, user) + if(detached_pockets && detached_pockets.parent == uniform) TakeComponent(detached_pockets) - U.armor = U.armor.detachArmor(armor) - //SANDSTORM EDIT - current_uniform = null - //SANDSTORM EDIT END + uniform.armor = uniform.armor.detachArmor(armor) if(isliving(user)) - on_uniform_dropped(U, user) + on_uniform_dropped(uniform, user) if(minimize_when_attached) transform *= 2 @@ -62,48 +55,36 @@ pixel_y = 0 layer = initial(layer) plane = initial(plane) - U.cut_overlays() - U.attached_accessories -= src - U.accessory_overlays = list() - if(length(U.attached_accessories)) - U.accessory_overlays = list(mutable_appearance('icons/mob/clothing/accessories.dmi', "blank")) - for(var/obj/item/clothing/accessory/attached_accessory in U.attached_accessories) - attached_accessory.force_unto(U) - var/datum/element/polychromic/polychromic = LAZYACCESS(attached_accessory.comp_lookup, "item_worn_overlays") - if(!polychromic) - var/mutable_appearance/accessory_overlay = mutable_appearance(attached_accessory.mob_overlay_icon, attached_accessory.item_state || attached_accessory.icon_state, ABOVE_HUD_LAYER) - accessory_overlay.alpha = attached_accessory.alpha - accessory_overlay.color = attached_accessory.color - U.accessory_overlays += accessory_overlay - else - polychromic.apply_worn_overlays(attached_accessory, FALSE, attached_accessory.mob_overlay_icon, attached_accessory.item_state || attached_accessory.icon_state, NONE, U.accessory_overlays) + uniform.cut_overlays() + LAZYREMOVE(uniform.attached_accessories, src) + for(var/obj/item/clothing/accessory/attached_accessory as anything in uniform.attached_accessories) + uniform.add_overlay(attached_accessory) //SANDSTORM EDIT -/obj/item/clothing/accessory/proc/force_unto(obj/item/clothing/under/U) +/obj/item/clothing/accessory/proc/force_unto(obj/item/clothing/under/uniform) layer = FLOAT_LAYER plane = FLOAT_PLANE if(minimize_when_attached) - if(current_uniform != U) - transform *= 0.5 //halve the size so it doesn't overpower the under - pixel_x += 8 - pixel_y -= 8 - if(length(U.attached_accessories) > 1) - if(length(U.attached_accessories) <= 3 && !current_uniform) - pixel_y += 8 * (length(U.attached_accessories) - 1) - else if((length(U.attached_accessories) > 3) && (length(U.attached_accessories) <= 6) && !current_uniform) - pixel_x -= 8 - pixel_y += 8 * (length(U.attached_accessories) - 4) - else if((length(U.attached_accessories) > 6) && (length(U.attached_accessories) <= 9) && !current_uniform) - pixel_x -= 16 - pixel_y += 8 * (length(U.attached_accessories) - 7) - else - if(current_uniform != U) + transform *= 0.5 //halve the size so it doesn't overpower the under + pixel_x += 8 + pixel_y -= 8 + if(length(uniform.attached_accessories) > 1) + switch(LAZYLEN(uniform.attached_accessories)) + if(2 to 3) + pixel_y += 8 * (length(uniform.attached_accessories) - 1) + if(4 to 6) + pixel_x -= 8 + pixel_y += 8 * (length(uniform.attached_accessories) - 4) + if(7 to 9) + pixel_x -= 16 + pixel_y += 8 * (length(uniform.attached_accessories) - 7) + else //we ran out of space for accessories, so we just throw shit at the wall pixel_x = 0 pixel_y = 0 pixel_x += rand(-16, 16) pixel_y += rand(-16, 16) - U.add_overlay(src) + uniform.add_overlay(src) //SANDSTORM EDIT END /obj/item/clothing/accessory/proc/on_uniform_equip(obj/item/clothing/under/U, user) @@ -122,9 +103,9 @@ /obj/item/clothing/accessory/examine(mob/user) . = ..() - . += "\The [src] can be attached to [istype(src, /obj/item/clothing/accessory/ring) ? "gloves" : "a uniform"]. Alt-click to remove it once attached." + . += span_notice("\The [src] can be attached to [istype(src, /obj/item/clothing/accessory/ring) ? "gloves" : "a uniform"]. Alt-click to remove it once attached.") if(initial(above_suit)) - . += "\The [src] can be worn above or below your suit. Ctrl-click to toggle." + . += span_notice("\The [src] can be worn above or below your suit. Ctrl-click to toggle.") ////////////// //Waistcoats// diff --git a/code/modules/mob/living/carbon/human/examine.dm b/code/modules/mob/living/carbon/human/examine.dm index 6e4375f29d..21919ddeff 100644 --- a/code/modules/mob/living/carbon/human/examine.dm +++ b/code/modules/mob/living/carbon/human/examine.dm @@ -50,22 +50,15 @@ //accessory var/accessory_msg if(istype(w_uniform, /obj/item/clothing/under)) - var/obj/item/clothing/under/U = w_uniform - if(length(U.attached_accessories) && !(U.flags_inv & HIDEACCESSORY)) - var/list/weehoo = list() - var/dumb_icons = "" - for(var/obj/item/clothing/accessory/attached_accessory in U.attached_accessories) - if(!(attached_accessory.flags_inv & HIDEACCESSORY)) - weehoo += "\a [attached_accessory]" - dumb_icons = "[dumb_icons][icon2html(attached_accessory, user)]" - if(length(weehoo)) - accessory_msg += " with [dumb_icons]" - if(length(U.attached_accessories) >= 2) - accessory_msg += jointext(weehoo, ", ", 1, length(weehoo) - 1) - accessory_msg += " and [weehoo[length(weehoo)]]" - else - accessory_msg += weehoo[1] - + var/obj/item/clothing/under/worn_thing = w_uniform + if(!CHECK_BITFIELD(worn_thing.flags_inv, HIDEACCESSORY)) + var/list/accessory_preparation + for(var/obj/item/clothing/accessory/attached_accessory as anything in worn_thing.attached_accessories) + if(CHECK_BITFIELD(attached_accessory.flags_inv, HIDEACCESSORY)) + continue + LAZYADD(accessory_preparation, "[icon2html(attached_accessory, user)] [attached_accessory]") + if(length(accessory_preparation)) + accessory_msg = " with [english_list(accessory_preparation)]" . += "[t_He] [t_is] wearing [w_uniform.get_examine_string(user)][accessory_msg]." //head @@ -88,7 +81,20 @@ //gloves if(gloves && !(ITEM_SLOT_GLOVES in obscured)) - . += "[t_He] [t_has] [gloves.get_examine_string(user)] on [t_his] hands." + //accessory + var/accessory_msg + if(istype(gloves, /obj/item/clothing/gloves)) + var/obj/item/clothing/gloves/worn_thing = gloves + if(!CHECK_BITFIELD(worn_thing.flags_inv, HIDEACCESSORY)) + var/list/accessory_preparation + for(var/obj/item/clothing/accessory/ring/attached_accessory as anything in worn_thing.attached_accessories) + if(CHECK_BITFIELD(attached_accessory.flags_inv, HIDEACCESSORY)) + continue + LAZYADD(accessory_preparation, "[icon2html(attached_accessory, user)] [attached_accessory]") + if(length(accessory_preparation)) + accessory_msg = " with [english_list(accessory_preparation)] on [t_his] fingers" + + . += "[t_He] [t_has] [gloves.get_examine_string(user)] on [t_his] hands[accessory_msg]." else if(length(blood_DNA)) var/hand_number = get_num_arms(FALSE) if(hand_number) diff --git a/modular_sand/code/modules/clothing/gloves/_gloves.dm b/modular_sand/code/modules/clothing/gloves/_gloves.dm index 7b21d86c73..e18ccaeff8 100644 --- a/modular_sand/code/modules/clothing/gloves/_gloves.dm +++ b/modular_sand/code/modules/clothing/gloves/_gloves.dm @@ -1,8 +1,7 @@ /obj/item/clothing/gloves var/dummy_thick = FALSE // is able to hold accessories on its item var/max_accessories = 1 - var/list/obj/item/clothing/accessory/ring/attached_accessories = list() - var/list/mutable_appearance/accessory_overlays = list() + var/list/obj/item/clothing/accessory/ring/attached_accessories /obj/item/clothing/gloves/Destroy() QDEL_LIST(attached_accessories) @@ -10,9 +9,12 @@ /obj/item/clothing/gloves/worn_overlays(isinhands = FALSE, icon_file, used_state, style_flags = NONE) . = ..() - if(!isinhands) - if(length(accessory_overlays)) - . += accessory_overlays + if(CHECK_BITFIELD(flags_inv, HIDEACCESSORY)) + return + for(var/obj/item/clothing/accessory/ring/attached_accessory as anything in attached_accessories) + if(CHECK_BITFIELD(attached_accessory.flags_inv, HIDEACCESSORY)) + continue + . += attached_accessory.build_worn_icon() /obj/item/clothing/gloves/attackby(obj/item/I, mob/user, params) if(!attach_accessory(I, user)) @@ -28,66 +30,43 @@ /obj/item/clothing/gloves/equipped(mob/user, slot) ..() - // Sandstorm edit - for(var/obj/item/clothing/accessory/ring/attached_accessory in attached_accessories) - if(attached_accessory && slot != ITEM_SLOT_HANDS && ishuman(user)) - var/mob/living/carbon/human/H = user + for(var/obj/item/clothing/accessory/ring/attached_accessory as anything in attached_accessories) + if(attached_accessory && slot == ITEM_SLOT_HANDS && ishuman(user)) attached_accessory.on_uniform_equip(src, user) - if(attached_accessory.above_suit) - H.update_inv_wear_suit() - // Sandstorm edit END /obj/item/clothing/gloves/dropped(mob/user) - // Sandstorm edit - for(var/obj/item/clothing/accessory/ring/attached_accessory in attached_accessories) + for(var/obj/item/clothing/accessory/ring/attached_accessory as anything in attached_accessories) attached_accessory.on_uniform_dropped(src, user) - if(ishuman(user)) - var/mob/living/carbon/human/H = user - if(attached_accessory.above_suit) - H.update_inv_wear_suit() - // Sandstorm edit END ..() -/obj/item/clothing/gloves/proc/attach_accessory(obj/item/I, mob/user, notifyAttach = 1) +/obj/item/clothing/gloves/proc/attach_accessory(obj/item/clothing/accessory/ring/accessory, mob/user, notifyAttach = 1) . = FALSE - if(istype(I, /obj/item/clothing/accessory/ring)) - var/obj/item/clothing/accessory/ring/A = I - if(length(attached_accessories) >= max_accessories) - if(user) - to_chat(user, span_warning("[src] already has [length(attached_accessories)] accessories.")) - return - if(dummy_thick) - if(user) - to_chat(user, span_warning("[src] is too bulky and cannot have accessories attached to it!")) - return - else - if(user && !user.temporarilyRemoveItemFromInventory(I)) - return - if(!A.attach(src, user)) - return + if(!istype(accessory)) + return + if(length(attached_accessories) >= max_accessories) + if(user) + to_chat(user, "[src] already has [length(attached_accessories)] accessories.") + return + if(dummy_thick) + if(user) + to_chat(user, "[src] is too bulky and cannot have accessories attached to it!") + return + if(user && !user.temporarilyRemoveItemFromInventory(accessory)) + return + if(!accessory.attach(src, user)) + return - if(user && notifyAttach) - to_chat(user, span_notice("You attach [I] to [src].")) + if(user && notifyAttach) + to_chat(user, "You attach [accessory] to [src].") - if((flags_inv & HIDEACCESSORY) || (A.flags_inv & HIDEACCESSORY)) - return TRUE + if((flags_inv & HIDEACCESSORY) || (accessory.flags_inv & HIDEACCESSORY)) + return TRUE - accessory_overlays = list(mutable_appearance('icons/mob/clothing/accessories.dmi', "blank")) - for(var/obj/item/clothing/accessory/attached_accessory in attached_accessories) - var/datum/element/polychromic/polychromic = LAZYACCESS(attached_accessory.comp_lookup, "item_worn_overlays") - if(!polychromic) - var/mutable_appearance/accessory_overlay = mutable_appearance(attached_accessory.mob_overlay_icon, attached_accessory.item_state || attached_accessory.icon_state, ABOVE_HUD_LAYER) - accessory_overlay.alpha = attached_accessory.alpha - accessory_overlay.color = attached_accessory.color - accessory_overlays += accessory_overlay - else - polychromic.apply_worn_overlays(attached_accessory, FALSE, attached_accessory.mob_overlay_icon, attached_accessory.item_state || attached_accessory.icon_state, NONE, accessory_overlays) + if(ishuman(loc)) + var/mob/living/carbon/human/H = loc + H.update_inv_gloves() - if(ishuman(loc)) - var/mob/living/carbon/human/H = loc - H.update_inv_gloves() - - return TRUE + return TRUE /obj/item/clothing/gloves/proc/remove_accessory(mob/user) if(!isliving(user)) @@ -95,20 +74,20 @@ if(!can_use(user)) return - if(length(attached_accessories)) - var/obj/item/clothing/accessory/ring/A = attached_accessories[length(attached_accessories)] - A.detach(src, user) - if(user.put_in_hands(A)) - to_chat(user, span_notice("You detach [A] from [src].")) - else - to_chat(user, span_notice("You detach [A] from [src] and it falls on the floor.")) + if(!LAZYLEN(attached_accessories)) + return + var/obj/item/clothing/accessory/ring/accessory = attached_accessories[length(attached_accessories)] + accessory.detach(src, user) + if(user.put_in_hands(accessory)) + to_chat(user, span_notice("You detach [accessory] from [src].")) + else + to_chat(user, span_notice("You detach [accessory] from [src] and it falls on the floor.")) - if(ishuman(loc)) - var/mob/living/carbon/human/H = loc - H.update_inv_gloves() + if(ishuman(loc)) + var/mob/living/carbon/human/H = loc + H.update_inv_gloves() /obj/item/clothing/gloves/examine(mob/user) . = ..() - if(length(attached_accessories)) - for(var/obj/item/clothing/accessory/ring/attached_accessory in attached_accessories) - . += "\A [attached_accessory] is attached to one of it's fingers." + for(var/obj/item/clothing/accessory/ring/attached_accessory as anything in attached_accessories) + . += "\A [attached_accessory] is attached to one of its fingers." diff --git a/modular_sand/code/modules/clothing/gloves/accessories.dm b/modular_sand/code/modules/clothing/gloves/accessories.dm index e2afe193ff..c6bf70c536 100644 --- a/modular_sand/code/modules/clothing/gloves/accessories.dm +++ b/modular_sand/code/modules/clothing/gloves/accessories.dm @@ -10,6 +10,8 @@ icon_state = "ringgold" item_state = "gring" strip_delay = 40 + /// Here as a reminder, do not add this, unsupported. + above_suit = FALSE var/transfer_prints = FALSE var/transfer_blood = 0 var/strip_mod = 1