diff --git a/code/datums/components/sticker.dm b/code/datums/components/sticker.dm index 2c87d856da8..a11ab10e7c6 100644 --- a/code/datums/components/sticker.dm +++ b/code/datums/components/sticker.dm @@ -13,18 +13,21 @@ var/atom/movable/our_sticker /// Reference to the created overlay, used during component deletion. var/mutable_appearance/sticker_overlay - // Callback invoked when sticker is applied to the parent. + /// Callback invoked when sticker is applied to the parent. var/datum/callback/stick_callback - // Callback invoked when sticker is peeled (not removed) from the parent. + /// Callback invoked when sticker is peeled (not removed) from the parent. var/datum/callback/peel_callback + /// Text added to the atom's examine when stickered. + var/examine_text -/datum/component/sticker/Initialize(atom/stickering_atom, dir = NORTH, px = 0, py = 0, datum/callback/stick_callback, datum/callback/peel_callback) +/datum/component/sticker/Initialize(atom/stickering_atom, dir = NORTH, px = 0, py = 0, datum/callback/stick_callback, datum/callback/peel_callback, examine_text) if(!isatom(parent)) return COMPONENT_INCOMPATIBLE src.our_sticker = our_sticker src.stick_callback = stick_callback src.peel_callback = peel_callback + src.examine_text = examine_text stick(stickering_atom, px, py) register_turf_signals(dir) @@ -45,9 +48,10 @@ /datum/component/sticker/RegisterWithParent() RegisterSignal(parent, COMSIG_LIVING_IGNITED, PROC_REF(on_ignite)) RegisterSignal(parent, COMSIG_COMPONENT_CLEAN_ACT, PROC_REF(on_clean)) + RegisterSignal(parent, COMSIG_ATOM_EXAMINE, PROC_REF(on_examine)) /datum/component/sticker/UnregisterFromParent() - UnregisterSignal(parent, list(COMSIG_LIVING_IGNITED, COMSIG_COMPONENT_CLEAN_ACT)) + UnregisterSignal(parent, list(COMSIG_LIVING_IGNITED, COMSIG_COMPONENT_CLEAN_ACT, COMSIG_ATOM_EXAMINE)) /// Subscribes to `COMSIG_TURF_EXPOSE` if parent atom is a turf. If turf is closed - subscribes to signal /datum/component/sticker/proc/register_turf_signals(dir) @@ -116,3 +120,9 @@ if(exposed_temperature >= FIRE_MINIMUM_TEMPERATURE_TO_EXIST) qdel(our_sticker) // which qdels us + +/datum/component/sticker/proc/on_examine(atom/source, mob/user, list/examine_list) + SIGNAL_HANDLER + + if(!isnull(examine_text)) + examine_list += span_warning(examine_text) diff --git a/code/datums/station_traits/neutral_traits.dm b/code/datums/station_traits/neutral_traits.dm index 3069e644d6e..5432701992b 100644 --- a/code/datums/station_traits/neutral_traits.dm +++ b/code/datums/station_traits/neutral_traits.dm @@ -479,7 +479,7 @@ return if((skub_stance == RANDOM_SKUB && prob(50)) || skub_stance == PRO_SKUB) - var/obj/item/storage/box/skub/boxie = new(spawned.loc) + var/obj/item/storage/box/stickers/skub/boxie = new(spawned.loc) spawned.equip_to_slot_if_possible(boxie, ITEM_SLOT_BACKPACK, indirect_action = TRUE) if(ishuman(spawned)) var/obj/item/clothing/suit/costume/wellworn_shirt/skub/shirt = new(spawned.loc) @@ -496,24 +496,28 @@ shirt.forceMove(boxie) /// A box containing a skub, for easier carry because skub is a bulky item. -/obj/item/storage/box/skub - name = "skub box" - desc = "A box to store your skub and pro-skub shirt in. A label on the back reads: \"Skubtide, Stationwide\"." - icon_state = "hugbox" - illustration = "skub" +/obj/item/storage/box/stickers/skub + name = "skub fan pack" + desc = "A vinyl pouch to store your skub and pro-skub shirt in. A label on the back reads: \"Skubtide, Stationwide\"." + icon_state = "skubpack" + illustration = "label_skub" + w_class = WEIGHT_CLASS_SMALL -/obj/item/storage/box/skub/Initialize(mapload) +/obj/item/storage/box/stickers/skub/Initialize(mapload) . = ..() + atom_storage.max_slots = 3 atom_storage.exception_hold = typecacheof(list(/obj/item/skub, /obj/item/clothing/suit/costume/wellworn_shirt/skub)) -/obj/item/storage/box/skub/PopulateContents() +/obj/item/storage/box/stickers/skub/PopulateContents() new /obj/item/skub(src) new /obj/item/sticker/skub(src) new /obj/item/sticker/skub(src) /obj/item/storage/box/stickers/anti_skub - name = "anti-skub stickers box" - desc = "The enemy may have been given a skub and a shirt, but I've more stickers! Plus the box can hold my anti-skub shirt." + name = "anti-skub stickers pack" + desc = "The enemy may have been given a skub and a shirt, but I've got more stickers! Plus the pack can hold my anti-skub shirt." + icon_state = "skubpack" + illustration = "label_anti_skub" /obj/item/storage/box/stickers/anti_skub/Initialize(mapload) . = ..() diff --git a/code/game/objects/items/stickers.dm b/code/game/objects/items/stickers.dm index 19ac58f6f40..447e2022473 100644 --- a/code/game/objects/items/stickers.dm +++ b/code/game/objects/items/stickers.dm @@ -30,8 +30,10 @@ /// `list` or `null`, contains possible alternate `icon_states`. var/list/icon_states - /// Whether sticker is legal and allowed to generate inside non-syndicate boxes. - var/contraband = FALSE + /// This sticker won't be generated inside random sticker packs. + var/exclude_from_random = FALSE + /// Text added to the atom's examine when stickered. + var/examine_text /obj/item/sticker/Initialize(mapload) . = ..() @@ -85,7 +87,7 @@ user.log_message("stuck [src] to [key_name(victim)]", LOG_ATTACK) victim.log_message("had [src] stuck to them by [key_name(user)]", LOG_ATTACK) - target.AddComponent(/datum/component/sticker, src, get_dir(target, src), px, py) + target.AddComponent(/datum/component/sticker, src, get_dir(target, src), px, py, null, null, examine_text) return TRUE #undef MAX_STICKER_COUNT @@ -123,6 +125,7 @@ name = "blue R sticker" desc = "A sticker of FUCK THE SYSTEM, the galaxy's premiere hardcore punk band." icon_state = "revhead" + examine_text = "There is a sticker displaying FUCK THE SYSTEM, the galaxy's premiere hardcore punk band." /obj/item/sticker/pslime name = "slime plushie sticker" @@ -149,6 +152,12 @@ name = "toolbox sticker" icon_state = "soul" +/obj/item/sticker/chief_engineer + name = "CE approved sticker" + icon_state = "ce_approved" + exclude_from_random = TRUE + examine_text = "There is a sticker displaying the Chief Engineer's SEAL OF APPROVAL." + /obj/item/sticker/clown name = "clown sticker" icon_state = "honkman" @@ -164,15 +173,17 @@ /obj/item/sticker/skub name = "skub sticker" icon_state = "skub" + examine_text = "There is a sticker displaying Skubtide, Stationwide!" /obj/item/sticker/anti_skub name = "anti-skub sticker" icon_state = "anti_skub" + examine_text = "There is an anti-skub sticker." /obj/item/sticker/syndicate name = "syndicate sticker" icon_state = "synd" - contraband = TRUE + exclude_from_random = TRUE /obj/item/sticker/syndicate/Initialize(mapload) . = ..() diff --git a/code/game/objects/items/storage/boxes/engineering_boxes.dm b/code/game/objects/items/storage/boxes/engineering_boxes.dm index a46703ec8bf..09f641ec315 100644 --- a/code/game/objects/items/storage/boxes/engineering_boxes.dm +++ b/code/game/objects/items/storage/boxes/engineering_boxes.dm @@ -112,3 +112,12 @@ ..() for(var/i in 1 to 7) new /obj/item/tank/internals/emergency_oxygen/engi(src) //in case anyone ever wants to do anything with spawning them, apart from crafting the box + +/obj/item/storage/box/stickers/chief_engineer + name = "CE approved sticker pack" + desc = "With one of these stickers, inform the crew that the contraption in the corridor is COMPLETELY SAFE!" + illustration = "label_ce" + +/obj/item/storage/box/stickers/chief_engineer/PopulateContents() + for(var/i in 1 to 3) + new /obj/item/sticker/chief_engineer(src) diff --git a/code/game/objects/items/storage/boxes/service_boxes.dm b/code/game/objects/items/storage/boxes/service_boxes.dm index ee558d863da..767f351635d 100644 --- a/code/game/objects/items/storage/boxes/service_boxes.dm +++ b/code/game/objects/items/storage/boxes/service_boxes.dm @@ -224,14 +224,35 @@ new /obj/item/toy/balloon/long(src) /obj/item/storage/box/stickers - name = "box of stickers" - desc = "A box full of random stickers. Do give to the clown." + name = "sticker pack" + desc = "A pack of removable stickers. Removable? What a rip off!
On the back, DO NOT GIVE TO THE CLOWN! is printed in large lettering." + icon = 'icons/obj/toys/stickers.dmi' + icon_state = "stickerpack" + illustration = null + w_class = WEIGHT_CLASS_TINY + var/static/list/pack_labels = list( + "smile", + "frown", + "heart", + "silentman", + "tider", + "star", + ) + +/obj/item/storage/box/stickers/Initialize(mapload) + . = ..() + atom_storage.max_slots = 8 + atom_storage.set_holdable(list(/obj/item/sticker)) + atom_storage.max_specific_storage = WEIGHT_CLASS_TINY + if(isnull(illustration)) + illustration = pick(pack_labels) + update_appearance() /obj/item/storage/box/stickers/proc/generate_non_contraband_stickers_list() var/list/allowed_stickers = list() for(var/obj/item/sticker/sticker_type as anything in subtypesof(/obj/item/sticker)) - if(!sticker_type::contraband) + if(!sticker_type::exclude_from_random) allowed_stickers += sticker_type return allowed_stickers @@ -247,8 +268,9 @@ new type(src) /obj/item/storage/box/stickers/googly - name = "box of googly eye stickers" + name = "googly eye sticker pack" desc = "Turn anything and everything into something vaguely alive!" + illustration = "googly-alt" /obj/item/storage/box/stickers/googly/PopulateContents() for(var/i in 1 to 6) diff --git a/code/game/objects/items/storage/uplink_kits.dm b/code/game/objects/items/storage/uplink_kits.dm index eacd0b4b630..b54d4d30f3f 100644 --- a/code/game/objects/items/storage/uplink_kits.dm +++ b/code/game/objects/items/storage/uplink_kits.dm @@ -683,14 +683,7 @@ group.register(i) desc += " The implants are registered to the \"[group.name]\" group." -/obj/item/storage/box/syndie_kit/stickers - name = "sticker kit" - -/obj/item/storage/box/syndie_kit/stickers/Initialize(mapload) - . = ..() - atom_storage.max_slots = 8 - -/obj/item/storage/box/syndie_kit/stickers/PopulateContents() +/obj/item/storage/box/stickers/syndie_kit/PopulateContents() var/list/types = subtypesof(/obj/item/sticker/syndicate) for(var/i in 1 to atom_storage.max_slots) diff --git a/code/game/objects/structures/crates_lockers/closets/secure/engineering.dm b/code/game/objects/structures/crates_lockers/closets/secure/engineering.dm index 3dc59fb9ce2..22dd2bec4b2 100644 --- a/code/game/objects/structures/crates_lockers/closets/secure/engineering.dm +++ b/code/game/objects/structures/crates_lockers/closets/secure/engineering.dm @@ -18,6 +18,7 @@ new /obj/item/extinguisher/advanced(src) new /obj/item/storage/photo_album/ce(src) new /obj/item/storage/box/skillchips/engineering(src) + new /obj/item/storage/box/stickers/chief_engineer(src) /obj/structure/closet/secure_closet/engineering_chief/populate_contents_immediate() . = ..() diff --git a/code/modules/uplink/uplink_items/badass.dm b/code/modules/uplink/uplink_items/badass.dm index 08cf3affe07..5c5e0390b50 100644 --- a/code/modules/uplink/uplink_items/badass.dm +++ b/code/modules/uplink/uplink_items/badass.dm @@ -91,7 +91,7 @@ /datum/uplink_item/badass/stickers name = "Syndicate Sticker Pack" desc = "Contains 8 random stickers precisely engineered to resemble suspicious objects, which may or may not be useful for fooling crew." - item = /obj/item/storage/box/syndie_kit/stickers + item = /obj/item/storage/box/stickers/syndie_kit cost = 1 /datum/uplink_item/badass/demotivational_posters diff --git a/icons/obj/storage/box.dmi b/icons/obj/storage/box.dmi index 58c1dd661ae..747fb5462c7 100644 Binary files a/icons/obj/storage/box.dmi and b/icons/obj/storage/box.dmi differ diff --git a/icons/obj/toys/stickers.dmi b/icons/obj/toys/stickers.dmi index 37780f5fd6c..80c0e138e38 100644 Binary files a/icons/obj/toys/stickers.dmi and b/icons/obj/toys/stickers.dmi differ