From fcda4c0fbb15d908b481ebdc155ba89d90e0d5b2 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Thu, 25 Apr 2019 20:40:48 -0400 Subject: [PATCH 1/4] Update _neck.dm --- code/modules/clothing/neck/_neck.dm | 44 +++++++++++++++++++++++++++-- 1 file changed, 42 insertions(+), 2 deletions(-) diff --git a/code/modules/clothing/neck/_neck.dm b/code/modules/clothing/neck/_neck.dm index 8245148096..d4cfbd1a84 100644 --- a/code/modules/clothing/neck/_neck.dm +++ b/code/modules/clothing/neck/_neck.dm @@ -171,17 +171,57 @@ icon_state = "stripedbluescarf" item_color = "stripedbluescarf" -/obj/item/clothing/neck/petcollar //don't really wear this though please c'mon seriously guys +/////////// +//COLLARS// +/////////// + +/obj/item/clothing/neck/petcollar name = "pet collar" desc = "It's for pets. Though you probably could wear it yourself, you'd doubtless be the subject of ridicule." icon_state = "petcollar" item_color = "petcollar" + pocket_storage_component_path = /datum/component/storage/concrete/pockets/small/collar var/tagname = null /obj/item/clothing/neck/petcollar/attack_self(mob/user) tagname = copytext(sanitize(input(user, "Would you like to change the name on the tag?", "Name your new pet", "Spot") as null|text),1,MAX_NAME_LEN) name = "[initial(name)] - [tagname]" +/obj/item/clothing/neck/petcollar/locked + name = "locked collar" + desc = "A collar that has a small lock on it to keep it from being removed." + pocket_storage_component_path = /datum/component/storage/concrete/pockets/small/collar/locked + var/lock = FALSE + +/obj/item/clothing/neck/petcollar/locked/attackby(obj/item/key/collar, mob/user, params) + if(lock != FALSE) + to_chat(user, "With a click the collar unlocks!") + lock = FALSE + item_flags = NONE + else + to_chat(user, "With a click the collar locks!") + lock = TRUE + item_flags = NODROP + return + +/obj/item/clothing/neck/petcollar/locked/attack_hand(mob/user) + if(loc == user && user.get_item_by_slot(SLOT_NECK) && lock != FALSE) + to_chat(user, "The collar is locked! You'll need unlock the collar before you can take it off!") + return + ..() + +/obj/item/key/collar + name = "Collar Key" + desc = "A key for a tiny lock on a collar or bag." + +/obj/item/clothing/neck/petcollar/Initialize() + . = ..() + new /obj/item/reagent_containers/food/snacks/cookie(src) + +/obj/item/clothing/neck/petcollar/locked/Initialize() + . = ..() + new /obj/item/key/collar(src) + ////////////// //DOPE BLING// ////////////// @@ -191,4 +231,4 @@ desc = "Damn, it feels good to be a gangster." icon = 'icons/obj/clothing/neck.dmi' icon_state = "bling" - item_color = "bling" \ No newline at end of file + item_color = "bling" From a69b845509b8f0fc8ab294823f4d7ce1c1e23d6b Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Thu, 25 Apr 2019 20:41:34 -0400 Subject: [PATCH 2/4] Update pockets.dm --- .../components/storage/concrete/pockets.dm | 117 +++++++----------- 1 file changed, 48 insertions(+), 69 deletions(-) diff --git a/code/datums/components/storage/concrete/pockets.dm b/code/datums/components/storage/concrete/pockets.dm index 3d03c2adbd..f049a12ffb 100644 --- a/code/datums/components/storage/concrete/pockets.dm +++ b/code/datums/components/storage/concrete/pockets.dm @@ -1,73 +1,52 @@ -/datum/component/storage/concrete/pockets - max_items = 2 - max_w_class = WEIGHT_CLASS_SMALL - max_combined_w_class = 50 - rustle_sound = FALSE -/datum/component/storage/concrete/pockets/handle_item_insertion(obj/item/I, prevent_warning, mob/user) +/////////// +//COLLARS// +/////////// + +/obj/item/clothing/neck/petcollar + name = "pet collar" + desc = "It's for pets. Though you probably could wear it yourself, you'd doubtless be the subject of ridicule." + icon_state = "petcollar" + item_color = "petcollar" + pocket_storage_component_path = /datum/component/storage/concrete/pockets/small/collar + var/tagname = null + +/obj/item/clothing/neck/petcollar/attack_self(mob/user) + tagname = copytext(sanitize(input(user, "Would you like to change the name on the tag?", "Name your new pet", "Spot") as null|text),1,MAX_NAME_LEN) + name = "[initial(name)] - [tagname]" + + +/obj/item/clothing/neck/petcollar/locked + name = "locked collar" + desc = "A collar that has a small lock on it to keep it from being removed." + pocket_storage_component_path = /datum/component/storage/concrete/pockets/small/collar/locked + var/lock = FALSE + +/obj/item/clothing/neck/petcollar/locked/attackby(obj/item/key/collar, mob/user, params) + if(lock != FALSE) + to_chat(user, "With a click the collar unlocks!") + lock = FALSE + item_flags = NONE + else + to_chat(user, "With a click the collar locks!") + lock = TRUE + item_flags = NODROP + return + +/obj/item/clothing/neck/petcollar/locked/attack_hand(mob/user) + if(loc == user && user.get_item_by_slot(SLOT_NECK) && lock != FALSE) + to_chat(user, "The collar is locked! You'll need unlock the collar before you can take it off!") + return + ..() + +/obj/item/key/collar + name = "Collar Key" + desc = "A key for a tiny lock on a collar or bag." + +/obj/item/clothing/neck/petcollar/Initialize() . = ..() - if(. && silent && !prevent_warning) - if(quickdraw) - to_chat(user, "You discreetly slip [I] into [parent]. Alt-click [parent] to remove it.") - else - to_chat(user, "You discreetly slip [I] into [parent].") + new /obj/item/reagent_containers/food/snacks/cookie(src) -/datum/component/storage/concrete/pockets - max_w_class = WEIGHT_CLASS_NORMAL - -/datum/component/storage/concrete/pockets/small - max_items = 1 - attack_hand_interact = FALSE - -/datum/component/storage/concrete/pockets/tiny - max_items = 1 - max_w_class = WEIGHT_CLASS_TINY - attack_hand_interact = FALSE - -/datum/component/storage/concrete/pockets/small/detective - attack_hand_interact = TRUE // so the detectives would discover pockets in their hats - -/datum/component/storage/concrete/pockets/shoes - attack_hand_interact = FALSE - quickdraw = TRUE - silent = TRUE - -/datum/component/storage/concrete/pockets/shoes/Initialize() +/obj/item/clothing/neck/petcollar/locked/Initialize() . = ..() - cant_hold = typecacheof(list(/obj/item/screwdriver/power)) - can_hold = typecacheof(list( - /obj/item/kitchen/knife, /obj/item/switchblade, /obj/item/pen, - /obj/item/scalpel, /obj/item/reagent_containers/syringe, /obj/item/dnainjector, - /obj/item/reagent_containers/hypospray/medipen, /obj/item/reagent_containers/dropper, - /obj/item/implanter, /obj/item/screwdriver, /obj/item/weldingtool/mini, - /obj/item/firing_pin - )) - -/datum/component/storage/concrete/pockets/shoes/clown/Initialize() - . = ..() - cant_hold = typecacheof(list(/obj/item/screwdriver/power)) - can_hold = typecacheof(list( - /obj/item/kitchen/knife, /obj/item/switchblade, /obj/item/pen, - /obj/item/scalpel, /obj/item/reagent_containers/syringe, /obj/item/dnainjector, - /obj/item/reagent_containers/hypospray/medipen, /obj/item/reagent_containers/dropper, - /obj/item/implanter, /obj/item/screwdriver, /obj/item/weldingtool/mini, - /obj/item/firing_pin, /obj/item/bikehorn)) - -/datum/component/storage/concrete/pockets/pocketprotector - max_items = 3 - max_w_class = WEIGHT_CLASS_TINY - var/atom/original_parent - -/datum/component/storage/concrete/pockets/pocketprotector/Initialize() - original_parent = parent - . = ..() - can_hold = typecacheof(list( //Same items as a PDA - /obj/item/pen, - /obj/item/toy/crayon, - /obj/item/lipstick, - /obj/item/flashlight/pen, - /obj/item/clothing/mask/cigarette)) - -/datum/component/storage/concrete/pockets/pocketprotector/real_location() - // if the component is reparented to a jumpsuit, the items still go in the protector - return original_parent + new /obj/item/key/collar(src) From 59cc2b5a9c7f26eabd40d08653b597e7c422f4d8 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Thu, 25 Apr 2019 20:42:38 -0400 Subject: [PATCH 3/4] Update vending.dm --- modular_citadel/code/game/machinery/vending.dm | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/modular_citadel/code/game/machinery/vending.dm b/modular_citadel/code/game/machinery/vending.dm index 213dd8a17a..bdca91b0e6 100755 --- a/modular_citadel/code/game/machinery/vending.dm +++ b/modular_citadel/code/game/machinery/vending.dm @@ -54,8 +54,11 @@ /obj/item/clothing/neck/petcollar = 5, /obj/item/clothing/under/mankini = 1, /obj/item/dildo/flared/huge = 1 - ) - premium = list(/obj/item/electropack/shockcollar = 3) + ) + premium = list( + /obj/item/electropack/shockcollar = 3, + /obj/item/clothing/neck/petcollar/locked = 1 + ) refill_canister = /obj/item/vending_refill/kink /* /obj/machinery/vending/nazivend From 33e3df815717df367edde60f6cce230f4dc5c464 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Thu, 25 Apr 2019 20:46:39 -0400 Subject: [PATCH 4/4] What in the hell? --- .../components/storage/concrete/pockets.dm | 133 +++++++++++------- 1 file changed, 85 insertions(+), 48 deletions(-) diff --git a/code/datums/components/storage/concrete/pockets.dm b/code/datums/components/storage/concrete/pockets.dm index f049a12ffb..e0a23b0209 100644 --- a/code/datums/components/storage/concrete/pockets.dm +++ b/code/datums/components/storage/concrete/pockets.dm @@ -1,52 +1,89 @@ +/datum/component/storage/concrete/pockets + max_items = 2 + max_w_class = WEIGHT_CLASS_SMALL + max_combined_w_class = 50 + rustle_sound = FALSE -/////////// -//COLLARS// -/////////// - -/obj/item/clothing/neck/petcollar - name = "pet collar" - desc = "It's for pets. Though you probably could wear it yourself, you'd doubtless be the subject of ridicule." - icon_state = "petcollar" - item_color = "petcollar" - pocket_storage_component_path = /datum/component/storage/concrete/pockets/small/collar - var/tagname = null - -/obj/item/clothing/neck/petcollar/attack_self(mob/user) - tagname = copytext(sanitize(input(user, "Would you like to change the name on the tag?", "Name your new pet", "Spot") as null|text),1,MAX_NAME_LEN) - name = "[initial(name)] - [tagname]" - - -/obj/item/clothing/neck/petcollar/locked - name = "locked collar" - desc = "A collar that has a small lock on it to keep it from being removed." - pocket_storage_component_path = /datum/component/storage/concrete/pockets/small/collar/locked - var/lock = FALSE - -/obj/item/clothing/neck/petcollar/locked/attackby(obj/item/key/collar, mob/user, params) - if(lock != FALSE) - to_chat(user, "With a click the collar unlocks!") - lock = FALSE - item_flags = NONE - else - to_chat(user, "With a click the collar locks!") - lock = TRUE - item_flags = NODROP - return - -/obj/item/clothing/neck/petcollar/locked/attack_hand(mob/user) - if(loc == user && user.get_item_by_slot(SLOT_NECK) && lock != FALSE) - to_chat(user, "The collar is locked! You'll need unlock the collar before you can take it off!") - return - ..() - -/obj/item/key/collar - name = "Collar Key" - desc = "A key for a tiny lock on a collar or bag." - -/obj/item/clothing/neck/petcollar/Initialize() +/datum/component/storage/concrete/pockets/handle_item_insertion(obj/item/I, prevent_warning, mob/user) . = ..() - new /obj/item/reagent_containers/food/snacks/cookie(src) + if(. && silent && !prevent_warning) + if(quickdraw) + to_chat(user, "You discreetly slip [I] into [parent]. Alt-click [parent] to remove it.") + else + to_chat(user, "You discreetly slip [I] into [parent].") -/obj/item/clothing/neck/petcollar/locked/Initialize() +/datum/component/storage/concrete/pockets + max_w_class = WEIGHT_CLASS_NORMAL + +/datum/component/storage/concrete/pockets/small + max_items = 1 + attack_hand_interact = FALSE + +/datum/component/storage/concrete/pockets/small/collar + max_items = 1 + +/datum/component/storage/concrete/pockets/small/collar/Initialize() . = ..() - new /obj/item/key/collar(src) + can_hold = typecacheof(list( + /obj/item/reagent_containers/food/snacks/cookie, + /obj/item/reagent_containers/food/snacks/sugarcookie)) + +/datum/component/storage/concrete/pockets/small/collar/locked/Initialize() + . = ..() + can_hold = typecacheof(list( + /obj/item/reagent_containers/food/snacks/cookie, + /obj/item/reagent_containers/food/snacks/sugarcookie, + /obj/item/key/collar)) + +/datum/component/storage/concrete/pockets/tiny + max_items = 1 + max_w_class = WEIGHT_CLASS_TINY + attack_hand_interact = FALSE + +/datum/component/storage/concrete/pockets/small/detective + attack_hand_interact = TRUE // so the detectives would discover pockets in their hats + +/datum/component/storage/concrete/pockets/shoes + attack_hand_interact = FALSE + quickdraw = TRUE + silent = TRUE + +/datum/component/storage/concrete/pockets/shoes/Initialize() + . = ..() + cant_hold = typecacheof(list(/obj/item/screwdriver/power)) + can_hold = typecacheof(list( + /obj/item/kitchen/knife, /obj/item/switchblade, /obj/item/pen, + /obj/item/scalpel, /obj/item/reagent_containers/syringe, /obj/item/dnainjector, + /obj/item/reagent_containers/hypospray/medipen, /obj/item/reagent_containers/dropper, + /obj/item/implanter, /obj/item/screwdriver, /obj/item/weldingtool/mini, + /obj/item/firing_pin + )) + +/datum/component/storage/concrete/pockets/shoes/clown/Initialize() + . = ..() + cant_hold = typecacheof(list(/obj/item/screwdriver/power)) + can_hold = typecacheof(list( + /obj/item/kitchen/knife, /obj/item/switchblade, /obj/item/pen, + /obj/item/scalpel, /obj/item/reagent_containers/syringe, /obj/item/dnainjector, + /obj/item/reagent_containers/hypospray/medipen, /obj/item/reagent_containers/dropper, + /obj/item/implanter, /obj/item/screwdriver, /obj/item/weldingtool/mini, + /obj/item/firing_pin, /obj/item/bikehorn)) + +/datum/component/storage/concrete/pockets/pocketprotector + max_items = 3 + max_w_class = WEIGHT_CLASS_TINY + var/atom/original_parent + +/datum/component/storage/concrete/pockets/pocketprotector/Initialize() + original_parent = parent + . = ..() + can_hold = typecacheof(list( //Same items as a PDA + /obj/item/pen, + /obj/item/toy/crayon, + /obj/item/lipstick, + /obj/item/flashlight/pen, + /obj/item/clothing/mask/cigarette)) + +/datum/component/storage/concrete/pockets/pocketprotector/real_location() + // if the component is reparented to a jumpsuit, the items still go in the protector + return original_parent