From c58b4daa35e28a26728e9f6aeb7dbbec5d0ed430 Mon Sep 17 00:00:00 2001 From: Putnam Date: Fri, 24 Jan 2020 11:58:58 -0800 Subject: [PATCH] collectors too this doesn't compile but like. it's a draft --- code/game/gamemodes/objective.dm | 30 ++++++++++++++++++- code/game/objects/items/cards_ids.dm | 5 +++- code/game/objects/items/storage/book.dm | 3 ++ .../antagonists/collector/collector.dm | 19 ++++++++++++ 4 files changed, 55 insertions(+), 2 deletions(-) create mode 100644 code/modules/antagonists/collector/collector.dm diff --git a/code/game/gamemodes/objective.dm b/code/game/gamemodes/objective.dm index 11933c2717..fa302eeca8 100644 --- a/code/game/gamemodes/objective.dm +++ b/code/game/gamemodes/objective.dm @@ -999,7 +999,7 @@ GLOBAL_LIST_EMPTY(possible_items_special) /datum/objective/hoard/proc/set_target(obj/item/I) if(I) hoarded_item = I - explanation_text = "Keep [I] on your person at all costs." + explanation_text = "Keep [I] on your person at all times." return hoarded_item else explanation_text = "Free objective" @@ -1026,6 +1026,34 @@ GLOBAL_LIST_EMPTY(possible_items_special) /datum/objective/hoard/heirloom/find_target() set_target(pick(GLOB.family_heirlooms)) +GLOBAL_LIST_EMPTY(traitor_contraband) + +GLOBAL_LIST_EMPTY(cult_contraband) + +/datum/objective/hoard/collector + name = "Hoard contraband" + +/datum/objective/collector/New() + ..() + if(!GLOB.traitor_contraband.len)//Only need to fill the list when it's needed. + GLOB.traitor_contraband = list(/obj/item/card/emag/empty,/obj/item/clothing/glasses/phantomthief,/obj/item/storage/book/bible/syndicate/empty,/obj/item/clothing/gloves/chameleon/broken) + if(!GLOB.cult_contraband.len) + GLOB.cult_contraband = list(/obj/item/clockwork/slab,/obj/item/clockwork/component/belligerent_eye,/obj/item/clockwork/component/belligerent_eye/lens_gem,/obj/item/restraints/legcuffs/bola/cult,/obj/item/shuttle_curse,/obj/item/cult_shift) + +/datum/objective/hoard/collector/find_target() + var/obj/item/I + if(prob(50)) + I = new pick_and_take(GLOB.traitor_contraband) + else + I = new pick_and_take(GLOB.cult_contraband) + I.forceMove(get_turf(owner)) + if(ishuman(owner)) + var/mob/living/carbon/human/H = owner + H.equip_in_one_of_slots(I, list("backpack" = SLOT_IN_BACKPACK)) + hoarded_item = I + + + GLOBAL_LIST_EMPTY(possible_sabotages) // For saboteurs. Go in and cause some trouble somewhere. Not necessarily breaking things, just sufficiently troublemaking. /datum/objective/sabotage diff --git a/code/game/objects/items/cards_ids.dm b/code/game/objects/items/cards_ids.dm index 48dac6a08b..5ec989ab73 100644 --- a/code/game/objects/items/cards_ids.dm +++ b/code/game/objects/items/cards_ids.dm @@ -128,6 +128,9 @@ return . = ..() +/obj/item/card/emag/empty + uses = 0 + /obj/item/emagrecharge name = "electromagnet charging device" desc = "A small cell with two prongs lazily jabbed into it. It looks like it's made for charging the small batteries found in electromagnetic devices, sadly this can't be recharged like a normal cell." @@ -541,4 +544,4 @@ update_label("John Doe", "Clowny") id_color = "#0000FF" /obj/item/card/id/knight/captain - id_color = "#FFD700" \ No newline at end of file + id_color = "#FFD700" diff --git a/code/game/objects/items/storage/book.dm b/code/game/objects/items/storage/book.dm index e47021c1f6..2762be8edf 100644 --- a/code/game/objects/items/storage/book.dm +++ b/code/game/objects/items/storage/book.dm @@ -244,3 +244,6 @@ GLOBAL_LIST_INIT(bibleitemstates, list("bible", "koran", "scrapbook", "bible", /obj/item/storage/book/bible/syndicate/add_blood_DNA(list/blood_dna) return FALSE + +/obj/item/storage/book/bible/syndicate/empty + uses = 0 diff --git a/code/modules/antagonists/collector/collector.dm b/code/modules/antagonists/collector/collector.dm new file mode 100644 index 0000000000..0e7a3a52e7 --- /dev/null +++ b/code/modules/antagonists/collector/collector.dm @@ -0,0 +1,19 @@ +/datum/antagonist/collector + name = "Contraband Collector" + show_in_antagpanel = FALSE + show_name_in_check_antagonists = FALSE + blacklisted_quirks = list() // no blacklist, these guys are harmless + +/datum/antagonist/collector/proc/forge_objectives() + var/datum/objective/hoard/collector/O = new + O.owner = owner + O.find_target() + objectives += O + +/datum/antagonist/collector/on_gain() + forge_objectives() + . = ..() + +/datum/antagonist/collector/greet() + to_chat(owner, "You are a contraband collector!") + owner.announce_objectives()