mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-29 16:18:01 +01:00
Sticker packs/Chief Engineer sticker (#86154)
## About The Pull Request - Changes sticker container from a generic box to a specialised 'sticker pack' with label - Adds a Chief Engineer seal of approval sticker  ## Why It's Good For The Game The CE can now quell crew concerns about machinery they find in the hallway Before:  After:  ## Changelog 🆑 LT3 add: Added Chief Engineer SEAL OF APPROVAL sticker code: Stickers now come in sticker packs, not boxes code: Stickers can now add examine text to whatever they're stuck on /🆑
This commit is contained in:
@@ -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)
|
||||
|
||||
@@ -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)
|
||||
. = ..()
|
||||
|
||||
@@ -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 <b>FUCK THE SYSTEM</b>, 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 <b>Chief Engineer's SEAL OF APPROVAL.</b>"
|
||||
|
||||
/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 <b>Skubtide, Stationwide!</b>"
|
||||
|
||||
/obj/item/sticker/anti_skub
|
||||
name = "anti-skub sticker"
|
||||
icon_state = "anti_skub"
|
||||
examine_text = "There is an <b>anti-skub</b> sticker."
|
||||
|
||||
/obj/item/sticker/syndicate
|
||||
name = "syndicate sticker"
|
||||
icon_state = "synd"
|
||||
contraband = TRUE
|
||||
exclude_from_random = TRUE
|
||||
|
||||
/obj/item/sticker/syndicate/Initialize(mapload)
|
||||
. = ..()
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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!<br>On the back, <b>DO NOT GIVE TO THE CLOWN!</b> 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)
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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()
|
||||
. = ..()
|
||||
|
||||
@@ -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
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 13 KiB After Width: | Height: | Size: 13 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 8.3 KiB After Width: | Height: | Size: 9.3 KiB |
Reference in New Issue
Block a user