From b1ec51b680c85738a1ca754e9e612009b5232aeb Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 03:46:04 -0400 Subject: [PATCH 001/120] adds basic procs for crew objectives --- code/citadel/cit_crewobjectives.dm | 44 ++++++++++++++++++++++++++++++ code/citadel/cit_miscreants.dm | 0 2 files changed, 44 insertions(+) create mode 100644 code/citadel/cit_crewobjectives.dm create mode 100644 code/citadel/cit_miscreants.dm diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm new file mode 100644 index 0000000000..70994f1e64 --- /dev/null +++ b/code/citadel/cit_crewobjectives.dm @@ -0,0 +1,44 @@ +/datum/controller/subsystem/ticker/proc/generate_crew_objectives() + for(var/datum/mind/crewMind in get_crewmember_minds()) + if(prob(10) && GLOB.master_mode != "extended")//extended is supposed to have less chaos + generate_miscreant_objectives(crewMind) + else + generate_individual_objectives(crewMind) + return + +/datum/controller/subsystem/ticker/proc/generate_individual_objectives(var/datum/mind/crewMind) + if(!crewMind) + return + if(!crewMind.current || !crewMind.objectives || crewMind.special_role) + return + if(!crewMind.assigned_role) + return + var/rolePathString = "/datum/objective/crew/[rolePathString]" + var/rolePath = text2path(rolePathString) + if (isnull(rolePath)) + return + var/list/objectiveTypes = typesof(rolePath) - rolePath + if(!objectiveTypes.len) + return + + var/selectedType = pick(objectiveTypes) + var/datum/objective/crew/newObjective = new selectedType + newObjective.owner = crewMind + crewMind.objectives += newObjective + crewMind.announce_objectives() + +/datum/objective/crew/ + explanation_text = "Yell on the coderbus discussion channel on Citadel's discord if this ever shows up. Something just broke here, dude" + +/datum/objective/crew/proc/setup() + +/datum/objective/crew/captain/ + +/datum/objective/crew/captain/hat + explanation_text = "Don't lose your hat." + +/datum/objective/crew/captain/hat/check_completion() + if(owner.current && owner.current.check_contents_for(/obj/item/clothing/head/caphat)) + return 1 + else + return 0 diff --git a/code/citadel/cit_miscreants.dm b/code/citadel/cit_miscreants.dm new file mode 100644 index 0000000000..e69de29bb2 From 790b52cf05adf7db4c58f11c5c965d86b57abd9c Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 03:50:13 -0400 Subject: [PATCH 002/120] calls crew objective generation roundstart --- code/controllers/subsystem/ticker.dm | 1 + 1 file changed, 1 insertion(+) diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index d196c9cb10..aed5a01d1f 100755 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -208,6 +208,7 @@ SUBSYSTEM_DEF(ticker) GLOB.start_landmarks_list = shuffle(GLOB.start_landmarks_list) //Shuffle the order of spawn points so they dont always predictably spawn bottom-up and right-to-left create_characters() //Create player characters collect_minds() + generate_crew_objectives() equip_characters() SSoverlays.Flush() //Flush the majority of the shit From 71805de4aa52ea2de185225a81230c0f254a9473 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 03:53:01 -0400 Subject: [PATCH 003/120] extra failsafe --- code/citadel/cit_crewobjectives.dm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 70994f1e64..29d7ae950f 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -20,9 +20,10 @@ var/list/objectiveTypes = typesof(rolePath) - rolePath if(!objectiveTypes.len) return - var/selectedType = pick(objectiveTypes) var/datum/objective/crew/newObjective = new selectedType + if(!newObjective) + return newObjective.owner = crewMind crewMind.objectives += newObjective crewMind.announce_objectives() From 6b8e46cdaee0440a6762365cbdd3d0be69643a64 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 04:10:40 -0400 Subject: [PATCH 004/120] Aaaaaand the basic miscreant stuff --- code/citadel/cit_crewobjectives.dm | 2 +- code/citadel/cit_miscreants.dm | 28 ++++++++++++++++++++++++++++ 2 files changed, 29 insertions(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 29d7ae950f..b9085260bf 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -29,7 +29,7 @@ crewMind.announce_objectives() /datum/objective/crew/ - explanation_text = "Yell on the coderbus discussion channel on Citadel's discord if this ever shows up. Something just broke here, dude" + explanation_text = "Yell on the coderbus discussion channel on Citadels discord if this ever shows up. Something just broke here, dude" /datum/objective/crew/proc/setup() diff --git a/code/citadel/cit_miscreants.dm b/code/citadel/cit_miscreants.dm index e69de29bb2..ea23a74722 100644 --- a/code/citadel/cit_miscreants.dm +++ b/code/citadel/cit_miscreants.dm @@ -0,0 +1,28 @@ +/datum/controller/subsystem/ticker/proc/generate_miscreant_objectives(var/datum/mind/crewMind) + if(GLOB.master_mode == "extended") + return //Thinking about it, extended's chaos whether or not mini-antags are present. But eh, whatever. Here's a sanity check. + if(!crewMind) + return + if(!crewMind.current || !crewMind.objectives || crewMind.special_role) + return + if(!crewMind.assigned_role) + return + var/list/objectiveTypes = typesof(/datum/objective/miscreant) - /datum/objective/miscreant + if(!objectiveTypes.len) + return + var/selectedType = pick(objectiveTypes) + var/datum/objective/crew/newObjective = new selectedType + if(!newObjective) + return + newObjective.owner = crewMind + crewMind.objectives += newObjective + crewMind.special_role = "miscreant" + to_chat(crewMind, "You are a Miscreant.") + to_chat(crewMind, "Pursuing your objective is purely optional, but it is not tracked. You may not commit any traitorous acts not directly related to them.") + crewMind.announce_objectives() + +/datum/objective/miscreant + explanation_text = "Something broke. Horribly. Dear god, im so sorry. Yell about this in the coderbus discussion channel of citadels discord." + +/datum/objective/miscreant/blockade + explanation_text = "Try to completely block off access to an area, claiming that it's too dangerous." \ No newline at end of file From d4f280495ed5ab18e2f7989a3834fdbd101e9ff7 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 04:11:50 -0400 Subject: [PATCH 005/120] almost forgot the .dme --- tgstation.dme | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tgstation.dme b/tgstation.dme index ee43dcafd7..19ea044625 100755 --- a/tgstation.dme +++ b/tgstation.dme @@ -164,10 +164,12 @@ #include "code\citadel\_cit_helpers.dm" #include "code\citadel\cit_areas.dm" #include "code\citadel\cit_arousal.dm" +#include "code\citadel\cit_crewobjectives.dm" #include "code\citadel\cit_emotes.dm" #include "code\citadel\cit_genemods.dm" #include "code\citadel\cit_guns.dm" #include "code\citadel\cit_kegs.dm" +#include "code\citadel\cit_miscreants.dm" #include "code\citadel\cit_reagents.dm" #include "code\citadel\cit_spawners.dm" #include "code\citadel\cit_uniforms.dm" From 42415aa81fd432d7b72dc9b2f89bae7c128b1317 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 04:18:41 -0400 Subject: [PATCH 006/120] aaaaaaaaaand extra miscreant objectives --- code/citadel/cit_miscreants.dm | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/code/citadel/cit_miscreants.dm b/code/citadel/cit_miscreants.dm index ea23a74722..241e65c09e 100644 --- a/code/citadel/cit_miscreants.dm +++ b/code/citadel/cit_miscreants.dm @@ -25,4 +25,19 @@ explanation_text = "Something broke. Horribly. Dear god, im so sorry. Yell about this in the coderbus discussion channel of citadels discord." /datum/objective/miscreant/blockade - explanation_text = "Try to completely block off access to an area, claiming that it's too dangerous." \ No newline at end of file + explanation_text = "Try to completely block off access to an area, under the pretense that it's too dangerous." + +/datum/objective/miscreant/incompetent + explanation_text = "Be as useless and incompetent as possible without getting killed." + +/datum/objective/miscreant/strike + explanation_text = "Try to convince your department to go on strike, and refuse to do any work." + +/datum/objective/miscreant/litterbug + explanation_text = "Make a huge mess wherever you go." + +/datum/objective/miscreant/stalk + explanation_text = "Single out a crew member and stalk them everywhere." + +/datum/objective/miscreant/creepy + explanation_text = "Sneak around looking as suspicious as possible without actually doing anything illegal." From 15f70e194312ec775c57962771c36bf5ef8ae003 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 04:34:46 -0400 Subject: [PATCH 007/120] get_crewmember_minds isn't global? --- code/citadel/cit_crewobjectives.dm | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index b9085260bf..fdfe18600e 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -1,5 +1,11 @@ /datum/controller/subsystem/ticker/proc/generate_crew_objectives() - for(var/datum/mind/crewMind in get_crewmember_minds()) + var/crewMembers = list() + for(var/V in GLOB.datacore.locked) + var/datum/data/record/R = V + var/mob/M = R.fields["reference"] + if(M && M.mind) + crewMembers += M.mind + for(var/datum/mind/crewMind in crewMembers) if(prob(10) && GLOB.master_mode != "extended")//extended is supposed to have less chaos generate_miscreant_objectives(crewMind) else From edc9c144250458e6368824bda306b9545f77ea47 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 04:37:16 -0400 Subject: [PATCH 008/120] dont code at 4 am --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index fdfe18600e..172c506d7c 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -19,7 +19,7 @@ return if(!crewMind.assigned_role) return - var/rolePathString = "/datum/objective/crew/[rolePathString]" + var/rolePathString = "/datum/objective/crew/[crewMind.assigned_role]" var/rolePath = text2path(rolePathString) if (isnull(rolePath)) return From 6ebdf0f6b9da2829f95adaaa6cef7f188037b2d2 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 04:42:47 -0400 Subject: [PATCH 009/120] dont code at 4 am 2: electric boogaloo --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 172c506d7c..81edaa6d8f 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -1,6 +1,6 @@ /datum/controller/subsystem/ticker/proc/generate_crew_objectives() var/crewMembers = list() - for(var/V in GLOB.datacore.locked) + for(var/V in GLOB.data_core.locked) var/datum/data/record/R = V var/mob/M = R.fields["reference"] if(M && M.mind) From f3a5eb58ea2a8462c434a52ddbd94aa58822a86d Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 05:03:03 -0400 Subject: [PATCH 010/120] hm --- code/citadel/cit_crewobjectives.dm | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 81edaa6d8f..b594c01e2c 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -1,11 +1,5 @@ /datum/controller/subsystem/ticker/proc/generate_crew_objectives() - var/crewMembers = list() - for(var/V in GLOB.data_core.locked) - var/datum/data/record/R = V - var/mob/M = R.fields["reference"] - if(M && M.mind) - crewMembers += M.mind - for(var/datum/mind/crewMind in crewMembers) + for(var/datum/mind/crewMind in SSticker.minds) if(prob(10) && GLOB.master_mode != "extended")//extended is supposed to have less chaos generate_miscreant_objectives(crewMind) else From 6af0856de10256c047c8910426a0bae2b35a8f44 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 05:22:12 -0400 Subject: [PATCH 011/120] too tired to find the stringtolowercase function --- code/citadel/cit_crewobjectives.dm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index b594c01e2c..58a494fe98 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -33,12 +33,12 @@ /datum/objective/crew/proc/setup() -/datum/objective/crew/captain/ +/datum/objective/crew/Captain/ -/datum/objective/crew/captain/hat +/datum/objective/crew/Captain/hat explanation_text = "Don't lose your hat." -/datum/objective/crew/captain/hat/check_completion() +/datum/objective/crew/Captain/hat/check_completion() if(owner.current && owner.current.check_contents_for(/obj/item/clothing/head/caphat)) return 1 else From b9712da5c864bcfefd46414ccc8a186b649cdace Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 05:49:31 -0400 Subject: [PATCH 012/120] properly fixes crew objective paths --- code/citadel/cit_crewobjectives.dm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 58a494fe98..b3b8c4be26 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -13,7 +13,7 @@ return if(!crewMind.assigned_role) return - var/rolePathString = "/datum/objective/crew/[crewMind.assigned_role]" + var/rolePathString = "/datum/objective/crew/[ckey(crewMind.assigned_role)]" var/rolePath = text2path(rolePathString) if (isnull(rolePath)) return @@ -33,12 +33,12 @@ /datum/objective/crew/proc/setup() -/datum/objective/crew/Captain/ +/datum/objective/crew/captain/ -/datum/objective/crew/Captain/hat +/datum/objective/crew/captain/hat explanation_text = "Don't lose your hat." -/datum/objective/crew/Captain/hat/check_completion() +/datum/objective/crew/captain/hat/check_completion() if(owner.current && owner.current.check_contents_for(/obj/item/clothing/head/caphat)) return 1 else From fc71faa59323379ddd26e3bea882884dbffba916 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 06:23:48 -0400 Subject: [PATCH 013/120] latejoin objectives and miscreants --- code/modules/mob/dead/new_player/new_player.dm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/code/modules/mob/dead/new_player/new_player.dm b/code/modules/mob/dead/new_player/new_player.dm index b11c6bc336..1dd48f69af 100644 --- a/code/modules/mob/dead/new_player/new_player.dm +++ b/code/modules/mob/dead/new_player/new_player.dm @@ -367,6 +367,10 @@ if(GLOB.highlander) to_chat(humanc, "THERE CAN BE ONLY ONE!!!") humanc.make_scottish() + if(prob(10) && GLOB.master_mode != "extended") + humanc.generate_miscreant_objectives() + else + humanc.generate_individual_objectives() GLOB.joined_player_list += character.ckey GLOB.latejoiners += character From e791a5a6379b4c15daa76da0bedeb854ea4380b8 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 06:31:55 -0400 Subject: [PATCH 014/120] hmm --- code/modules/mob/dead/new_player/new_player.dm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/code/modules/mob/dead/new_player/new_player.dm b/code/modules/mob/dead/new_player/new_player.dm index 1dd48f69af..7cdcae1281 100644 --- a/code/modules/mob/dead/new_player/new_player.dm +++ b/code/modules/mob/dead/new_player/new_player.dm @@ -355,6 +355,10 @@ var/mob/living/carbon/human/humanc if(ishuman(character)) + if(prob(10) && GLOB.master_mode != "extended") + humanc.generate_miscreant_objectives() + else + humanc.generate_individual_objectives() humanc = character //Let's retypecast the var to be human, if(humanc) //These procs all expect humans @@ -367,10 +371,6 @@ if(GLOB.highlander) to_chat(humanc, "THERE CAN BE ONLY ONE!!!") humanc.make_scottish() - if(prob(10) && GLOB.master_mode != "extended") - humanc.generate_miscreant_objectives() - else - humanc.generate_individual_objectives() GLOB.joined_player_list += character.ckey GLOB.latejoiners += character From a35126a5b26fcbf176dc301c4cf901b12fd4e07f Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 06:37:46 -0400 Subject: [PATCH 015/120] unnngh --- code/modules/mob/dead/new_player/new_player.dm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/code/modules/mob/dead/new_player/new_player.dm b/code/modules/mob/dead/new_player/new_player.dm index 7cdcae1281..428773bd9b 100644 --- a/code/modules/mob/dead/new_player/new_player.dm +++ b/code/modules/mob/dead/new_player/new_player.dm @@ -355,10 +355,6 @@ var/mob/living/carbon/human/humanc if(ishuman(character)) - if(prob(10) && GLOB.master_mode != "extended") - humanc.generate_miscreant_objectives() - else - humanc.generate_individual_objectives() humanc = character //Let's retypecast the var to be human, if(humanc) //These procs all expect humans @@ -371,6 +367,10 @@ if(GLOB.highlander) to_chat(humanc, "THERE CAN BE ONLY ONE!!!") humanc.make_scottish() + if(prob(10) && GLOB.master_mode != "extended") + SSticker.generate_miscreant_objectives(humanc.mind) + else + SSticker.generate_individual_objectives(humanc.mind) GLOB.joined_player_list += character.ckey GLOB.latejoiners += character From c56f82f6dde184ee09090b03b843fbb1a274aeb8 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 07:15:16 -0400 Subject: [PATCH 016/120] displays completed crew objectives and miscreants at round end --- code/controllers/subsystem/ticker.dm | 30 ++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index aed5a01d1f..e79c477486 100755 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -468,6 +468,20 @@ SUBSYSTEM_DEF(ticker) var/num_survivors = 0 var/num_escapees = 0 var/num_shuttle_escapees = 0 + var/list/successfulCrew = list() + var/list/miscreants = list() + + for(var/datum/mind/crewMind in minds) + if(!crewMind.current || !crewMind.objectives.len) + continue + if(var/datum/objective/miscreant/MO in crewMind.objectives) + miscreants += "[crewMind.current.real_name] (Played by: [crewMind.key]). Objective: [MO.explanation_text]" + if(var/datum/objective/crew/CO in crewMind.objectives) + if(CO.check_completion()) + to_chat(crewMind.current, "
Objective: [CO.explanation_text] Success!" + successfulCrew += "[crewMind.current.real_name] (Played by: [crewMind.key]). Objective: [CO.explanation_text]" + else + to_chat(crewMind.current, "
Objective: [CO.explanation_text] Failed." to_chat(world, "


The round has ended.") @@ -586,6 +600,22 @@ SUBSYSTEM_DEF(ticker) CHECK_TICK + if (successfulCrew.len) + tochat(world, "The following crew members completed their Crew Objectives:") + for(var/i in successfulCrew) + tochat(world, "[i]") + else + tochat(world, "Nobody completed their Crew Objectives!") + + CHECK_TICK + + if (miscreants.len) + tochat(world, " The following crew members were miscreants:") + for(var/i in miscreants) + tochat(world, "[i]") + + CHECK_TICK + mode.declare_station_goal_completion() CHECK_TICK From 9526f703a44055849c349cc66d9d91d40e22aeaf Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 07:20:45 -0400 Subject: [PATCH 017/120] coding, period, is a horrendous idea --- code/controllers/subsystem/ticker.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index e79c477486..502c24492f 100755 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -478,10 +478,10 @@ SUBSYSTEM_DEF(ticker) miscreants += "[crewMind.current.real_name] (Played by: [crewMind.key]). Objective: [MO.explanation_text]" if(var/datum/objective/crew/CO in crewMind.objectives) if(CO.check_completion()) - to_chat(crewMind.current, "
Objective: [CO.explanation_text] Success!" + to_chat(crewMind.current, "
Objective: [CO.explanation_text] Success!") successfulCrew += "[crewMind.current.real_name] (Played by: [crewMind.key]). Objective: [CO.explanation_text]" else - to_chat(crewMind.current, "
Objective: [CO.explanation_text] Failed." + to_chat(crewMind.current, "
Objective: [CO.explanation_text] Failed.") to_chat(world, "


The round has ended.") From 764df7609b8566fe545acf6e54068e7fb851b6db Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 07:25:04 -0400 Subject: [PATCH 018/120] byond is trash and so is my coding --- code/controllers/subsystem/ticker.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index 502c24492f..b386f3943d 100755 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -474,9 +474,9 @@ SUBSYSTEM_DEF(ticker) for(var/datum/mind/crewMind in minds) if(!crewMind.current || !crewMind.objectives.len) continue - if(var/datum/objective/miscreant/MO in crewMind.objectives) + for(var/datum/objective/miscreant/MO in crewMind.objectives) miscreants += "[crewMind.current.real_name] (Played by: [crewMind.key]). Objective: [MO.explanation_text]" - if(var/datum/objective/crew/CO in crewMind.objectives) + for(var/datum/objective/crew/CO in crewMind.objectives) if(CO.check_completion()) to_chat(crewMind.current, "
Objective: [CO.explanation_text] Success!") successfulCrew += "[crewMind.current.real_name] (Played by: [crewMind.key]). Objective: [CO.explanation_text]" From 26a63c2f76f139a7e65675487a04e7e45bb451ee Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 07:29:51 -0400 Subject: [PATCH 019/120] should compile just fine now --- code/controllers/subsystem/ticker.dm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index b386f3943d..0c59407ca8 100755 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -601,18 +601,18 @@ SUBSYSTEM_DEF(ticker) CHECK_TICK if (successfulCrew.len) - tochat(world, "The following crew members completed their Crew Objectives:") + to_chat(world, "The following crew members completed their Crew Objectives:") for(var/i in successfulCrew) - tochat(world, "[i]") + to_chat(world, "[i]") else - tochat(world, "Nobody completed their Crew Objectives!") + to_chat(world, "Nobody completed their Crew Objectives!") CHECK_TICK if (miscreants.len) - tochat(world, " The following crew members were miscreants:") + to_chat(world, " The following crew members were miscreants:") for(var/i in miscreants) - tochat(world, "[i]") + to_chat(world, "[i]") CHECK_TICK From 964a591c98729e9450596bedec165f2e012ceb2b Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 07:42:04 -0400 Subject: [PATCH 020/120] adds more miscreant objectives --- code/citadel/cit_miscreants.dm | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/code/citadel/cit_miscreants.dm b/code/citadel/cit_miscreants.dm index 241e65c09e..e383dfbb51 100644 --- a/code/citadel/cit_miscreants.dm +++ b/code/citadel/cit_miscreants.dm @@ -41,3 +41,12 @@ /datum/objective/miscreant/creepy explanation_text = "Sneak around looking as suspicious as possible without actually doing anything illegal." + +/datum/objective/miscreant/construction + explanation_text = "Perform obnoxious construction and renovation projects. Insist that you're just doing your job." + +/datum/objective/miscreant/access + explanation_text = "Make as much of the station as possible accessible to the public." + +/datum/objective/miscreant/whiny + explanation_text = "Complain incessantly about every minor issue you find." From 2e0c36024e5821ff2094ee7e34e4b8b31a8828d2 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 15:41:22 -0400 Subject: [PATCH 021/120] Small cleanup --- code/controllers/subsystem/ticker.dm | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index 0c59407ca8..5ad749836b 100755 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -471,18 +471,6 @@ SUBSYSTEM_DEF(ticker) var/list/successfulCrew = list() var/list/miscreants = list() - for(var/datum/mind/crewMind in minds) - if(!crewMind.current || !crewMind.objectives.len) - continue - for(var/datum/objective/miscreant/MO in crewMind.objectives) - miscreants += "[crewMind.current.real_name] (Played by: [crewMind.key]). Objective: [MO.explanation_text]" - for(var/datum/objective/crew/CO in crewMind.objectives) - if(CO.check_completion()) - to_chat(crewMind.current, "
Objective: [CO.explanation_text] Success!") - successfulCrew += "[crewMind.current.real_name] (Played by: [crewMind.key]). Objective: [CO.explanation_text]" - else - to_chat(crewMind.current, "
Objective: [CO.explanation_text] Failed.") - to_chat(world, "


The round has ended.") //Player status report @@ -600,12 +588,26 @@ SUBSYSTEM_DEF(ticker) CHECK_TICK + for(var/datum/mind/crewMind in minds) + if(!crewMind.current || !crewMind.objectives.len) + continue + for(var/datum/objective/miscreant/MO in crewMind.objectives) + miscreants += "[crewMind.current.real_name] (Played by: [crewMind.key]). Objective: [MO.explanation_text]" + for(var/datum/objective/crew/CO in crewMind.objectives) + if(CO.check_completion()) + to_chat(crewMind.current, "
Objective: [CO.explanation_text] Success!") + successfulCrew += "[crewMind.current.real_name] (Played by: [crewMind.key]). Objective: [CO.explanation_text]" + else + to_chat(crewMind.current, "
Objective: [CO.explanation_text] Failed.") + if (successfulCrew.len) to_chat(world, "The following crew members completed their Crew Objectives:") for(var/i in successfulCrew) to_chat(world, "[i]") + to_chat(world, "
") else to_chat(world, "Nobody completed their Crew Objectives!") + to_chat(world, "
") CHECK_TICK From 2ade816524569100d380c122e29cd83ba6cf3d01 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 17:47:01 -0400 Subject: [PATCH 022/120] More objectives --- code/citadel/cit_crewobjectives.dm | 65 ++++++++++++++++++++++++++++ code/citadel/cit_miscreants.dm | 3 ++ code/controllers/subsystem/ticker.dm | 1 + 3 files changed, 69 insertions(+) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index b3b8c4be26..6935106ed6 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -33,6 +33,8 @@ /datum/objective/crew/proc/setup() +/* COMMAND OBJECTIVES */ + /datum/objective/crew/captain/ /datum/objective/crew/captain/hat @@ -43,3 +45,66 @@ return 1 else return 0 + +/datum/objective/crew/captain/datfukkendisk + explanation_text = "Defend the nuclear authentication disk at all costs, and personally deliver it to Centcom." + +/datum/objective/crew/captain/datfukkendisk/check_completion() + if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) + return 1 + else + return 0 + +/* SECURITY OBJECTIVES */ + +/datum/objective/crew/headofsecurity/ + +/datum/objective/crew/headofsecurity/justicecrew + explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." + +/datum/objective/crew/headofsecurity/justicecrew/check_completion() + if(owner.current) + for(var/datum/mind/M in SSticker.minds) + if(M.current && isliving(owner)) + if(!M.special_role && !M.assigned_role = "Security Officer" && !M.assigned_role = "Detective" && !M.assigned_role = "Head of Security" && !M.assigned_role = "Lawyer" && get_area(M.current) != typesof(/area/security)) + return 0 + return 1 + +/datum/objective/crew/securityofficer/ + +/datum/objective/crew/securityofficer/justicecrew + explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." + +/datum/objective/crew/securityofficer/justicecrew/check_completion() + if(owner.current) + for(var/datum/mind/M in SSticker.minds) + if(M.current && isliving(owner)) + if(!M.special_role && !M.assigned_role = "Security Officer" && !M.assigned_role = "Detective" && !M.assigned_role = "Head of Security" && !M.assigned_role = "Lawyer" && get_area(M.current) != typesof(/area/security)) + return 0 + return 1 + +/datum/objective/crew/detective/ + +/datum/objective/crew/detective/justicecrew + explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." + +/datum/objective/crew/detective/justicecrew/check_completion() + if(owner.current) + for(var/datum/mind/M in SSticker.minds) + if(M.current && isliving(owner)) + if(!M.special_role && !M.assigned_role = "Security Officer" && !M.assigned_role = "Detective" && !M.assigned_role = "Head of Security" && !M.assigned_role = "Lawyer" && get_area(M.current) != typesof(/area/security)) + return 0 + return 1 + +/datum/objective/crew/lawyer/ + +/datum/objective/crew/lawyer/justicecrew + explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." + +/datum/objective/crew/lawyer/justicecrew/check_completion() + if(owner.current) + for(var/datum/mind/M in SSticker.minds) + if(M.current && isliving(owner)) + if(!M.special_role && !M.assigned_role = "Security Officer" && !M.assigned_role = "Detective" && !M.assigned_role = "Head of Security" && !M.assigned_role = "Lawyer" && get_area(M.current) != typesof(/area/security)) + return 0 + return 1 diff --git a/code/citadel/cit_miscreants.dm b/code/citadel/cit_miscreants.dm index e383dfbb51..dcfe4b4b26 100644 --- a/code/citadel/cit_miscreants.dm +++ b/code/citadel/cit_miscreants.dm @@ -50,3 +50,6 @@ /datum/objective/miscreant/whiny explanation_text = "Complain incessantly about every minor issue you find." + +/datum/objective/miscreant/immersions + explanation_text = "Act as out of character as you possibly can." diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index 5ad749836b..d288a7fe58 100755 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -615,6 +615,7 @@ SUBSYSTEM_DEF(ticker) to_chat(world, " The following crew members were miscreants:") for(var/i in miscreants) to_chat(world, "[i]") + to_chat(world, "
") CHECK_TICK From d6ec2184dfb28ced4485f8fbce47ba806e42cbf2 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 18:20:17 -0400 Subject: [PATCH 023/120] welp. my code is shit --- code/citadel/cit_crewobjectives.dm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 6935106ed6..7ca624f683 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -66,7 +66,7 @@ if(owner.current) for(var/datum/mind/M in SSticker.minds) if(M.current && isliving(owner)) - if(!M.special_role && !M.assigned_role = "Security Officer" && !M.assigned_role = "Detective" && !M.assigned_role = "Head of Security" && !M.assigned_role = "Lawyer" && get_area(M.current) != typesof(/area/security)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && get_area(M.current) != typesof(/area/security)) return 0 return 1 @@ -79,7 +79,7 @@ if(owner.current) for(var/datum/mind/M in SSticker.minds) if(M.current && isliving(owner)) - if(!M.special_role && !M.assigned_role = "Security Officer" && !M.assigned_role = "Detective" && !M.assigned_role = "Head of Security" && !M.assigned_role = "Lawyer" && get_area(M.current) != typesof(/area/security)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && get_area(M.current) != typesof(/area/security)) return 0 return 1 @@ -92,7 +92,7 @@ if(owner.current) for(var/datum/mind/M in SSticker.minds) if(M.current && isliving(owner)) - if(!M.special_role && !M.assigned_role = "Security Officer" && !M.assigned_role = "Detective" && !M.assigned_role = "Head of Security" && !M.assigned_role = "Lawyer" && get_area(M.current) != typesof(/area/security)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && get_area(M.current) != typesof(/area/security)) return 0 return 1 @@ -105,6 +105,6 @@ if(owner.current) for(var/datum/mind/M in SSticker.minds) if(M.current && isliving(owner)) - if(!M.special_role && !M.assigned_role = "Security Officer" && !M.assigned_role = "Detective" && !M.assigned_role = "Head of Security" && !M.assigned_role = "Lawyer" && get_area(M.current) != typesof(/area/security)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && get_area(M.current) != typesof(/area/security)) return 0 return 1 From 35bdf826cd8b999902f7a04da30a2adecaf825e3 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 18:36:52 -0400 Subject: [PATCH 024/120] byond was a mistake --- code/citadel/cit_miscreants.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_miscreants.dm b/code/citadel/cit_miscreants.dm index dcfe4b4b26..621b7701dc 100644 --- a/code/citadel/cit_miscreants.dm +++ b/code/citadel/cit_miscreants.dm @@ -11,7 +11,7 @@ if(!objectiveTypes.len) return var/selectedType = pick(objectiveTypes) - var/datum/objective/crew/newObjective = new selectedType + var/datum/objective/miscreant/newObjective = new selectedType if(!newObjective) return newObjective.owner = crewMind From 3d4d2d702426e36b973aac417deb3cd27598a3f3 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 22:04:52 -0400 Subject: [PATCH 025/120] Adjustments, adds a basic objective for roboticists --- code/citadel/cit_crewobjectives.dm | 56 ++++++++++++++++++++++++++-- code/citadel/cit_miscreants.dm | 2 +- code/controllers/subsystem/ticker.dm | 4 +- 3 files changed, 55 insertions(+), 7 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 7ca624f683..76ab337891 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -65,7 +65,7 @@ /datum/objective/crew/headofsecurity/justicecrew/check_completion() if(owner.current) for(var/datum/mind/M in SSticker.minds) - if(M.current && isliving(owner)) + if(M.current && isliving(M.current)) if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && get_area(M.current) != typesof(/area/security)) return 0 return 1 @@ -78,7 +78,7 @@ /datum/objective/crew/securityofficer/justicecrew/check_completion() if(owner.current) for(var/datum/mind/M in SSticker.minds) - if(M.current && isliving(owner)) + if(M.current && isliving(M.current)) if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && get_area(M.current) != typesof(/area/security)) return 0 return 1 @@ -91,7 +91,7 @@ /datum/objective/crew/detective/justicecrew/check_completion() if(owner.current) for(var/datum/mind/M in SSticker.minds) - if(M.current && isliving(owner)) + if(M.current && isliving(M.current)) if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && get_area(M.current) != typesof(/area/security)) return 0 return 1 @@ -104,7 +104,55 @@ /datum/objective/crew/lawyer/justicecrew/check_completion() if(owner.current) for(var/datum/mind/M in SSticker.minds) - if(M.current && isliving(owner)) + if(M.current && isliving(M.current)) if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && get_area(M.current) != typesof(/area/security)) return 0 return 1 + +/* SCIENCE OBJECTIVES */ + +/datum/objective/crew/researchdirector/ + +/datum/objective/crew/researchdirector/cyborgs + explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's codebus discussion channel about this) functioning cyborgs when the shift ends." + +/datum/objective/crew/researchdirector/cyborgs/New() + target_amount = rand(3,20) + update_explanation_text() + +/datum/objective/crew/researchdirector/cyborgs/update_explanation_text() + . = ..() + explanation_text = "Ensure there are at least [target_amount] functioning cyborgs when the shift ends." + +/datum/objective/crew/researchdirector/cyborgs/check_completion() + var/borgcount = target_amount + for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) + if(!R.stat == DEAD) + borgcount-- + if(borgcount <= 0) + return 1 + else + return 0 + +/datum/objective/crew/roboticist/ + +/datum/objective/crew/roboticist/cyborgs + explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's codebus discussion channel about this) functioning cyborgs when the shift ends." + +/datum/objective/crew/roboticist/cyborgs/New() + target_amount = rand(3,20) + update_explanation_text() + +/datum/objective/crew/roboticist/cyborgs/update_explanation_text() + . = ..() + explanation_text = "Ensure there are at least [target_amount] functioning cyborgs when the shift ends." + +/datum/objective/crew/roboticist/cyborgs/check_completion() + var/borgcount = target_amount + for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) + if(!R.stat == DEAD) + borgcount-- + if(borgcount <= 0) + return 1 + else + return 0 diff --git a/code/citadel/cit_miscreants.dm b/code/citadel/cit_miscreants.dm index 621b7701dc..d362f74251 100644 --- a/code/citadel/cit_miscreants.dm +++ b/code/citadel/cit_miscreants.dm @@ -18,7 +18,7 @@ crewMind.objectives += newObjective crewMind.special_role = "miscreant" to_chat(crewMind, "You are a Miscreant.") - to_chat(crewMind, "Pursuing your objective is purely optional, but it is not tracked. You may not commit any traitorous acts not directly related to them.") + to_chat(crewMind, "Pursuing your objective is entirely optional, but it isn't tracked. Performing traitorous acts not directly related to your objective may result in permanent termination of your employment.") crewMind.announce_objectives() /datum/objective/miscreant diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index d288a7fe58..dfe55379f1 100755 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -595,10 +595,10 @@ SUBSYSTEM_DEF(ticker) miscreants += "[crewMind.current.real_name] (Played by: [crewMind.key]). Objective: [MO.explanation_text]" for(var/datum/objective/crew/CO in crewMind.objectives) if(CO.check_completion()) - to_chat(crewMind.current, "
Objective: [CO.explanation_text] Success!") + to_chat(crewMind.current, "
Your objective: [CO.explanation_text] Success!") successfulCrew += "[crewMind.current.real_name] (Played by: [crewMind.key]). Objective: [CO.explanation_text]" else - to_chat(crewMind.current, "
Objective: [CO.explanation_text] Failed.") + to_chat(crewMind.current, "
Your objective: [CO.explanation_text] Failed.") if (successfulCrew.len) to_chat(world, "The following crew members completed their Crew Objectives:") From dce076f76b1752625d457a9988429150dd1b6a2d Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 22:45:53 -0400 Subject: [PATCH 026/120] just to make sure nothing breaks --- code/citadel/cit_crewobjectives.dm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 76ab337891..71a146fc22 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -117,6 +117,7 @@ explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's codebus discussion channel about this) functioning cyborgs when the shift ends." /datum/objective/crew/researchdirector/cyborgs/New() + . = ..() target_amount = rand(3,20) update_explanation_text() @@ -140,6 +141,7 @@ explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's codebus discussion channel about this) functioning cyborgs when the shift ends." /datum/objective/crew/roboticist/cyborgs/New() + . = ..() target_amount = rand(3,20) update_explanation_text() From 4af7100b7b519f7c85bdd70602cbb697834a8bc6 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 4 Sep 2017 23:34:37 -0400 Subject: [PATCH 027/120] Adds potential for conflict between captain, HOP, and HOS. also adds a unique HOP objective --- code/citadel/cit_crewobjectives.dm | 33 +++++++++++++++++++++++++++++- 1 file changed, 32 insertions(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 71a146fc22..c5e929aca5 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -47,7 +47,7 @@ return 0 /datum/objective/crew/captain/datfukkendisk - explanation_text = "Defend the nuclear authentication disk at all costs, and personally deliver it to Centcom." + explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." /datum/objective/crew/captain/datfukkendisk/check_completion() if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) @@ -55,6 +55,28 @@ else return 0 +/datum/objective/crew/headofpersonnel/ + +/datum/objective/crew/headofpersonnel/ian + explanation_text = "Defend Ian at all costs, and ensure he gets delivered to Centcom at the end of the shift." + +/datum/objective/crew/headofpersonnel/ian/check_completion() + if(owner.current) + for(var/mob/living/simple_animal/pet/dog/corgi/Ian/goodboy in world) + if(goodboy.stat != DEAD && SSshuttle.emergency.shuttle_areas[get_area(goodboy)]) + return 1 + return 0 + return 0 + +/datum/objective/crew/headofpersonnel/datfukkendisk + explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." + +/datum/objective/crew/headofpersonnel/datfukkendisk/check_completion() + if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) + return 1 + else + return 0 + /* SECURITY OBJECTIVES */ /datum/objective/crew/headofsecurity/ @@ -70,6 +92,15 @@ return 0 return 1 +/datum/objective/crew/headofsecurity/datfukkendisk + explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." + +/datum/objective/crew/headofsecurity/datfukkendisk/check_completion() + if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) + return 1 + else + return 0 + /datum/objective/crew/securityofficer/ /datum/objective/crew/securityofficer/justicecrew From 38e4c86666f9dfa59560a82647b9cb72f42e4fe9 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 01:12:05 -0400 Subject: [PATCH 028/120] more objectives + fixes --- code/citadel/cit_crewobjectives.dm | 66 ++++++++++++++++++++++++++++-- 1 file changed, 62 insertions(+), 4 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index c5e929aca5..63a0347951 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -88,7 +88,7 @@ if(owner.current) for(var/datum/mind/M in SSticker.minds) if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && get_area(M.current) != typesof(/area/security)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) return 0 return 1 @@ -110,7 +110,20 @@ if(owner.current) for(var/datum/mind/M in SSticker.minds) if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && get_area(M.current) != typesof(/area/security)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) + return 0 + return 1 + +/datum/objective/crew/warden/ + +/datum/objective/crew/warden/justicecrew + explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." + +/datum/objective/crew/warden/justicecrew/check_completion() + if(owner.current) + for(var/datum/mind/M in SSticker.minds) + if(M.current && isliving(M.current)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) return 0 return 1 @@ -123,7 +136,7 @@ if(owner.current) for(var/datum/mind/M in SSticker.minds) if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && get_area(M.current) != typesof(/area/security)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) return 0 return 1 @@ -136,7 +149,7 @@ if(owner.current) for(var/datum/mind/M in SSticker.minds) if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && get_area(M.current) != typesof(/area/security)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) return 0 return 1 @@ -189,3 +202,48 @@ return 1 else return 0 + +/* ENGINEERING OBJECTIVES */ + +/* MEDICAL OBJECTIVES */ + +/datum/objective/crew/chiefmedicalofficer/ + +/datum/objective/crew/chiefmedicalofficer/morgue + explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." + +/datum/objective/crew/chiefmedicalofficer/morgue/check_completion() + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(H.stat == DEAD && H.z == ZLEVEL_STATION) + if(get_area.H != /area/medical/morgue) + return 0 + return 1 + +/datum/objective/crew/geneticist + +/datum/objective/crew/geneticist/morgue + explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." + +/datum/objective/crew/geneticist/morgue/check_completion() + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(H.stat == DEAD && H.z == ZLEVEL_STATION) + if(get_area.H != /area/medical/morgue) + return 0 + return 1 + +/datum/objective/crew/medicaldoctor + +/datum/objective/crew/medicaldoctor/morgue + explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." + +/datum/objective/crew/medicaldoctor/morgue/check_completion() + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(H.stat == DEAD && H.z == ZLEVEL_STATION) + if(get_area.H != /area/medical/morgue) + return 0 + return 1 + + +/* CARGO OBJECTIVES */ + +/* CIVILLIAN OBJECTIVES */ From af7ad3e620541514c93fda91af45e96cf6ac6200 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 01:21:18 -0400 Subject: [PATCH 029/120] reee --- code/citadel/cit_crewobjectives.dm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 63a0347951..7d396e3e33 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -215,7 +215,7 @@ /datum/objective/crew/chiefmedicalofficer/morgue/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.z == ZLEVEL_STATION) - if(get_area.H != /area/medical/morgue) + if(get_area(H) != /area/medical/morgue) return 0 return 1 @@ -227,7 +227,7 @@ /datum/objective/crew/geneticist/morgue/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.z == ZLEVEL_STATION) - if(get_area.H != /area/medical/morgue) + if(get_area(H) != /area/medical/morgue) return 0 return 1 @@ -239,7 +239,7 @@ /datum/objective/crew/medicaldoctor/morgue/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.z == ZLEVEL_STATION) - if(get_area.H != /area/medical/morgue) + if(get_area(H) != /area/medical/morgue) return 0 return 1 From 396251665e4dfad3d76bd48589ab2df5f292015b Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 01:40:35 -0400 Subject: [PATCH 030/120] added comments to show where objectives are ported from --- code/citadel/cit_crewobjectives.dm | 20 ++++++++++---------- code/citadel/cit_miscreants.dm | 4 ++++ 2 files changed, 14 insertions(+), 10 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 7d396e3e33..2c3b0d8524 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -37,7 +37,7 @@ /datum/objective/crew/captain/ -/datum/objective/crew/captain/hat +/datum/objective/crew/captain/hat //Ported from Goon explanation_text = "Don't lose your hat." /datum/objective/crew/captain/hat/check_completion() @@ -46,7 +46,7 @@ else return 0 -/datum/objective/crew/captain/datfukkendisk +/datum/objective/crew/captain/datfukkendisk //Ported from old Hippie explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." /datum/objective/crew/captain/datfukkendisk/check_completion() @@ -57,7 +57,7 @@ /datum/objective/crew/headofpersonnel/ -/datum/objective/crew/headofpersonnel/ian +/datum/objective/crew/headofpersonnel/ian //Ported from old Hippie explanation_text = "Defend Ian at all costs, and ensure he gets delivered to Centcom at the end of the shift." /datum/objective/crew/headofpersonnel/ian/check_completion() @@ -68,7 +68,7 @@ return 0 return 0 -/datum/objective/crew/headofpersonnel/datfukkendisk +/datum/objective/crew/headofpersonnel/datfukkendisk //Ported from old Hippie explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." /datum/objective/crew/headofpersonnel/datfukkendisk/check_completion() @@ -92,7 +92,7 @@ return 0 return 1 -/datum/objective/crew/headofsecurity/datfukkendisk +/datum/objective/crew/headofsecurity/datfukkendisk //Ported from old Hippie explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." /datum/objective/crew/headofsecurity/datfukkendisk/check_completion() @@ -157,7 +157,7 @@ /datum/objective/crew/researchdirector/ -/datum/objective/crew/researchdirector/cyborgs +/datum/objective/crew/researchdirector/cyborgs //Ported from old Hippie explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's codebus discussion channel about this) functioning cyborgs when the shift ends." /datum/objective/crew/researchdirector/cyborgs/New() @@ -181,7 +181,7 @@ /datum/objective/crew/roboticist/ -/datum/objective/crew/roboticist/cyborgs +/datum/objective/crew/roboticist/cyborgs //Ported from old Hippie explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's codebus discussion channel about this) functioning cyborgs when the shift ends." /datum/objective/crew/roboticist/cyborgs/New() @@ -209,7 +209,7 @@ /datum/objective/crew/chiefmedicalofficer/ -/datum/objective/crew/chiefmedicalofficer/morgue +/datum/objective/crew/chiefmedicalofficer/morgue //Ported from old Hippie explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." /datum/objective/crew/chiefmedicalofficer/morgue/check_completion() @@ -221,7 +221,7 @@ /datum/objective/crew/geneticist -/datum/objective/crew/geneticist/morgue +/datum/objective/crew/geneticist/morgue //Ported from old Hippie explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." /datum/objective/crew/geneticist/morgue/check_completion() @@ -233,7 +233,7 @@ /datum/objective/crew/medicaldoctor -/datum/objective/crew/medicaldoctor/morgue +/datum/objective/crew/medicaldoctor/morgue //Ported from old Hippie explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." /datum/objective/crew/medicaldoctor/morgue/check_completion() diff --git a/code/citadel/cit_miscreants.dm b/code/citadel/cit_miscreants.dm index d362f74251..fbd89c1827 100644 --- a/code/citadel/cit_miscreants.dm +++ b/code/citadel/cit_miscreants.dm @@ -24,6 +24,8 @@ /datum/objective/miscreant explanation_text = "Something broke. Horribly. Dear god, im so sorry. Yell about this in the coderbus discussion channel of citadels discord." +/* Goon's Miscreant Objectives */ + /datum/objective/miscreant/blockade explanation_text = "Try to completely block off access to an area, under the pretense that it's too dangerous." @@ -51,5 +53,7 @@ /datum/objective/miscreant/whiny explanation_text = "Complain incessantly about every minor issue you find." +/* Citadel's Miscreant Objectives */ + /datum/objective/miscreant/immersions explanation_text = "Act as out of character as you possibly can." From 6313f24c6a9f9b6c4cf2e1251af70dc0c121e773 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 01:57:00 -0400 Subject: [PATCH 031/120] adds petsplosion for assistants --- code/citadel/cit_crewobjectives.dm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 2c3b0d8524..e63cc22e6b 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -247,3 +247,27 @@ /* CARGO OBJECTIVES */ /* CIVILLIAN OBJECTIVES */ + +/datum/objective/crew/assistant + +/datum/objective/crew/assistant/petsplosion + explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the codebus discussion channel) animals on the station by the end of the shift. Anthropomorphic animals do not count." + +/datum/objective/crew/assistant/petsplosion/New() + . = ..() + target_amount = rand(5,75) + update_explanation_text() + +/datum/objective/crew/assistant/petsplosion/update_explanation_text() + . = ..() + explanation_text = "Ensure there are at least [target_amount] animals on the station by the end of the shift. Anthropomorphic animals do not count." + +/datum/objective/crew/assistant/petsplosion/check_completion() + var/petcount = target_amount + for(var/mob/living/simple_animal/pet/P in world) + if(!P.stat == DEAD) + petcount-- + if(petcount <= 0) + return 1 + else + return 0 From e340a0fd5ba763235b9a122381943f521d41d63c Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 11:37:53 -0400 Subject: [PATCH 032/120] improves petsplosion, adds it to cargo tech and qm --- code/citadel/cit_crewobjectives.dm | 78 +++++++++++++++++++++++++++--- 1 file changed, 72 insertions(+), 6 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index e63cc22e6b..8c883a3d30 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -62,7 +62,7 @@ /datum/objective/crew/headofpersonnel/ian/check_completion() if(owner.current) - for(var/mob/living/simple_animal/pet/dog/corgi/Ian/goodboy in world) + for(var/mob/living/simple_animal/pet/dog/corgi/Ian/goodboy in GLOB.mob_list) if(goodboy.stat != DEAD && SSshuttle.emergency.shuttle_areas[get_area(goodboy)]) return 1 return 0 @@ -246,27 +246,93 @@ /* CARGO OBJECTIVES */ +/datum/objective/crew/quartermaster + +/datum/objective/crew/quartermaster/petsplosion + explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the codebus discussion channel) pets on the station by the end of the shift. Interpret this as you wish." + +/datum/objective/crew/quartermaster/petsplosion/New() + . = ..() + target_amount = rand(10,75) + update_explanation_text() + +/datum/objective/crew/quartermaster/petsplosion/update_explanation_text() + . = ..() + explanation_text = "Ensure there are at least [target_amount] pets on the station by the end of the shift. Interpret this as you wish." + +/datum/objective/crew/quartermaster/petsplosion/check_completion() + var/petcount = target_amount + for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) + if(!P.stat == DEAD) + if(P.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) + petcount-- + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(!H.stat == DEAD) + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if(istype(H.neck, /obj/item/clothing/neck/petcollar) + petcount-- + if(petcount <= 0) + return 1 + else + return 0 + +/datum/objective/crew/cargotechnician + +/datum/objective/crew/cargotechnician/petsplosion + explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the codebus discussion channel) pets on the station by the end of the shift. Interpret this as you wish." + +/datum/objective/crew/assistant/petsplosion/New() + . = ..() + target_amount = rand(10,75) + update_explanation_text() + +/datum/objective/crew/cargotechnician/petsplosion/update_explanation_text() + . = ..() + explanation_text = "Ensure there are at least [target_amount] pets on the station by the end of the shift. Interpret this as you wish." + +/datum/objective/crew/cargotechnician/petsplosion/check_completion() + var/petcount = target_amount + for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) + if(!P.stat == DEAD) + if(P.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) + petcount-- + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(!H.stat == DEAD) + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if(istype(H.neck, /obj/item/clothing/neck/petcollar) + petcount-- + if(petcount <= 0) + return 1 + else + return 0 + /* CIVILLIAN OBJECTIVES */ /datum/objective/crew/assistant /datum/objective/crew/assistant/petsplosion - explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the codebus discussion channel) animals on the station by the end of the shift. Anthropomorphic animals do not count." + explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the codebus discussion channel) pets on the station by the end of the shift. Interpret this as you wish." /datum/objective/crew/assistant/petsplosion/New() . = ..() - target_amount = rand(5,75) + target_amount = rand(10,75) update_explanation_text() /datum/objective/crew/assistant/petsplosion/update_explanation_text() . = ..() - explanation_text = "Ensure there are at least [target_amount] animals on the station by the end of the shift. Anthropomorphic animals do not count." + explanation_text = "Ensure there are at least [target_amount] pets on the station by the end of the shift. Interpret this as you wish." /datum/objective/crew/assistant/petsplosion/check_completion() var/petcount = target_amount - for(var/mob/living/simple_animal/pet/P in world) + for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) if(!P.stat == DEAD) - petcount-- + if(P.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) + petcount-- + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(!H.stat == DEAD) + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if(istype(H.neck, /obj/item/clothing/neck/petcollar) + petcount-- if(petcount <= 0) return 1 else From 3a0d1dc982b4aec990cf7f664152d54355cb7843 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 12:01:00 -0400 Subject: [PATCH 033/120] Nerfs compiling errors, lowers expectations for assistants --- code/citadel/cit_crewobjectives.dm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 8c883a3d30..e05c90e1d8 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -269,7 +269,7 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(!H.stat == DEAD) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(istype(H.neck, /obj/item/clothing/neck/petcollar) + if(istype(H.neck, /obj/item/clothing/neck/petcollar)) petcount-- if(petcount <= 0) return 1 @@ -299,7 +299,7 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(!H.stat == DEAD) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(istype(H.neck, /obj/item/clothing/neck/petcollar) + if(istype(H.neck, /obj/item/clothing/neck/petcollar)) petcount-- if(petcount <= 0) return 1 @@ -315,7 +315,7 @@ /datum/objective/crew/assistant/petsplosion/New() . = ..() - target_amount = rand(10,75) + target_amount = rand(10,25) update_explanation_text() /datum/objective/crew/assistant/petsplosion/update_explanation_text() @@ -331,7 +331,7 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(!H.stat == DEAD) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(istype(H.neck, /obj/item/clothing/neck/petcollar) + if(istype(H.neck, /obj/item/clothing/neck/petcollar)) petcount-- if(petcount <= 0) return 1 From c2d86f12e99c158acfb49623cd8e281c79cd898f Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 12:44:07 -0400 Subject: [PATCH 034/120] gives the bartender ONE JOB and actually nerfs compiling errors --- code/citadel/cit_crewobjectives.dm | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index e05c90e1d8..3bed8fb1a9 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -269,7 +269,7 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(!H.stat == DEAD) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(istype(H.neck, /obj/item/clothing/neck/petcollar)) + if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) petcount-- if(petcount <= 0) return 1 @@ -299,7 +299,7 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(!H.stat == DEAD) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(istype(H.neck, /obj/item/clothing/neck/petcollar)) + if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) petcount-- if(petcount <= 0) return 1 @@ -308,6 +308,19 @@ /* CIVILLIAN OBJECTIVES */ +/datum/objective/crew/bartender + +/datum/objective/crew/bartender/responsibility + explanation_text = "Make sure nobody dies of alchohol poisoning." + +/datum/objective/crew/bartender/responsibility/check_completion() + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(H.stat == DEAD && H.reagents) + if(H.reagents.has_reagent(ethanol)) + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) + return 0 + return 1 + /datum/objective/crew/assistant /datum/objective/crew/assistant/petsplosion @@ -331,7 +344,7 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(!H.stat == DEAD) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(istype(H.neck, /obj/item/clothing/neck/petcollar)) + if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) petcount-- if(petcount <= 0) return 1 From 2cb959b4cf8ee4c2fdce2d0077746d463459339d Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 12:54:43 -0400 Subject: [PATCH 035/120] daMNIT --- code/citadel/cit_crewobjectives.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 3bed8fb1a9..21c99604fb 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -316,8 +316,8 @@ /datum/objective/crew/bartender/responsibility/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.reagents) - if(H.reagents.has_reagent(ethanol)) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) + if(H.reagents.has_reagent(typesof(/datum/reagent/consumable/ethanol))) + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) return 0 return 1 From eb03ce69d4e9dfa2e3a22f09d753cf42c0eda9c6 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 12:59:05 -0400 Subject: [PATCH 036/120] it'll work properly eventually --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 21c99604fb..c113889502 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -316,7 +316,7 @@ /datum/objective/crew/bartender/responsibility/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.reagents) - if(H.reagents.has_reagent(typesof(/datum/reagent/consumable/ethanol))) + if(H.reagents.has_reagent(typesof(/datum/reagent/consumable/ethanol).id)) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) return 0 return 1 From 32504f73f88d89a51cd50c9b6d9d9486cd97d544 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 14:37:17 -0400 Subject: [PATCH 037/120] hoPEFULLY FIXES IT, adds chem objective for chemists and CMOs --- code/citadel/cit_crewobjectives.dm | 68 ++++++++++++++++++++++++++++-- 1 file changed, 65 insertions(+), 3 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index c113889502..bee028c89f 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -219,6 +219,35 @@ return 0 return 1 +/datum/objective/crew/chiefmedicalofficer/chems //Ported from old Hippie with adjustments + var/targetchem = "none" + var/datum/reagent/chempath + explanation_text = "Ensure at least (yo something broke here) living crew members have (yell about this in the codebus discussion channel of citadel's discord) in their bloodstream when the shift ends." + +/datum/objective/crew/chiefmedicalofficer/chems/New() + . = ..() + target_amount = rand(2,5) + var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) + chempath = pick(typesof(/datum/reagent/drug) - blacklist, typesof(/datum/reagent/medicine) - blacklist, /datum/reagent/aphrodisiac, /datum/reagent/anaphrodisiac) + targetchem = chempath.id + update_explanation_text() + +/datum/objective/crew/chiefmedicalofficer/chems/update_explanation_text() + . = ..() + explanation_text = "Ensure at least [target_amount] living crew members have [chempath.name] in their bloodstream when the shift ends." + +/datum/objective/crew/chiefmedicalofficer/chems/check_completion() + var/gotchems = 0 + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(!H.stat == DEAD && H.reagents) + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if(H.reagents.has_reagent(targetchem) + gotchems += 1 + if(gotchems >= target_amount) + return 1 + else + return 0 + /datum/objective/crew/geneticist /datum/objective/crew/geneticist/morgue //Ported from old Hippie @@ -231,6 +260,37 @@ return 0 return 1 +/datum/objective/crew/chemist/ + +/datum/objective/crew/chemist/chems //Ported from old Hippie with adjustments + var/targetchem = "none" + var/datum/reagent/chempath + explanation_text = "Ensure at least (yo something broke here) living crew members have (yell about this in the codebus discussion channel of citadel's discord) in their bloodstream when the shift ends." + +/datum/objective/crew/chemist/chems/New() + . = ..() + target_amount = rand(2,5) + var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) + chempath = pick(typesof(/datum/reagent/drug) - blacklist, typesof(/datum/reagent/medicine) - blacklist, /datum/reagent/aphrodisiac, /datum/reagent/anaphrodisiac) + targetchem = chempath.id + update_explanation_text() + +/datum/objective/crew/chemist/chems/update_explanation_text() + . = ..() + explanation_text = "Ensure at least [target_amount] living crew members have [chempath.name] in their bloodstream when the shift ends." + +/datum/objective/crew/chemist/chems/check_completion() + var/gotchems = 0 + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(!H.stat == DEAD && H.reagents) + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if(H.reagents.has_reagent(targetchem) + gotchems += 1 + if(gotchems >= target_amount) + return 1 + else + return 0 + /datum/objective/crew/medicaldoctor /datum/objective/crew/medicaldoctor/morgue //Ported from old Hippie @@ -316,9 +376,11 @@ /datum/objective/crew/bartender/responsibility/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.reagents) - if(H.reagents.has_reagent(typesof(/datum/reagent/consumable/ethanol).id)) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - return 0 + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + for(/datum/reagent/consumable/ethanol/A in typesof(/datum/reagent/consumable/ethanol)) + if(A) + if(A.volume >= 5) + return 0 return 1 /datum/objective/crew/assistant From 6f47ac46d00d73aa5f305b64ff0be5b200e76483 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 14:51:37 -0400 Subject: [PATCH 038/120] hopefully fixes the compile errors --- code/citadel/cit_crewobjectives.dm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index bee028c89f..8c8a3b8e4b 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -237,13 +237,13 @@ explanation_text = "Ensure at least [target_amount] living crew members have [chempath.name] in their bloodstream when the shift ends." /datum/objective/crew/chiefmedicalofficer/chems/check_completion() - var/gotchems = 0 + var/gotchems = target_amount for(var/mob/living/carbon/human/H in GLOB.mob_list) if(!H.stat == DEAD && H.reagents) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(H.reagents.has_reagent(targetchem) - gotchems += 1 - if(gotchems >= target_amount) + gotchems-- + if(gotchems <= 0) return 1 else return 0 @@ -280,13 +280,13 @@ explanation_text = "Ensure at least [target_amount] living crew members have [chempath.name] in their bloodstream when the shift ends." /datum/objective/crew/chemist/chems/check_completion() - var/gotchems = 0 + var/gotchems = target_amount for(var/mob/living/carbon/human/H in GLOB.mob_list) if(!H.stat == DEAD && H.reagents) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(H.reagents.has_reagent(targetchem) - gotchems += 1 - if(gotchems >= target_amount) + gotchems-- + if(gotchems <= 0) return 1 else return 0 From fd8c9bc57d2e269c35465c1e67acc50d888f836e Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 15:00:22 -0400 Subject: [PATCH 039/120] where has my life gone --- code/citadel/cit_crewobjectives.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 8c8a3b8e4b..ca97f20f6d 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -241,7 +241,7 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(!H.stat == DEAD && H.reagents) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(H.reagents.has_reagent(targetchem) + if(H.reagents.has_reagent(targetchem)) gotchems-- if(gotchems <= 0) return 1 @@ -284,7 +284,7 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(!H.stat == DEAD && H.reagents) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(H.reagents.has_reagent(targetchem) + if(H.reagents.has_reagent(targetchem)) gotchems-- if(gotchems <= 0) return 1 From fe8f42bb5fca3039e44dea0ce813a7ee00d5a5f2 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 15:07:54 -0400 Subject: [PATCH 040/120] thERE WE GO --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index ca97f20f6d..7fc088a554 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -377,7 +377,7 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.reagents) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - for(/datum/reagent/consumable/ethanol/A in typesof(/datum/reagent/consumable/ethanol)) + for(var/datum/reagent/consumable/ethanol/A in typesof(/datum/reagent/consumable/ethanol)) if(A) if(A.volume >= 5) return 0 From d7e201bec845b0d4ad261ea13a4cd96d42bc3c3f Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 17:37:50 -0400 Subject: [PATCH 041/120] nerfs chem objective (makes it only give only one chem as the target as its supposed to) --- code/citadel/cit_crewobjectives.dm | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 7fc088a554..f6ea333413 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -228,7 +228,10 @@ . = ..() target_amount = rand(2,5) var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) - chempath = pick(typesof(/datum/reagent/drug) - blacklist, typesof(/datum/reagent/medicine) - blacklist, /datum/reagent/aphrodisiac, /datum/reagent/anaphrodisiac) + var/drugs = typesof(/datum/reagent/drug) - blacklist + var/meds = typesof(/datum/reagent/medicine) - blacklist + var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac + chempath = pick(chemlist) targetchem = chempath.id update_explanation_text() @@ -271,7 +274,10 @@ . = ..() target_amount = rand(2,5) var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) - chempath = pick(typesof(/datum/reagent/drug) - blacklist, typesof(/datum/reagent/medicine) - blacklist, /datum/reagent/aphrodisiac, /datum/reagent/anaphrodisiac) + var/drugs = typesof(/datum/reagent/drug) - blacklist + var/meds = typesof(/datum/reagent/medicine) - blacklist + var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac + chempath = pick(chemlist) targetchem = chempath.id update_explanation_text() From e6246d1f1a6f013546f4afe5f4ccf91fbbc1bcc6 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 17:47:02 -0400 Subject: [PATCH 042/120] fixes runtime --- code/citadel/cit_crewobjectives.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index f6ea333413..024ddaaa98 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -232,7 +232,7 @@ var/meds = typesof(/datum/reagent/medicine) - blacklist var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac chempath = pick(chemlist) - targetchem = chempath.id + targetchem = initial(chempath.id) update_explanation_text() /datum/objective/crew/chiefmedicalofficer/chems/update_explanation_text() @@ -278,7 +278,7 @@ var/meds = typesof(/datum/reagent/medicine) - blacklist var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac chempath = pick(chemlist) - targetchem = chempath.id + targetchem = initial(chempath.id) update_explanation_text() /datum/objective/crew/chemist/chems/update_explanation_text() From 60e9682ce25efad32ec4300b489fc421833b25cd Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 17:50:20 -0400 Subject: [PATCH 043/120] I'm blind --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 024ddaaa98..e2ddb0572b 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -383,7 +383,7 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.reagents) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - for(var/datum/reagent/consumable/ethanol/A in typesof(/datum/reagent/consumable/ethanol)) + for(var/datum/reagent/consumable/ethanol/A in H.reagents) if(A) if(A.volume >= 5) return 0 From 71ae5732601b56c8656105603c6d0b5ae95955bc Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 18:03:34 -0400 Subject: [PATCH 044/120] patches ANOTHER runtime. jesus im bad at this --- code/citadel/cit_crewobjectives.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index e2ddb0572b..82871c44f5 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -237,7 +237,7 @@ /datum/objective/crew/chiefmedicalofficer/chems/update_explanation_text() . = ..() - explanation_text = "Ensure at least [target_amount] living crew members have [chempath.name] in their bloodstream when the shift ends." + explanation_text = "Ensure at least [target_amount] living crew members have [initial(chempath.name)] in their bloodstream when the shift ends." /datum/objective/crew/chiefmedicalofficer/chems/check_completion() var/gotchems = target_amount @@ -283,7 +283,7 @@ /datum/objective/crew/chemist/chems/update_explanation_text() . = ..() - explanation_text = "Ensure at least [target_amount] living crew members have [chempath.name] in their bloodstream when the shift ends." + explanation_text = "Ensure at least [target_amount] living crew members have [initial(chempath.name)] in their bloodstream when the shift ends." /datum/objective/crew/chemist/chems/check_completion() var/gotchems = target_amount From a196eccb26b62965b0b47565d1cc7647f2733059 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 19:21:29 -0400 Subject: [PATCH 045/120] should fix responsibility objective. hopefully --- code/citadel/cit_crewobjectives.dm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 82871c44f5..8994d4e547 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -380,10 +380,11 @@ explanation_text = "Make sure nobody dies of alchohol poisoning." /datum/objective/crew/bartender/responsibility/check_completion() + var/boozetypes = typesof(/datum/reagent/consumable/ethanol) for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.reagents) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - for(var/datum/reagent/consumable/ethanol/A in H.reagents) + for(boozetypes/A in H.reagents) if(A) if(A.volume >= 5) return 0 From 830eef1207848653536fd53136b995b0e2f9d32d Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 20:00:26 -0400 Subject: [PATCH 046/120] ... theres a var for that --- code/citadel/cit_crewobjectives.dm | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 8994d4e547..f2702695b9 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -380,14 +380,10 @@ explanation_text = "Make sure nobody dies of alchohol poisoning." /datum/objective/crew/bartender/responsibility/check_completion() - var/boozetypes = typesof(/datum/reagent/consumable/ethanol) for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(H.stat == DEAD && H.reagents) + if(H.stat == DEAD && H.drunkenness >= 80) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - for(boozetypes/A in H.reagents) - if(A) - if(A.volume >= 5) - return 0 + return 0 return 1 /datum/objective/crew/assistant From dd0f5506cf29865b2a869791945834fa68f55f79 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 20:08:19 -0400 Subject: [PATCH 047/120] updates error text --- code/citadel/cit_crewobjectives.dm | 16 ++++++++-------- code/citadel/cit_miscreants.dm | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index f2702695b9..8e08c464af 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -29,7 +29,7 @@ crewMind.announce_objectives() /datum/objective/crew/ - explanation_text = "Yell on the coderbus discussion channel on Citadels discord if this ever shows up. Something just broke here, dude" + explanation_text = "Yell on the development discussion channel on Citadels discord if this ever shows up. Something just broke here, dude" /datum/objective/crew/proc/setup() @@ -158,7 +158,7 @@ /datum/objective/crew/researchdirector/ /datum/objective/crew/researchdirector/cyborgs //Ported from old Hippie - explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's codebus discussion channel about this) functioning cyborgs when the shift ends." + explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's development discussion channel about this) functioning cyborgs when the shift ends." /datum/objective/crew/researchdirector/cyborgs/New() . = ..() @@ -182,7 +182,7 @@ /datum/objective/crew/roboticist/ /datum/objective/crew/roboticist/cyborgs //Ported from old Hippie - explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's codebus discussion channel about this) functioning cyborgs when the shift ends." + explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's development discussion channel about this) functioning cyborgs when the shift ends." /datum/objective/crew/roboticist/cyborgs/New() . = ..() @@ -222,7 +222,7 @@ /datum/objective/crew/chiefmedicalofficer/chems //Ported from old Hippie with adjustments var/targetchem = "none" var/datum/reagent/chempath - explanation_text = "Ensure at least (yo something broke here) living crew members have (yell about this in the codebus discussion channel of citadel's discord) in their bloodstream when the shift ends." + explanation_text = "Ensure at least (yo something broke here) living crew members have (yell about this in the development discussion channel of citadel's discord) in their bloodstream when the shift ends." /datum/objective/crew/chiefmedicalofficer/chems/New() . = ..() @@ -268,7 +268,7 @@ /datum/objective/crew/chemist/chems //Ported from old Hippie with adjustments var/targetchem = "none" var/datum/reagent/chempath - explanation_text = "Ensure at least (yo something broke here) living crew members have (yell about this in the codebus discussion channel of citadel's discord) in their bloodstream when the shift ends." + explanation_text = "Ensure at least (yo something broke here) living crew members have (yell about this in the development discussion channel of citadel's discord) in their bloodstream when the shift ends." /datum/objective/crew/chemist/chems/New() . = ..() @@ -315,7 +315,7 @@ /datum/objective/crew/quartermaster /datum/objective/crew/quartermaster/petsplosion - explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the codebus discussion channel) pets on the station by the end of the shift. Interpret this as you wish." + explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." /datum/objective/crew/quartermaster/petsplosion/New() . = ..() @@ -345,7 +345,7 @@ /datum/objective/crew/cargotechnician /datum/objective/crew/cargotechnician/petsplosion - explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the codebus discussion channel) pets on the station by the end of the shift. Interpret this as you wish." + explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." /datum/objective/crew/assistant/petsplosion/New() . = ..() @@ -389,7 +389,7 @@ /datum/objective/crew/assistant /datum/objective/crew/assistant/petsplosion - explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the codebus discussion channel) pets on the station by the end of the shift. Interpret this as you wish." + explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." /datum/objective/crew/assistant/petsplosion/New() . = ..() diff --git a/code/citadel/cit_miscreants.dm b/code/citadel/cit_miscreants.dm index fbd89c1827..722cd53727 100644 --- a/code/citadel/cit_miscreants.dm +++ b/code/citadel/cit_miscreants.dm @@ -22,7 +22,7 @@ crewMind.announce_objectives() /datum/objective/miscreant - explanation_text = "Something broke. Horribly. Dear god, im so sorry. Yell about this in the coderbus discussion channel of citadels discord." + explanation_text = "Something broke. Horribly. Dear god, im so sorry. Yell about this in the development discussion channel of citadels discord." /* Goon's Miscreant Objectives */ From a5b335885f677d40affb82381def332edb55d2f9 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 21:41:11 -0400 Subject: [PATCH 048/120] janitor cleaning objective --- code/citadel/cit_crewobjectives.dm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 8e08c464af..636c618f64 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -386,6 +386,31 @@ return 0 return 1 +/datum/objective/crew/janitor + +/datum/objective/crew/janitor/clean //ported from old Hippie + var/list/areas = list() + explanation_text = "Ensure sure that (Yo, something broke. Yell about this in citadels devlopmeent discussion channel.) remain spotless at the end of the shift." + +/datum/objective/crew/janitor/clean/new() + . = ..() + var/list/possibleareas = GLOB.teleportlocs + for(var/i in 1 to rand(1,4)) + areas |= pick_n_take(possibleareas) + update_explanation_text() + +/datum/objective/crew/janitor/clean/update_explanation_text() + . = ..() + explanation_text = "Ensure that " + for(var/i in 1 to areas.len) + var/area/A = areas[i] + explanation_text += "[A.name]" + if(i != areas.len) + explanation_text += ", and " + explanation_text += " remain[(areas.len ==1) ? "s" : ""] spotless at the end of the shift." + +/datum/objective/crew/janitor/clean/check_completion() + /datum/objective/crew/assistant /datum/objective/crew/assistant/petsplosion From dda6e59817116491d6d852e13bb0ab0e399bad73 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 21:49:00 -0400 Subject: [PATCH 049/120] I haven't had a breath of fresh air for two days now --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 636c618f64..322b88a7eb 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -392,7 +392,7 @@ var/list/areas = list() explanation_text = "Ensure sure that (Yo, something broke. Yell about this in citadels devlopmeent discussion channel.) remain spotless at the end of the shift." -/datum/objective/crew/janitor/clean/new() +/datum/objective/crew/janitor/clean/New() . = ..() var/list/possibleareas = GLOB.teleportlocs for(var/i in 1 to rand(1,4)) From c1d1cc5cb187aa4de3356145891dca33d4768411 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 21:56:59 -0400 Subject: [PATCH 050/120] gramatically correct spaghetti code --- code/citadel/cit_crewobjectives.dm | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 322b88a7eb..4075e669ad 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -401,13 +401,15 @@ /datum/objective/crew/janitor/clean/update_explanation_text() . = ..() - explanation_text = "Ensure that " + explanation_text = "Ensure that the " for(var/i in 1 to areas.len) var/area/A = areas[i] explanation_text += "[A.name]" - if(i != areas.len) - explanation_text += ", and " - explanation_text += " remain[(areas.len ==1) ? "s" : ""] spotless at the end of the shift." + if(i != areas.len && areas.len >= 3) + explanation_text += ", " + if(i == areas.len - 1) + explanation_text += "and " + explanation_text += " [(areas.len ==1) ? "is completely" : "are [(areas.len == 2) ? "completely" : "all"]"] spotless at the end of the shift." /datum/objective/crew/janitor/clean/check_completion() From 855455a6cad93699d511f7f9a3b11e1ff4473517 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 5 Sep 2017 22:27:27 -0400 Subject: [PATCH 051/120] nerfs runtimes, buffs memory retention --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 4075e669ad..194e8682ae 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -404,7 +404,7 @@ explanation_text = "Ensure that the " for(var/i in 1 to areas.len) var/area/A = areas[i] - explanation_text += "[A.name]" + explanation_text += "[A]" if(i != areas.len && areas.len >= 3) explanation_text += ", " if(i == areas.len - 1) From 146d11dfad0b0d4d356d0f6e5a661263f54752c9 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 02:06:36 -0400 Subject: [PATCH 052/120] nerfs bad rng --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 194e8682ae..2cbb958f24 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -394,7 +394,7 @@ /datum/objective/crew/janitor/clean/New() . = ..() - var/list/possibleareas = GLOB.teleportlocs + var/list/possibleareas = GLOB.teleportlocs - /area/space for(var/i in 1 to rand(1,4)) areas |= pick_n_take(possibleareas) update_explanation_text() From c9a340de27f8e71648594d319f1c59633ae7963c Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 13:18:39 -0400 Subject: [PATCH 053/120] fixes janitor objective, tones down other objectives --- code/citadel/cit_crewobjectives.dm | 44 +++++++++++++----------------- 1 file changed, 19 insertions(+), 25 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 2cbb958f24..53868fa084 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -219,14 +219,13 @@ return 0 return 1 -/datum/objective/crew/chiefmedicalofficer/chems //Ported from old Hippie with adjustments +/datum/objective/crew/chiefmedicalofficer/chems //Ported from old Hippie var/targetchem = "none" var/datum/reagent/chempath - explanation_text = "Ensure at least (yo something broke here) living crew members have (yell about this in the development discussion channel of citadel's discord) in their bloodstream when the shift ends." + explanation_text = "Have (yell about this in the development discussion channel of citadel's discord, something broke) in your bloodstream when the shift ends." /datum/objective/crew/chiefmedicalofficer/chems/New() . = ..() - target_amount = rand(2,5) var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) var/drugs = typesof(/datum/reagent/drug) - blacklist var/meds = typesof(/datum/reagent/medicine) - blacklist @@ -237,17 +236,14 @@ /datum/objective/crew/chiefmedicalofficer/chems/update_explanation_text() . = ..() - explanation_text = "Ensure at least [target_amount] living crew members have [initial(chempath.name)] in their bloodstream when the shift ends." + explanation_text = "Have [initial(chempath.name)] in your bloodstream when the shift ends." /datum/objective/crew/chiefmedicalofficer/chems/check_completion() var/gotchems = target_amount - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(!H.stat == DEAD && H.reagents) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(H.reagents.has_reagent(targetchem)) - gotchems-- - if(gotchems <= 0) - return 1 + if(owner.current) + if(!owner.stat == DEAD && owner.reagents) + if(owner.reagents.has_reagent(targetchem)) + return 1 else return 0 @@ -265,14 +261,13 @@ /datum/objective/crew/chemist/ -/datum/objective/crew/chemist/chems //Ported from old Hippie with adjustments +/datum/objective/crew/chemist/chems //Ported from old Hippie var/targetchem = "none" var/datum/reagent/chempath - explanation_text = "Ensure at least (yo something broke here) living crew members have (yell about this in the development discussion channel of citadel's discord) in their bloodstream when the shift ends." + explanation_text = "Have (yell about this in the development discussion channel of citadel's discord, something broke) in your bloodstream when the shift ends." /datum/objective/crew/chemist/chems/New() . = ..() - target_amount = rand(2,5) var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) var/drugs = typesof(/datum/reagent/drug) - blacklist var/meds = typesof(/datum/reagent/medicine) - blacklist @@ -283,17 +278,14 @@ /datum/objective/crew/chemist/chems/update_explanation_text() . = ..() - explanation_text = "Ensure at least [target_amount] living crew members have [initial(chempath.name)] in their bloodstream when the shift ends." + explanation_text = "Have [initial(chempath.name)] in your bloodstream when the shift ends." /datum/objective/crew/chemist/chems/check_completion() var/gotchems = target_amount - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(!H.stat == DEAD && H.reagents) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(H.reagents.has_reagent(targetchem)) - gotchems-- - if(gotchems <= 0) - return 1 + if(owner.current) + if(!owner.stat == DEAD && owner.reagents) + if(owner.reagents.has_reagent(targetchem)) + return 1 else return 0 @@ -319,7 +311,6 @@ /datum/objective/crew/quartermaster/petsplosion/New() . = ..() - target_amount = rand(10,75) update_explanation_text() /datum/objective/crew/quartermaster/petsplosion/update_explanation_text() @@ -349,7 +340,6 @@ /datum/objective/crew/assistant/petsplosion/New() . = ..() - target_amount = rand(10,75) update_explanation_text() /datum/objective/crew/cargotechnician/petsplosion/update_explanation_text() @@ -412,6 +402,10 @@ explanation_text += " [(areas.len ==1) ? "is completely" : "are [(areas.len == 2) ? "completely" : "all"]"] spotless at the end of the shift." /datum/objective/crew/janitor/clean/check_completion() + for(var/area/A in areas) + for(var/obj/effect/decal/A in area_contents(A) + return 0 + return 1 /datum/objective/crew/assistant @@ -420,7 +414,7 @@ /datum/objective/crew/assistant/petsplosion/New() . = ..() - target_amount = rand(10,25) + target_amount = rand(10,20) update_explanation_text() /datum/objective/crew/assistant/petsplosion/update_explanation_text() From d996b7ab7560cf59c2aeaf69081bbcce6a5b7c69 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 13:35:56 -0400 Subject: [PATCH 054/120] adds "kill bubblegum" objective for shaft miners --- code/citadel/cit_crewobjectives.dm | 19 ++++++++++++++++--- code/citadel/cit_miscreants.dm | 6 ++++++ 2 files changed, 22 insertions(+), 3 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 53868fa084..3d2fcc10ba 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -162,7 +162,7 @@ /datum/objective/crew/researchdirector/cyborgs/New() . = ..() - target_amount = rand(3,20) + target_amount = rand(3,10) update_explanation_text() /datum/objective/crew/researchdirector/cyborgs/update_explanation_text() @@ -186,7 +186,7 @@ /datum/objective/crew/roboticist/cyborgs/New() . = ..() - target_amount = rand(3,20) + target_amount = rand(3,10) update_explanation_text() /datum/objective/crew/roboticist/cyborgs/update_explanation_text() @@ -311,6 +311,7 @@ /datum/objective/crew/quartermaster/petsplosion/New() . = ..() + target_amount = rand(10,30) update_explanation_text() /datum/objective/crew/quartermaster/petsplosion/update_explanation_text() @@ -338,8 +339,9 @@ /datum/objective/crew/cargotechnician/petsplosion explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." -/datum/objective/crew/assistant/petsplosion/New() +/datum/objective/crew/cargotechnician/petsplosion/New() . = ..() + target_amount = rand(10,30) update_explanation_text() /datum/objective/crew/cargotechnician/petsplosion/update_explanation_text() @@ -362,6 +364,17 @@ else return 0 +/datum/objective/crew/shaftminer + +/datum/objective/crew/shaftminer/bubblegum + explanation_text = "Ensure Bubblegum is dead at the end of the shift." + +/datum/objective/crew/shaftminer/bubblegum/check_completion() + for(var/mob/living/simple_animal/hostile/megafuana/bubblegum/B in GLOB.mob_list) + if(!B.stat == DEAD) + return 0 + return 1 + /* CIVILLIAN OBJECTIVES */ /datum/objective/crew/bartender diff --git a/code/citadel/cit_miscreants.dm b/code/citadel/cit_miscreants.dm index 722cd53727..19e75047f5 100644 --- a/code/citadel/cit_miscreants.dm +++ b/code/citadel/cit_miscreants.dm @@ -53,7 +53,13 @@ /datum/objective/miscreant/whiny explanation_text = "Complain incessantly about every minor issue you find." +/datum/objective/miscreant/damage + explanation_text = "Cause as much property damage as possible without actually harming anyone." + /* Citadel's Miscreant Objectives */ /datum/objective/miscreant/immersions explanation_text = "Act as out of character as you possibly can." + +/datum/objective/miscreant/racism + explanation_text = "Attempt to establish superiority of your race." From 94354c3dd67bc5361e0e4fb203bc32c4a296847b Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 14:14:18 -0400 Subject: [PATCH 055/120] more janitor adjustments --- code/citadel/cit_crewobjectives.dm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 3d2fcc10ba..2ac404375f 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -397,8 +397,8 @@ /datum/objective/crew/janitor/clean/New() . = ..() - var/list/possibleareas = GLOB.teleportlocs - /area/space - for(var/i in 1 to rand(1,4)) + var/list/possibleareas = GLOB.teleportlocs - /area - typesof(/area/space) - typesof(/area/lavaland) - typesof(/area/mine) - typesof(/area/ai_monitored/turret_protected) - typesof(/area/tcommsat) + for(var/i in 1 to rand(1,6)) areas |= pick_n_take(possibleareas) update_explanation_text() @@ -412,7 +412,7 @@ explanation_text += ", " if(i == areas.len - 1) explanation_text += "and " - explanation_text += " [(areas.len ==1) ? "is completely" : "are [(areas.len == 2) ? "completely" : "all"]"] spotless at the end of the shift." + explanation_text += " [(areas.len ==1) ? "is completely" : "are [(areas.len == 2) ? "completely" : "all"]"] clean at the end of the shift." /datum/objective/crew/janitor/clean/check_completion() for(var/area/A in areas) From 02cc0b2db1906f31eb01a37f9e3a10356413e1a5 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 14:19:25 -0400 Subject: [PATCH 056/120] should fix compiling errors --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 2ac404375f..06a8071a0f 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -416,7 +416,7 @@ /datum/objective/crew/janitor/clean/check_completion() for(var/area/A in areas) - for(var/obj/effect/decal/A in area_contents(A) + for(var/obj/effect/decal/cleanable/A in area_contents(A)) return 0 return 1 From 367c6c8adaac2b51baaab53be1cbf15b43076887 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 14:37:01 -0400 Subject: [PATCH 057/120] im bad at this coding thing --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 06a8071a0f..61b772494e 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -370,7 +370,7 @@ explanation_text = "Ensure Bubblegum is dead at the end of the shift." /datum/objective/crew/shaftminer/bubblegum/check_completion() - for(var/mob/living/simple_animal/hostile/megafuana/bubblegum/B in GLOB.mob_list) + for(var/mob/living/simple_animal/hostile/megafauna/bubblegum/B in GLOB.mob_list) if(!B.stat == DEAD) return 0 return 1 From be5013c2a03054a4134a7c198db05efbef7f18d4 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 14:37:59 -0400 Subject: [PATCH 058/120] aaaAAAUUGH --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 61b772494e..55eb6da781 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -416,7 +416,7 @@ /datum/objective/crew/janitor/clean/check_completion() for(var/area/A in areas) - for(var/obj/effect/decal/cleanable/A in area_contents(A)) + for(var/obj/effect/decal/cleanable/C in area_contents(A)) return 0 return 1 From 1753a4509a32237efa84585925123e5b6ec27311 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 14:51:28 -0400 Subject: [PATCH 059/120] there we go. compiling errors fixed. --- code/citadel/cit_crewobjectives.dm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 55eb6da781..93041f4707 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -241,8 +241,8 @@ /datum/objective/crew/chiefmedicalofficer/chems/check_completion() var/gotchems = target_amount if(owner.current) - if(!owner.stat == DEAD && owner.reagents) - if(owner.reagents.has_reagent(targetchem)) + if(!owner.current.stat == DEAD && owner.current.reagents) + if(owner.current.reagents.has_reagent(targetchem)) return 1 else return 0 @@ -283,8 +283,8 @@ /datum/objective/crew/chemist/chems/check_completion() var/gotchems = target_amount if(owner.current) - if(!owner.stat == DEAD && owner.reagents) - if(owner.reagents.has_reagent(targetchem)) + if(!owner.current.stat == DEAD && owner.current.reagents) + if(owner.current.reagents.has_reagent(targetchem)) return 1 else return 0 From 4bcb9f16290886b5709ea12989d1913cc201e29a Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 16:34:38 -0400 Subject: [PATCH 060/120] druglord objective + fixes --- code/citadel/cit_crewobjectives.dm | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 93041f4707..8412cb1831 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -239,7 +239,6 @@ explanation_text = "Have [initial(chempath.name)] in your bloodstream when the shift ends." /datum/objective/crew/chiefmedicalofficer/chems/check_completion() - var/gotchems = target_amount if(owner.current) if(!owner.current.stat == DEAD && owner.current.reagents) if(owner.current.reagents.has_reagent(targetchem)) @@ -281,7 +280,6 @@ explanation_text = "Have [initial(chempath.name)] in your bloodstream when the shift ends." /datum/objective/crew/chemist/chems/check_completion() - var/gotchems = target_amount if(owner.current) if(!owner.current.stat == DEAD && owner.current.reagents) if(owner.current.reagents.has_reagent(targetchem)) @@ -289,6 +287,30 @@ else return 0 +/datum/objective/crew/chemist/druglord //ported from hippie, + var/targetchem = "none" + var/datum/reagent/chempath + explanation_text = "Have at least (somethin broke here) pills containing (report this on the development discussion channel of citadel's discord) when the shift ends." + +/datum/objective/crew/chemist/druglord/New() + . = ..() + target_amount = rand(5,50) + var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol) + var/drugs = typesof(/datum/reagent/drug) - blacklist + var/chemlist = drugs + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac + chempath = pick(chemlist) + targetchem = initial(chempath.id) + update_explanation_text() + +/datum/objective/crew/chemist/druglord/update_explanation_text() + . = ..() + explanation_text = "Have at least [target_amount] pills containing [initial(chempath.name)] when the shift ends." + +/datum/objective/crew/chemist/druglord/check_completion() + if(owner.current) + if(owner.current.contents) + + /datum/objective/crew/medicaldoctor /datum/objective/crew/medicaldoctor/morgue //Ported from old Hippie From 49152d4bdb69c53a9370daac2b03c3869540cc64 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 16:46:28 -0400 Subject: [PATCH 061/120] Bluh --- code/citadel/cit_crewobjectives.dm | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 8412cb1831..b00b63f103 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -287,7 +287,7 @@ else return 0 -/datum/objective/crew/chemist/druglord //ported from hippie, +/datum/objective/crew/chemist/druglord //ported from old Hippie with adjustments var/targetchem = "none" var/datum/reagent/chempath explanation_text = "Have at least (somethin broke here) pills containing (report this on the development discussion channel of citadel's discord) when the shift ends." @@ -307,9 +307,16 @@ explanation_text = "Have at least [target_amount] pills containing [initial(chempath.name)] when the shift ends." /datum/objective/crew/chemist/druglord/check_completion() + var/pillcount = target_amount if(owner.current) if(owner.current.contents) - + for(var/item/reagent_containers/pill/P in owner.current.get_contents()) + if(P.reagents.has_reagent(targetchem)) + pillcount-- + if(pillcount <= 0) + return 1 + else + return 0 /datum/objective/crew/medicaldoctor From 44729f3944501cd280724fd0ef5553c32588119e Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 16:55:31 -0400 Subject: [PATCH 062/120] ya shittin me right now? --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index b00b63f103..7be5c71960 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -310,7 +310,7 @@ var/pillcount = target_amount if(owner.current) if(owner.current.contents) - for(var/item/reagent_containers/pill/P in owner.current.get_contents()) + for(var/obj/item/reagent_containers/pill/P in owner.current.get_contents()) if(P.reagents.has_reagent(targetchem)) pillcount-- if(pillcount <= 0) From 98e30a70a7a777c967ef83eef00761a3c2cc4f2a Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 17:12:12 -0400 Subject: [PATCH 063/120] adds druglorg objective to botanist --- code/citadel/cit_crewobjectives.dm | 40 +++++++++++++++++++++++++++--- 1 file changed, 37 insertions(+), 3 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 7be5c71960..8740b845ff 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -226,7 +226,7 @@ /datum/objective/crew/chiefmedicalofficer/chems/New() . = ..() - var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) + var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) var/drugs = typesof(/datum/reagent/drug) - blacklist var/meds = typesof(/datum/reagent/medicine) - blacklist var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac @@ -267,7 +267,7 @@ /datum/objective/crew/chemist/chems/New() . = ..() - var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) + var/blacklist = list(/datum/reagent/drug, /datum/reagetn/drug/nicotine, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) var/drugs = typesof(/datum/reagent/drug) - blacklist var/meds = typesof(/datum/reagent/medicine) - blacklist var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac @@ -295,7 +295,7 @@ /datum/objective/crew/chemist/druglord/New() . = ..() target_amount = rand(5,50) - var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol) + var/blacklist = list(/datum/reagent/drug, /datum/reagent/nicotine, /datum/reagent/drug/menthol) var/drugs = typesof(/datum/reagent/drug) - blacklist var/chemlist = drugs + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac chempath = pick(chemlist) @@ -406,6 +406,40 @@ /* CIVILLIAN OBJECTIVES */ +/datum/objective/crew/botanist + +/datum/objective/crew/botanist/druglord //ported from old Hippie with adjustments + var/targetchem = "none" + var/datum/reagent/chempath + explanation_text = "Have at least (somethin broke here) harvested plants containing (report this on the development discussion channel of citadel's discord) when the shift ends." + +/datum/objective/crew/botanist/druglord/New() + . = ..() + target_amount = rand(3,20) + var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) + var/drugs = typesof(/datum/reagent/drug) - blacklist + var/meds = typesof(/datum/reagent/medicine) - blacklist + var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac + chempath = pick(chemlist) + targetchem = initial(chempath.id) + update_explanation_text() + +/datum/objective/crew/botanist/druglord/update_explanation_text() + . = ..() + explanation_text = "Have at least [target_amount] harvested plants containing [initial(chempath.name)] when the shift ends." + +/datum/objective/crew/botanist/druglord/check_completion() + var/pillcount = target_amount + if(owner.current) + if(owner.current.contents) + for(var/obj/item/reagent_containers/food/snacks/grown/P in owner.current.get_contents()) + if(P.reagents.has_reagent(targetchem)) + pillcount-- + if(pillcount <= 0) + return 1 + else + return 0 + /datum/objective/crew/bartender /datum/objective/crew/bartender/responsibility From f52fa8e2e9cee510c48f7c9b85b77fc66c76505d Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 17:18:45 -0400 Subject: [PATCH 064/120] it's probably a better idea to do this while sober --- code/citadel/cit_crewobjectives.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 8740b845ff..58fc652a8f 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -267,7 +267,7 @@ /datum/objective/crew/chemist/chems/New() . = ..() - var/blacklist = list(/datum/reagent/drug, /datum/reagetn/drug/nicotine, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) + var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) var/drugs = typesof(/datum/reagent/drug) - blacklist var/meds = typesof(/datum/reagent/medicine) - blacklist var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac @@ -295,7 +295,7 @@ /datum/objective/crew/chemist/druglord/New() . = ..() target_amount = rand(5,50) - var/blacklist = list(/datum/reagent/drug, /datum/reagent/nicotine, /datum/reagent/drug/menthol) + var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol) var/drugs = typesof(/datum/reagent/drug) - blacklist var/chemlist = drugs + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac chempath = pick(chemlist) From 0b04dd521136b4b1089f4bcdf133b84a3d58f3e2 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 17:50:41 -0400 Subject: [PATCH 065/120] no harmful viruses objective for virologists --- code/citadel/cit_crewobjectives.dm | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 58fc652a8f..6181947653 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -318,6 +318,19 @@ else return 0 +/datum/objective/crew/virologist + +/datum/objective/crew/virologist/noinfections + explanation_text = "Ensure no living crew members are infected with harmful viruses at the end of the shift" + +/datum/objective/crew/virologist/noinfections/check_completion() + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(!H.stat == DEAD) + if(H.z = ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if(H.check_virus() == 2) + return 0 + return 1 + /datum/objective/crew/medicaldoctor /datum/objective/crew/medicaldoctor/morgue //Ported from old Hippie From 8ef2b39d4410bfcf9a8a4722738aa6b5bd5c39ce Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 18:34:05 -0400 Subject: [PATCH 066/120] adds clown slip objective --- code/citadel/cit_crewobjectives.dm | 27 ++++++++++++++++++- .../objects/items/devices/PDA/PDA_types.dm | 2 ++ 2 files changed, 28 insertions(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 6181947653..1055d9f6ad 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -326,7 +326,7 @@ /datum/objective/crew/virologist/noinfections/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) if(!H.stat == DEAD) - if(H.z = ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(H.check_virus() == 2) return 0 return 1 @@ -496,6 +496,31 @@ return 0 return 1 +/datum/objective/crew/clown + +/datum/objective/crew/clown/slipster //ported from old Hippie with adjustments + explanation_text = "Slip at least (Yell on citadel's development discussion channel if you see this) different people with your PDA, and have it on you at the end of the shift." + +/datum/objective/crew/clown/slipster/New() + . = ..() + target_amount = rand(5, 20) + update_explanation_text() + +/datum/objective/crew/clown/slipster/update_explanation_text() + . = ..() + explanation_text = "Slip at least [target_amount] different people with your PDA, and have it on you at the end of the shift." + +/datum/objective/crew/clown/slipster/check_completion() + var/uniqueslips = list() + if(owner.current) + for(/obj/item/device/pda/clown/PDA in get_contents(owner.current)) //100% open for badmin abuse + for(var/mob/living/carbon/human/H in PDA.slipvictims) + uniqueslips |= H + if(uniqueslips.len >= target_amount) + return 1 + else + return 0 + /datum/objective/crew/assistant /datum/objective/crew/assistant/petsplosion diff --git a/code/game/objects/items/devices/PDA/PDA_types.dm b/code/game/objects/items/devices/PDA/PDA_types.dm index 08e417b9d5..4f2db14fa6 100644 --- a/code/game/objects/items/devices/PDA/PDA_types.dm +++ b/code/game/objects/items/devices/PDA/PDA_types.dm @@ -6,6 +6,7 @@ icon_state = "pda-clown" desc = "A portable microcomputer by Thinktronic Systems, LTD. The surface is coated with polytetrafluoroethylene and banana drippings." ttone = "honk" + var/slipvictims = list() /obj/item/device/pda/clown/Initialize() . = ..() @@ -18,6 +19,7 @@ return var/mob/living/carbon/human/M = S.slip_victim if (istype(M) && (M.real_name != src.owner)) + slipvictims |= M var/obj/item/cartridge/virus/clown/cart = cartridge if(istype(cart) && cart.charges < 5) cart.charges++ From 5e25464e1a359710ba4296dcbb25a29aad134951 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 18:56:59 -0400 Subject: [PATCH 067/120] sweet jesus im absolutely horrid at this --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 1055d9f6ad..ac3d51c61f 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -513,7 +513,7 @@ /datum/objective/crew/clown/slipster/check_completion() var/uniqueslips = list() if(owner.current) - for(/obj/item/device/pda/clown/PDA in get_contents(owner.current)) //100% open for badmin abuse + for(var/obj/item/device/pda/clown/PDA in owner.current.get_contents()) //100% open for badmin abuse for(var/mob/living/carbon/human/H in PDA.slipvictims) uniqueslips |= H if(uniqueslips.len >= target_amount) From 879eb6e448b13f6c9d705389beaeae8374689382 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 20:04:19 -0400 Subject: [PATCH 068/120] more objectives, hopefully fixes compiling errors --- code/citadel/cit_crewobjectives.dm | 35 +++++++++++++++++++++++++++++- 1 file changed, 34 insertions(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index ac3d51c61f..31cd2279c9 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -511,7 +511,7 @@ explanation_text = "Slip at least [target_amount] different people with your PDA, and have it on you at the end of the shift." /datum/objective/crew/clown/slipster/check_completion() - var/uniqueslips = list() + var/list/uniqueslips = list() if(owner.current) for(var/obj/item/device/pda/clown/PDA in owner.current.get_contents()) //100% open for badmin abuse for(var/mob/living/carbon/human/H in PDA.slipvictims) @@ -521,8 +521,41 @@ else return 0 +/datum/objective/crew/mime + +/datum/objective/crew/mime/vow //ported from old Hippie + explanation_text = "Never break your vow of silence." + +/datum/objective/crew/mime/vow/check_completion() + var/list/say_log = owner.logging[INDIVIDUAL_SAY_LOG] + if(owner.current) + if(say_log.len > 0) + return 0 + return 1 + /datum/objective/crew/assistant +/datum/objective/crew/assistant/departmentclothes + var/obj/item/clothing/under/rank/targetuniform + explanation_text = "Be wearing a (Yo, this objective broke. report this to citadels discord via the development channel) at the end of the shift." + +/datum/objective/crew/assistant/departmentclothes/New() + . = ..() + var/list/blacklist = list(/obj/item/clothing/under/rank, /obj/item/clothing/under/rank/miner, /obj/item/clothing/under/rank/medical/blue, /obj/item/clothing/under/rank/medical/green, /obj/item/clothing/under/rank/medical/purple, /obj/item/clothing/under/rank/security/grey, /obj/item/clothing/under/rank/warden/grey, /obj/item/clothing/under/rank/head_of_security/grey /obj/item/clothing/under/rank/mailman, /obj/item/clothing/under/rank/psyche, /obj/item/clothing/under/rank/clown/sexy, /obj/item/clothing/under/rank/centcom_officer, /obj/item/clothing/under/rank/centcom_commander, /obj/item/clothing/under/rank/security/navyblue/russian, /obj/item/clothing/under/rank/security/blueshirt) + var/list/validclothes = typesof(/obj/item/clothing/under/rank) - blacklist + targetuniform = pick(validclothes) + update_explanation_text() + +/datum/objective/crew/assistant/departmentclothes/update_explanation_text() + . = ..() + explanation_text = "Be wearing a [targetuniform] at the end of the shift. + +/datum/objective/crew/assistant/departmentclothes/check_completion() + if(owner.current) + if(istype(H.w_uniform, targetuniform) + return 1 + return 0 + /datum/objective/crew/assistant/petsplosion explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." From 19628a2d9f2b3ce6c7107f8dca113d1be4eafdc0 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 20:23:19 -0400 Subject: [PATCH 069/120] hnnnnnnnnngh --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 31cd2279c9..4c54fbad78 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -552,7 +552,7 @@ /datum/objective/crew/assistant/departmentclothes/check_completion() if(owner.current) - if(istype(H.w_uniform, targetuniform) + if(istype(H.w_uniform, targetuniform)) return 1 return 0 From fe4839db72abfbb443677204db246a9ceef46554 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 20:30:12 -0400 Subject: [PATCH 070/120] compile dammit --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 4c54fbad78..394bd554ea 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -527,8 +527,8 @@ explanation_text = "Never break your vow of silence." /datum/objective/crew/mime/vow/check_completion() - var/list/say_log = owner.logging[INDIVIDUAL_SAY_LOG] if(owner.current) + var/list/say_log = owner.current.logging[INDIVIDUAL_SAY_LOG] if(say_log.len > 0) return 0 return 1 From 16669efe4a205a99af56899073b136867fc25cf6 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 20:39:49 -0400 Subject: [PATCH 071/120] thERE WE GO --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 394bd554ea..c2924f1c1c 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -548,7 +548,7 @@ /datum/objective/crew/assistant/departmentclothes/update_explanation_text() . = ..() - explanation_text = "Be wearing a [targetuniform] at the end of the shift. + explanation_text = "Be wearing a [targetuniform] at the end of the shift." /datum/objective/crew/assistant/departmentclothes/check_completion() if(owner.current) From fb0fd1ca107818de90b082400c03bbb36e4e439b Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 20:52:28 -0400 Subject: [PATCH 072/120] adds comma --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index c2924f1c1c..a57f8665c3 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -541,7 +541,7 @@ /datum/objective/crew/assistant/departmentclothes/New() . = ..() - var/list/blacklist = list(/obj/item/clothing/under/rank, /obj/item/clothing/under/rank/miner, /obj/item/clothing/under/rank/medical/blue, /obj/item/clothing/under/rank/medical/green, /obj/item/clothing/under/rank/medical/purple, /obj/item/clothing/under/rank/security/grey, /obj/item/clothing/under/rank/warden/grey, /obj/item/clothing/under/rank/head_of_security/grey /obj/item/clothing/under/rank/mailman, /obj/item/clothing/under/rank/psyche, /obj/item/clothing/under/rank/clown/sexy, /obj/item/clothing/under/rank/centcom_officer, /obj/item/clothing/under/rank/centcom_commander, /obj/item/clothing/under/rank/security/navyblue/russian, /obj/item/clothing/under/rank/security/blueshirt) + var/list/blacklist = list(/obj/item/clothing/under/rank, /obj/item/clothing/under/rank/miner, /obj/item/clothing/under/rank/medical/blue, /obj/item/clothing/under/rank/medical/green, /obj/item/clothing/under/rank/medical/purple, /obj/item/clothing/under/rank/security/grey, /obj/item/clothing/under/rank/warden/grey, /obj/item/clothing/under/rank/head_of_security/grey, /obj/item/clothing/under/rank/mailman, /obj/item/clothing/under/rank/psyche, /obj/item/clothing/under/rank/clown/sexy, /obj/item/clothing/under/rank/centcom_officer, /obj/item/clothing/under/rank/centcom_commander, /obj/item/clothing/under/rank/security/navyblue/russian, /obj/item/clothing/under/rank/security/blueshirt) var/list/validclothes = typesof(/obj/item/clothing/under/rank) - blacklist targetuniform = pick(validclothes) update_explanation_text() From 15ab156b86c2b2377a8bde90c1ad7ee4c506733e Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 21:04:45 -0400 Subject: [PATCH 073/120] moves crew objectives into separate files --- code/citadel/cit_crewobjectives.dm | 551 ------------------ .../cit_crewobjectives_cargo.dm | 72 +++ .../cit_crewobjectives_civilian.dm | 166 ++++++ .../cit_crewobjectives_command.dm | 43 ++ .../cit_crewobjectives_medical.dm | 137 +++++ .../cit_crewobjectives_science.dm | 49 ++ .../cit_crewobjectives_security.dm | 75 +++ tgstation.dme | 6 + 8 files changed, 548 insertions(+), 551 deletions(-) create mode 100644 code/citadel/crew_objectives/cit_crewobjectives_cargo.dm create mode 100644 code/citadel/crew_objectives/cit_crewobjectives_civilian.dm create mode 100644 code/citadel/crew_objectives/cit_crewobjectives_command.dm create mode 100644 code/citadel/crew_objectives/cit_crewobjectives_medical.dm create mode 100644 code/citadel/crew_objectives/cit_crewobjectives_science.dm create mode 100644 code/citadel/crew_objectives/cit_crewobjectives_security.dm diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index a57f8665c3..83422bd054 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -32,554 +32,3 @@ explanation_text = "Yell on the development discussion channel on Citadels discord if this ever shows up. Something just broke here, dude" /datum/objective/crew/proc/setup() - -/* COMMAND OBJECTIVES */ - -/datum/objective/crew/captain/ - -/datum/objective/crew/captain/hat //Ported from Goon - explanation_text = "Don't lose your hat." - -/datum/objective/crew/captain/hat/check_completion() - if(owner.current && owner.current.check_contents_for(/obj/item/clothing/head/caphat)) - return 1 - else - return 0 - -/datum/objective/crew/captain/datfukkendisk //Ported from old Hippie - explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." - -/datum/objective/crew/captain/datfukkendisk/check_completion() - if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) - return 1 - else - return 0 - -/datum/objective/crew/headofpersonnel/ - -/datum/objective/crew/headofpersonnel/ian //Ported from old Hippie - explanation_text = "Defend Ian at all costs, and ensure he gets delivered to Centcom at the end of the shift." - -/datum/objective/crew/headofpersonnel/ian/check_completion() - if(owner.current) - for(var/mob/living/simple_animal/pet/dog/corgi/Ian/goodboy in GLOB.mob_list) - if(goodboy.stat != DEAD && SSshuttle.emergency.shuttle_areas[get_area(goodboy)]) - return 1 - return 0 - return 0 - -/datum/objective/crew/headofpersonnel/datfukkendisk //Ported from old Hippie - explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." - -/datum/objective/crew/headofpersonnel/datfukkendisk/check_completion() - if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) - return 1 - else - return 0 - -/* SECURITY OBJECTIVES */ - -/datum/objective/crew/headofsecurity/ - -/datum/objective/crew/headofsecurity/justicecrew - explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." - -/datum/objective/crew/headofsecurity/justicecrew/check_completion() - if(owner.current) - for(var/datum/mind/M in SSticker.minds) - if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) - return 0 - return 1 - -/datum/objective/crew/headofsecurity/datfukkendisk //Ported from old Hippie - explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." - -/datum/objective/crew/headofsecurity/datfukkendisk/check_completion() - if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) - return 1 - else - return 0 - -/datum/objective/crew/securityofficer/ - -/datum/objective/crew/securityofficer/justicecrew - explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." - -/datum/objective/crew/securityofficer/justicecrew/check_completion() - if(owner.current) - for(var/datum/mind/M in SSticker.minds) - if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) - return 0 - return 1 - -/datum/objective/crew/warden/ - -/datum/objective/crew/warden/justicecrew - explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." - -/datum/objective/crew/warden/justicecrew/check_completion() - if(owner.current) - for(var/datum/mind/M in SSticker.minds) - if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) - return 0 - return 1 - -/datum/objective/crew/detective/ - -/datum/objective/crew/detective/justicecrew - explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." - -/datum/objective/crew/detective/justicecrew/check_completion() - if(owner.current) - for(var/datum/mind/M in SSticker.minds) - if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) - return 0 - return 1 - -/datum/objective/crew/lawyer/ - -/datum/objective/crew/lawyer/justicecrew - explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." - -/datum/objective/crew/lawyer/justicecrew/check_completion() - if(owner.current) - for(var/datum/mind/M in SSticker.minds) - if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) - return 0 - return 1 - -/* SCIENCE OBJECTIVES */ - -/datum/objective/crew/researchdirector/ - -/datum/objective/crew/researchdirector/cyborgs //Ported from old Hippie - explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's development discussion channel about this) functioning cyborgs when the shift ends." - -/datum/objective/crew/researchdirector/cyborgs/New() - . = ..() - target_amount = rand(3,10) - update_explanation_text() - -/datum/objective/crew/researchdirector/cyborgs/update_explanation_text() - . = ..() - explanation_text = "Ensure there are at least [target_amount] functioning cyborgs when the shift ends." - -/datum/objective/crew/researchdirector/cyborgs/check_completion() - var/borgcount = target_amount - for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) - if(!R.stat == DEAD) - borgcount-- - if(borgcount <= 0) - return 1 - else - return 0 - -/datum/objective/crew/roboticist/ - -/datum/objective/crew/roboticist/cyborgs //Ported from old Hippie - explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's development discussion channel about this) functioning cyborgs when the shift ends." - -/datum/objective/crew/roboticist/cyborgs/New() - . = ..() - target_amount = rand(3,10) - update_explanation_text() - -/datum/objective/crew/roboticist/cyborgs/update_explanation_text() - . = ..() - explanation_text = "Ensure there are at least [target_amount] functioning cyborgs when the shift ends." - -/datum/objective/crew/roboticist/cyborgs/check_completion() - var/borgcount = target_amount - for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) - if(!R.stat == DEAD) - borgcount-- - if(borgcount <= 0) - return 1 - else - return 0 - -/* ENGINEERING OBJECTIVES */ - -/* MEDICAL OBJECTIVES */ - -/datum/objective/crew/chiefmedicalofficer/ - -/datum/objective/crew/chiefmedicalofficer/morgue //Ported from old Hippie - explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." - -/datum/objective/crew/chiefmedicalofficer/morgue/check_completion() - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(H.stat == DEAD && H.z == ZLEVEL_STATION) - if(get_area(H) != /area/medical/morgue) - return 0 - return 1 - -/datum/objective/crew/chiefmedicalofficer/chems //Ported from old Hippie - var/targetchem = "none" - var/datum/reagent/chempath - explanation_text = "Have (yell about this in the development discussion channel of citadel's discord, something broke) in your bloodstream when the shift ends." - -/datum/objective/crew/chiefmedicalofficer/chems/New() - . = ..() - var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) - var/drugs = typesof(/datum/reagent/drug) - blacklist - var/meds = typesof(/datum/reagent/medicine) - blacklist - var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac - chempath = pick(chemlist) - targetchem = initial(chempath.id) - update_explanation_text() - -/datum/objective/crew/chiefmedicalofficer/chems/update_explanation_text() - . = ..() - explanation_text = "Have [initial(chempath.name)] in your bloodstream when the shift ends." - -/datum/objective/crew/chiefmedicalofficer/chems/check_completion() - if(owner.current) - if(!owner.current.stat == DEAD && owner.current.reagents) - if(owner.current.reagents.has_reagent(targetchem)) - return 1 - else - return 0 - -/datum/objective/crew/geneticist - -/datum/objective/crew/geneticist/morgue //Ported from old Hippie - explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." - -/datum/objective/crew/geneticist/morgue/check_completion() - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(H.stat == DEAD && H.z == ZLEVEL_STATION) - if(get_area(H) != /area/medical/morgue) - return 0 - return 1 - -/datum/objective/crew/chemist/ - -/datum/objective/crew/chemist/chems //Ported from old Hippie - var/targetchem = "none" - var/datum/reagent/chempath - explanation_text = "Have (yell about this in the development discussion channel of citadel's discord, something broke) in your bloodstream when the shift ends." - -/datum/objective/crew/chemist/chems/New() - . = ..() - var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) - var/drugs = typesof(/datum/reagent/drug) - blacklist - var/meds = typesof(/datum/reagent/medicine) - blacklist - var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac - chempath = pick(chemlist) - targetchem = initial(chempath.id) - update_explanation_text() - -/datum/objective/crew/chemist/chems/update_explanation_text() - . = ..() - explanation_text = "Have [initial(chempath.name)] in your bloodstream when the shift ends." - -/datum/objective/crew/chemist/chems/check_completion() - if(owner.current) - if(!owner.current.stat == DEAD && owner.current.reagents) - if(owner.current.reagents.has_reagent(targetchem)) - return 1 - else - return 0 - -/datum/objective/crew/chemist/druglord //ported from old Hippie with adjustments - var/targetchem = "none" - var/datum/reagent/chempath - explanation_text = "Have at least (somethin broke here) pills containing (report this on the development discussion channel of citadel's discord) when the shift ends." - -/datum/objective/crew/chemist/druglord/New() - . = ..() - target_amount = rand(5,50) - var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol) - var/drugs = typesof(/datum/reagent/drug) - blacklist - var/chemlist = drugs + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac - chempath = pick(chemlist) - targetchem = initial(chempath.id) - update_explanation_text() - -/datum/objective/crew/chemist/druglord/update_explanation_text() - . = ..() - explanation_text = "Have at least [target_amount] pills containing [initial(chempath.name)] when the shift ends." - -/datum/objective/crew/chemist/druglord/check_completion() - var/pillcount = target_amount - if(owner.current) - if(owner.current.contents) - for(var/obj/item/reagent_containers/pill/P in owner.current.get_contents()) - if(P.reagents.has_reagent(targetchem)) - pillcount-- - if(pillcount <= 0) - return 1 - else - return 0 - -/datum/objective/crew/virologist - -/datum/objective/crew/virologist/noinfections - explanation_text = "Ensure no living crew members are infected with harmful viruses at the end of the shift" - -/datum/objective/crew/virologist/noinfections/check_completion() - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(!H.stat == DEAD) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(H.check_virus() == 2) - return 0 - return 1 - -/datum/objective/crew/medicaldoctor - -/datum/objective/crew/medicaldoctor/morgue //Ported from old Hippie - explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." - -/datum/objective/crew/medicaldoctor/morgue/check_completion() - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(H.stat == DEAD && H.z == ZLEVEL_STATION) - if(get_area(H) != /area/medical/morgue) - return 0 - return 1 - - -/* CARGO OBJECTIVES */ - -/datum/objective/crew/quartermaster - -/datum/objective/crew/quartermaster/petsplosion - explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." - -/datum/objective/crew/quartermaster/petsplosion/New() - . = ..() - target_amount = rand(10,30) - update_explanation_text() - -/datum/objective/crew/quartermaster/petsplosion/update_explanation_text() - . = ..() - explanation_text = "Ensure there are at least [target_amount] pets on the station by the end of the shift. Interpret this as you wish." - -/datum/objective/crew/quartermaster/petsplosion/check_completion() - var/petcount = target_amount - for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) - if(!P.stat == DEAD) - if(P.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) - petcount-- - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(!H.stat == DEAD) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) - petcount-- - if(petcount <= 0) - return 1 - else - return 0 - -/datum/objective/crew/cargotechnician - -/datum/objective/crew/cargotechnician/petsplosion - explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." - -/datum/objective/crew/cargotechnician/petsplosion/New() - . = ..() - target_amount = rand(10,30) - update_explanation_text() - -/datum/objective/crew/cargotechnician/petsplosion/update_explanation_text() - . = ..() - explanation_text = "Ensure there are at least [target_amount] pets on the station by the end of the shift. Interpret this as you wish." - -/datum/objective/crew/cargotechnician/petsplosion/check_completion() - var/petcount = target_amount - for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) - if(!P.stat == DEAD) - if(P.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) - petcount-- - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(!H.stat == DEAD) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) - petcount-- - if(petcount <= 0) - return 1 - else - return 0 - -/datum/objective/crew/shaftminer - -/datum/objective/crew/shaftminer/bubblegum - explanation_text = "Ensure Bubblegum is dead at the end of the shift." - -/datum/objective/crew/shaftminer/bubblegum/check_completion() - for(var/mob/living/simple_animal/hostile/megafauna/bubblegum/B in GLOB.mob_list) - if(!B.stat == DEAD) - return 0 - return 1 - -/* CIVILLIAN OBJECTIVES */ - -/datum/objective/crew/botanist - -/datum/objective/crew/botanist/druglord //ported from old Hippie with adjustments - var/targetchem = "none" - var/datum/reagent/chempath - explanation_text = "Have at least (somethin broke here) harvested plants containing (report this on the development discussion channel of citadel's discord) when the shift ends." - -/datum/objective/crew/botanist/druglord/New() - . = ..() - target_amount = rand(3,20) - var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) - var/drugs = typesof(/datum/reagent/drug) - blacklist - var/meds = typesof(/datum/reagent/medicine) - blacklist - var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac - chempath = pick(chemlist) - targetchem = initial(chempath.id) - update_explanation_text() - -/datum/objective/crew/botanist/druglord/update_explanation_text() - . = ..() - explanation_text = "Have at least [target_amount] harvested plants containing [initial(chempath.name)] when the shift ends." - -/datum/objective/crew/botanist/druglord/check_completion() - var/pillcount = target_amount - if(owner.current) - if(owner.current.contents) - for(var/obj/item/reagent_containers/food/snacks/grown/P in owner.current.get_contents()) - if(P.reagents.has_reagent(targetchem)) - pillcount-- - if(pillcount <= 0) - return 1 - else - return 0 - -/datum/objective/crew/bartender - -/datum/objective/crew/bartender/responsibility - explanation_text = "Make sure nobody dies of alchohol poisoning." - -/datum/objective/crew/bartender/responsibility/check_completion() - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(H.stat == DEAD && H.drunkenness >= 80) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - return 0 - return 1 - -/datum/objective/crew/janitor - -/datum/objective/crew/janitor/clean //ported from old Hippie - var/list/areas = list() - explanation_text = "Ensure sure that (Yo, something broke. Yell about this in citadels devlopmeent discussion channel.) remain spotless at the end of the shift." - -/datum/objective/crew/janitor/clean/New() - . = ..() - var/list/possibleareas = GLOB.teleportlocs - /area - typesof(/area/space) - typesof(/area/lavaland) - typesof(/area/mine) - typesof(/area/ai_monitored/turret_protected) - typesof(/area/tcommsat) - for(var/i in 1 to rand(1,6)) - areas |= pick_n_take(possibleareas) - update_explanation_text() - -/datum/objective/crew/janitor/clean/update_explanation_text() - . = ..() - explanation_text = "Ensure that the " - for(var/i in 1 to areas.len) - var/area/A = areas[i] - explanation_text += "[A]" - if(i != areas.len && areas.len >= 3) - explanation_text += ", " - if(i == areas.len - 1) - explanation_text += "and " - explanation_text += " [(areas.len ==1) ? "is completely" : "are [(areas.len == 2) ? "completely" : "all"]"] clean at the end of the shift." - -/datum/objective/crew/janitor/clean/check_completion() - for(var/area/A in areas) - for(var/obj/effect/decal/cleanable/C in area_contents(A)) - return 0 - return 1 - -/datum/objective/crew/clown - -/datum/objective/crew/clown/slipster //ported from old Hippie with adjustments - explanation_text = "Slip at least (Yell on citadel's development discussion channel if you see this) different people with your PDA, and have it on you at the end of the shift." - -/datum/objective/crew/clown/slipster/New() - . = ..() - target_amount = rand(5, 20) - update_explanation_text() - -/datum/objective/crew/clown/slipster/update_explanation_text() - . = ..() - explanation_text = "Slip at least [target_amount] different people with your PDA, and have it on you at the end of the shift." - -/datum/objective/crew/clown/slipster/check_completion() - var/list/uniqueslips = list() - if(owner.current) - for(var/obj/item/device/pda/clown/PDA in owner.current.get_contents()) //100% open for badmin abuse - for(var/mob/living/carbon/human/H in PDA.slipvictims) - uniqueslips |= H - if(uniqueslips.len >= target_amount) - return 1 - else - return 0 - -/datum/objective/crew/mime - -/datum/objective/crew/mime/vow //ported from old Hippie - explanation_text = "Never break your vow of silence." - -/datum/objective/crew/mime/vow/check_completion() - if(owner.current) - var/list/say_log = owner.current.logging[INDIVIDUAL_SAY_LOG] - if(say_log.len > 0) - return 0 - return 1 - -/datum/objective/crew/assistant - -/datum/objective/crew/assistant/departmentclothes - var/obj/item/clothing/under/rank/targetuniform - explanation_text = "Be wearing a (Yo, this objective broke. report this to citadels discord via the development channel) at the end of the shift." - -/datum/objective/crew/assistant/departmentclothes/New() - . = ..() - var/list/blacklist = list(/obj/item/clothing/under/rank, /obj/item/clothing/under/rank/miner, /obj/item/clothing/under/rank/medical/blue, /obj/item/clothing/under/rank/medical/green, /obj/item/clothing/under/rank/medical/purple, /obj/item/clothing/under/rank/security/grey, /obj/item/clothing/under/rank/warden/grey, /obj/item/clothing/under/rank/head_of_security/grey, /obj/item/clothing/under/rank/mailman, /obj/item/clothing/under/rank/psyche, /obj/item/clothing/under/rank/clown/sexy, /obj/item/clothing/under/rank/centcom_officer, /obj/item/clothing/under/rank/centcom_commander, /obj/item/clothing/under/rank/security/navyblue/russian, /obj/item/clothing/under/rank/security/blueshirt) - var/list/validclothes = typesof(/obj/item/clothing/under/rank) - blacklist - targetuniform = pick(validclothes) - update_explanation_text() - -/datum/objective/crew/assistant/departmentclothes/update_explanation_text() - . = ..() - explanation_text = "Be wearing a [targetuniform] at the end of the shift." - -/datum/objective/crew/assistant/departmentclothes/check_completion() - if(owner.current) - if(istype(H.w_uniform, targetuniform)) - return 1 - return 0 - -/datum/objective/crew/assistant/petsplosion - explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." - -/datum/objective/crew/assistant/petsplosion/New() - . = ..() - target_amount = rand(10,20) - update_explanation_text() - -/datum/objective/crew/assistant/petsplosion/update_explanation_text() - . = ..() - explanation_text = "Ensure there are at least [target_amount] pets on the station by the end of the shift. Interpret this as you wish." - -/datum/objective/crew/assistant/petsplosion/check_completion() - var/petcount = target_amount - for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) - if(!P.stat == DEAD) - if(P.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) - petcount-- - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(!H.stat == DEAD) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) - petcount-- - if(petcount <= 0) - return 1 - else - return 0 diff --git a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm new file mode 100644 index 0000000000..8ce77ed93b --- /dev/null +++ b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm @@ -0,0 +1,72 @@ +/* CARGO OBJECTIVES */ + +/datum/objective/crew/quartermaster + +/datum/objective/crew/quartermaster/petsplosion + explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." + +/datum/objective/crew/quartermaster/petsplosion/New() + . = ..() + target_amount = rand(10,30) + update_explanation_text() + +/datum/objective/crew/quartermaster/petsplosion/update_explanation_text() + . = ..() + explanation_text = "Ensure there are at least [target_amount] pets on the station by the end of the shift. Interpret this as you wish." + +/datum/objective/crew/quartermaster/petsplosion/check_completion() + var/petcount = target_amount + for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) + if(!P.stat == DEAD) + if(P.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) + petcount-- + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(!H.stat == DEAD) + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) + petcount-- + if(petcount <= 0) + return 1 + else + return 0 + +/datum/objective/crew/cargotechnician + +/datum/objective/crew/cargotechnician/petsplosion + explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." + +/datum/objective/crew/cargotechnician/petsplosion/New() + . = ..() + target_amount = rand(10,30) + update_explanation_text() + +/datum/objective/crew/cargotechnician/petsplosion/update_explanation_text() + . = ..() + explanation_text = "Ensure there are at least [target_amount] pets on the station by the end of the shift. Interpret this as you wish." + +/datum/objective/crew/cargotechnician/petsplosion/check_completion() + var/petcount = target_amount + for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) + if(!P.stat == DEAD) + if(P.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) + petcount-- + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(!H.stat == DEAD) + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) + petcount-- + if(petcount <= 0) + return 1 + else + return 0 + +/datum/objective/crew/shaftminer + +/datum/objective/crew/shaftminer/bubblegum + explanation_text = "Ensure Bubblegum is dead at the end of the shift." + +/datum/objective/crew/shaftminer/bubblegum/check_completion() + for(var/mob/living/simple_animal/hostile/megafauna/bubblegum/B in GLOB.mob_list) + if(!B.stat == DEAD) + return 0 + return 1 diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm new file mode 100644 index 0000000000..57d54acf5a --- /dev/null +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -0,0 +1,166 @@ +/* CIVILIAN OBJECTIVES */ + +/datum/objective/crew/botanist + +/datum/objective/crew/botanist/druglord //ported from old Hippie with adjustments + var/targetchem = "none" + var/datum/reagent/chempath + explanation_text = "Have at least (somethin broke here) harvested plants containing (report this on the development discussion channel of citadel's discord) when the shift ends." + +/datum/objective/crew/botanist/druglord/New() + . = ..() + target_amount = rand(3,20) + var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) + var/drugs = typesof(/datum/reagent/drug) - blacklist + var/meds = typesof(/datum/reagent/medicine) - blacklist + var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac + chempath = pick(chemlist) + targetchem = initial(chempath.id) + update_explanation_text() + +/datum/objective/crew/botanist/druglord/update_explanation_text() + . = ..() + explanation_text = "Have at least [target_amount] harvested plants containing [initial(chempath.name)] when the shift ends." + +/datum/objective/crew/botanist/druglord/check_completion() + var/pillcount = target_amount + if(owner.current) + if(owner.current.contents) + for(var/obj/item/reagent_containers/food/snacks/grown/P in owner.current.get_contents()) + if(P.reagents.has_reagent(targetchem)) + pillcount-- + if(pillcount <= 0) + return 1 + else + return 0 + +/datum/objective/crew/bartender + +/datum/objective/crew/bartender/responsibility + explanation_text = "Make sure nobody dies of alchohol poisoning." + +/datum/objective/crew/bartender/responsibility/check_completion() + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(H.stat == DEAD && H.drunkenness >= 80) + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + return 0 + return 1 + +/datum/objective/crew/janitor + +/datum/objective/crew/janitor/clean //ported from old Hippie + var/list/areas = list() + explanation_text = "Ensure sure that (Yo, something broke. Yell about this in citadels devlopmeent discussion channel.) remain spotless at the end of the shift." + +/datum/objective/crew/janitor/clean/New() + . = ..() + var/list/possibleareas = GLOB.teleportlocs - /area - typesof(/area/space) - typesof(/area/lavaland) - typesof(/area/mine) - typesof(/area/ai_monitored/turret_protected) - typesof(/area/tcommsat) + for(var/i in 1 to rand(1,6)) + areas |= pick_n_take(possibleareas) + update_explanation_text() + +/datum/objective/crew/janitor/clean/update_explanation_text() + . = ..() + explanation_text = "Ensure that the " + for(var/i in 1 to areas.len) + var/area/A = areas[i] + explanation_text += "[A]" + if(i != areas.len && areas.len >= 3) + explanation_text += ", " + if(i == areas.len - 1) + explanation_text += "and " + explanation_text += " [(areas.len ==1) ? "is completely" : "are [(areas.len == 2) ? "completely" : "all"]"] clean at the end of the shift." + +/datum/objective/crew/janitor/clean/check_completion() + for(var/area/A in areas) + for(var/obj/effect/decal/cleanable/C in area_contents(A)) + return 0 + return 1 + +/datum/objective/crew/clown + +/datum/objective/crew/clown/slipster //ported from old Hippie with adjustments + explanation_text = "Slip at least (Yell on citadel's development discussion channel if you see this) different people with your PDA, and have it on you at the end of the shift." + +/datum/objective/crew/clown/slipster/New() + . = ..() + target_amount = rand(5, 20) + update_explanation_text() + +/datum/objective/crew/clown/slipster/update_explanation_text() + . = ..() + explanation_text = "Slip at least [target_amount] different people with your PDA, and have it on you at the end of the shift." + +/datum/objective/crew/clown/slipster/check_completion() + var/list/uniqueslips = list() + if(owner.current) + for(var/obj/item/device/pda/clown/PDA in owner.current.get_contents()) //100% open for badmin abuse + for(var/mob/living/carbon/human/H in PDA.slipvictims) + uniqueslips |= H + if(uniqueslips.len >= target_amount) + return 1 + else + return 0 + +/datum/objective/crew/mime + +/datum/objective/crew/mime/vow //ported from old Hippie + explanation_text = "Never break your vow of silence." + +/datum/objective/crew/mime/vow/check_completion() + if(owner.current) + var/list/say_log = owner.current.logging[INDIVIDUAL_SAY_LOG] + if(say_log.len > 0) + return 0 + return 1 + +/datum/objective/crew/assistant + +/datum/objective/crew/assistant/departmentclothes + var/obj/item/clothing/under/rank/targetuniform + explanation_text = "Be wearing a (Yo, this objective broke. report this to citadels discord via the development channel) at the end of the shift." + +/datum/objective/crew/assistant/departmentclothes/New() + . = ..() + var/list/blacklist = list(/obj/item/clothing/under/rank, /obj/item/clothing/under/rank/miner, /obj/item/clothing/under/rank/medical/blue, /obj/item/clothing/under/rank/medical/green, /obj/item/clothing/under/rank/medical/purple, /obj/item/clothing/under/rank/security/grey, /obj/item/clothing/under/rank/warden/grey, /obj/item/clothing/under/rank/head_of_security/grey, /obj/item/clothing/under/rank/mailman, /obj/item/clothing/under/rank/psyche, /obj/item/clothing/under/rank/clown/sexy, /obj/item/clothing/under/rank/centcom_officer, /obj/item/clothing/under/rank/centcom_commander, /obj/item/clothing/under/rank/security/navyblue/russian, /obj/item/clothing/under/rank/security/blueshirt) + var/list/validclothes = typesof(/obj/item/clothing/under/rank) - blacklist + targetuniform = pick(validclothes) + update_explanation_text() + +/datum/objective/crew/assistant/departmentclothes/update_explanation_text() + . = ..() + explanation_text = "Be wearing a [targetuniform] at the end of the shift." + +/datum/objective/crew/assistant/departmentclothes/check_completion() + if(owner.current) + if(istype(owner.current.w_uniform, targetuniform)) + return 1 + return 0 + +/datum/objective/crew/assistant/petsplosion + explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." + +/datum/objective/crew/assistant/petsplosion/New() + . = ..() + target_amount = rand(10,20) + update_explanation_text() + +/datum/objective/crew/assistant/petsplosion/update_explanation_text() + . = ..() + explanation_text = "Ensure there are at least [target_amount] pets on the station by the end of the shift. Interpret this as you wish." + +/datum/objective/crew/assistant/petsplosion/check_completion() + var/petcount = target_amount + for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) + if(!P.stat == DEAD) + if(P.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) + petcount-- + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(!H.stat == DEAD) + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) + petcount-- + if(petcount <= 0) + return 1 + else + return 0 diff --git a/code/citadel/crew_objectives/cit_crewobjectives_command.dm b/code/citadel/crew_objectives/cit_crewobjectives_command.dm new file mode 100644 index 0000000000..c82954d6b2 --- /dev/null +++ b/code/citadel/crew_objectives/cit_crewobjectives_command.dm @@ -0,0 +1,43 @@ +/* COMMAND OBJECTIVES */ + +/datum/objective/crew/captain/ + +/datum/objective/crew/captain/hat //Ported from Goon + explanation_text = "Don't lose your hat." + +/datum/objective/crew/captain/hat/check_completion() + if(owner.current && owner.current.check_contents_for(/obj/item/clothing/head/caphat)) + return 1 + else + return 0 + +/datum/objective/crew/captain/datfukkendisk //Ported from old Hippie + explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." + +/datum/objective/crew/captain/datfukkendisk/check_completion() + if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) + return 1 + else + return 0 + +/datum/objective/crew/headofpersonnel/ + +/datum/objective/crew/headofpersonnel/ian //Ported from old Hippie + explanation_text = "Defend Ian at all costs, and ensure he gets delivered to Centcom at the end of the shift." + +/datum/objective/crew/headofpersonnel/ian/check_completion() + if(owner.current) + for(var/mob/living/simple_animal/pet/dog/corgi/Ian/goodboy in GLOB.mob_list) + if(goodboy.stat != DEAD && SSshuttle.emergency.shuttle_areas[get_area(goodboy)]) + return 1 + return 0 + return 0 + +/datum/objective/crew/headofpersonnel/datfukkendisk //Ported from old Hippie + explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." + +/datum/objective/crew/headofpersonnel/datfukkendisk/check_completion() + if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) + return 1 + else + return 0 diff --git a/code/citadel/crew_objectives/cit_crewobjectives_medical.dm b/code/citadel/crew_objectives/cit_crewobjectives_medical.dm new file mode 100644 index 0000000000..0e3c92b338 --- /dev/null +++ b/code/citadel/crew_objectives/cit_crewobjectives_medical.dm @@ -0,0 +1,137 @@ +/* MEDICAL OBJECTIVES */ + +/datum/objective/crew/chiefmedicalofficer/ + +/datum/objective/crew/chiefmedicalofficer/morgue //Ported from old Hippie + explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." + +/datum/objective/crew/chiefmedicalofficer/morgue/check_completion() + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(H.stat == DEAD && H.z == ZLEVEL_STATION) + if(get_area(H) != /area/medical/morgue) + return 0 + return 1 + +/datum/objective/crew/chiefmedicalofficer/chems //Ported from old Hippie + var/targetchem = "none" + var/datum/reagent/chempath + explanation_text = "Have (yell about this in the development discussion channel of citadel's discord, something broke) in your bloodstream when the shift ends." + +/datum/objective/crew/chiefmedicalofficer/chems/New() + . = ..() + var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) + var/drugs = typesof(/datum/reagent/drug) - blacklist + var/meds = typesof(/datum/reagent/medicine) - blacklist + var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac + chempath = pick(chemlist) + targetchem = initial(chempath.id) + update_explanation_text() + +/datum/objective/crew/chiefmedicalofficer/chems/update_explanation_text() + . = ..() + explanation_text = "Have [initial(chempath.name)] in your bloodstream when the shift ends." + +/datum/objective/crew/chiefmedicalofficer/chems/check_completion() + if(owner.current) + if(!owner.current.stat == DEAD && owner.current.reagents) + if(owner.current.reagents.has_reagent(targetchem)) + return 1 + else + return 0 + +/datum/objective/crew/geneticist + +/datum/objective/crew/geneticist/morgue //Ported from old Hippie + explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." + +/datum/objective/crew/geneticist/morgue/check_completion() + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(H.stat == DEAD && H.z == ZLEVEL_STATION) + if(get_area(H) != /area/medical/morgue) + return 0 + return 1 + +/datum/objective/crew/chemist/ + +/datum/objective/crew/chemist/chems //Ported from old Hippie + var/targetchem = "none" + var/datum/reagent/chempath + explanation_text = "Have (yell about this in the development discussion channel of citadel's discord, something broke) in your bloodstream when the shift ends." + +/datum/objective/crew/chemist/chems/New() + . = ..() + var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) + var/drugs = typesof(/datum/reagent/drug) - blacklist + var/meds = typesof(/datum/reagent/medicine) - blacklist + var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac + chempath = pick(chemlist) + targetchem = initial(chempath.id) + update_explanation_text() + +/datum/objective/crew/chemist/chems/update_explanation_text() + . = ..() + explanation_text = "Have [initial(chempath.name)] in your bloodstream when the shift ends." + +/datum/objective/crew/chemist/chems/check_completion() + if(owner.current) + if(!owner.current.stat == DEAD && owner.current.reagents) + if(owner.current.reagents.has_reagent(targetchem)) + return 1 + else + return 0 + +/datum/objective/crew/chemist/druglord //ported from old Hippie with adjustments + var/targetchem = "none" + var/datum/reagent/chempath + explanation_text = "Have at least (somethin broke here) pills containing (report this on the development discussion channel of citadel's discord) when the shift ends." + +/datum/objective/crew/chemist/druglord/New() + . = ..() + target_amount = rand(5,50) + var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol) + var/drugs = typesof(/datum/reagent/drug) - blacklist + var/chemlist = drugs + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac + chempath = pick(chemlist) + targetchem = initial(chempath.id) + update_explanation_text() + +/datum/objective/crew/chemist/druglord/update_explanation_text() + . = ..() + explanation_text = "Have at least [target_amount] pills containing [initial(chempath.name)] when the shift ends." + +/datum/objective/crew/chemist/druglord/check_completion() + var/pillcount = target_amount + if(owner.current) + if(owner.current.contents) + for(var/obj/item/reagent_containers/pill/P in owner.current.get_contents()) + if(P.reagents.has_reagent(targetchem)) + pillcount-- + if(pillcount <= 0) + return 1 + else + return 0 + +/datum/objective/crew/virologist + +/datum/objective/crew/virologist/noinfections + explanation_text = "Ensure no living crew members are infected with harmful viruses at the end of the shift" + +/datum/objective/crew/virologist/noinfections/check_completion() + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(!H.stat == DEAD) + if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if(H.check_virus() == 2) + return 0 + return 1 + +/datum/objective/crew/medicaldoctor + +/datum/objective/crew/medicaldoctor/morgue //Ported from old Hippie + explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." + +/datum/objective/crew/medicaldoctor/morgue/check_completion() + for(var/mob/living/carbon/human/H in GLOB.mob_list) + if(H.stat == DEAD && H.z == ZLEVEL_STATION) + if(get_area(H) != /area/medical/morgue) + return 0 + return 1 diff --git a/code/citadel/crew_objectives/cit_crewobjectives_science.dm b/code/citadel/crew_objectives/cit_crewobjectives_science.dm new file mode 100644 index 0000000000..a186242141 --- /dev/null +++ b/code/citadel/crew_objectives/cit_crewobjectives_science.dm @@ -0,0 +1,49 @@ +/* SCIENCE OBJECTIVES */ + +/datum/objective/crew/researchdirector/ + +/datum/objective/crew/researchdirector/cyborgs //Ported from old Hippie + explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's development discussion channel about this) functioning cyborgs when the shift ends." + +/datum/objective/crew/researchdirector/cyborgs/New() + . = ..() + target_amount = rand(3,10) + update_explanation_text() + +/datum/objective/crew/researchdirector/cyborgs/update_explanation_text() + . = ..() + explanation_text = "Ensure there are at least [target_amount] functioning cyborgs when the shift ends." + +/datum/objective/crew/researchdirector/cyborgs/check_completion() + var/borgcount = target_amount + for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) + if(!R.stat == DEAD) + borgcount-- + if(borgcount <= 0) + return 1 + else + return 0 + +/datum/objective/crew/roboticist/ + +/datum/objective/crew/roboticist/cyborgs //Ported from old Hippie + explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's development discussion channel about this) functioning cyborgs when the shift ends." + +/datum/objective/crew/roboticist/cyborgs/New() + . = ..() + target_amount = rand(3,10) + update_explanation_text() + +/datum/objective/crew/roboticist/cyborgs/update_explanation_text() + . = ..() + explanation_text = "Ensure there are at least [target_amount] functioning cyborgs when the shift ends." + +/datum/objective/crew/roboticist/cyborgs/check_completion() + var/borgcount = target_amount + for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) + if(!R.stat == DEAD) + borgcount-- + if(borgcount <= 0) + return 1 + else + return 0 diff --git a/code/citadel/crew_objectives/cit_crewobjectives_security.dm b/code/citadel/crew_objectives/cit_crewobjectives_security.dm new file mode 100644 index 0000000000..b453bd8633 --- /dev/null +++ b/code/citadel/crew_objectives/cit_crewobjectives_security.dm @@ -0,0 +1,75 @@ +/* SECURITY OBJECTIVES */ + +/datum/objective/crew/headofsecurity/ + +/datum/objective/crew/headofsecurity/justicecrew + explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." + +/datum/objective/crew/headofsecurity/justicecrew/check_completion() + if(owner.current) + for(var/datum/mind/M in SSticker.minds) + if(M.current && isliving(M.current)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) + return 0 + return 1 + +/datum/objective/crew/headofsecurity/datfukkendisk //Ported from old Hippie + explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." + +/datum/objective/crew/headofsecurity/datfukkendisk/check_completion() + if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) + return 1 + else + return 0 + +/datum/objective/crew/securityofficer/ + +/datum/objective/crew/securityofficer/justicecrew + explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." + +/datum/objective/crew/securityofficer/justicecrew/check_completion() + if(owner.current) + for(var/datum/mind/M in SSticker.minds) + if(M.current && isliving(M.current)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) + return 0 + return 1 + +/datum/objective/crew/warden/ + +/datum/objective/crew/warden/justicecrew + explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." + +/datum/objective/crew/warden/justicecrew/check_completion() + if(owner.current) + for(var/datum/mind/M in SSticker.minds) + if(M.current && isliving(M.current)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) + return 0 + return 1 + +/datum/objective/crew/detective/ + +/datum/objective/crew/detective/justicecrew + explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." + +/datum/objective/crew/detective/justicecrew/check_completion() + if(owner.current) + for(var/datum/mind/M in SSticker.minds) + if(M.current && isliving(M.current)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) + return 0 + return 1 + +/datum/objective/crew/lawyer/ + +/datum/objective/crew/lawyer/justicecrew + explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." + +/datum/objective/crew/lawyer/justicecrew/check_completion() + if(owner.current) + for(var/datum/mind/M in SSticker.minds) + if(M.current && isliving(M.current)) + if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) + return 0 + return 1 diff --git a/tgstation.dme b/tgstation.dme index 19ea044625..3d44b7c398 100755 --- a/tgstation.dme +++ b/tgstation.dme @@ -175,6 +175,12 @@ #include "code\citadel\cit_uniforms.dm" #include "code\citadel\cit_vendors.dm" #include "code\citadel\dogborgstuff.dm" +#include "code\citadel\crew_objectives\cit_crewobjectives_cargo.dm" +#include "code\citadel\crew_objectives\cit_crewobjectives_civilian.dm" +#include "code\citadel\crew_objectives\cit_crewobjectives_command.dm" +#include "code\citadel\crew_objectives\cit_crewobjectives_medical.dm" +#include "code\citadel\crew_objectives\cit_crewobjectives_science.dm" +#include "code\citadel\crew_objectives\cit_crewobjectives_security.dm" #include "code\citadel\custom_loadout\custom_items.dm" #include "code\citadel\custom_loadout\load_to_mob.dm" #include "code\citadel\custom_loadout\read_from_file.dm" From 68a6ff5cfbc2e167f29a9d4b22f03cac3411505f Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 22:24:10 -0400 Subject: [PATCH 074/120] just,,, compile, please --- code/citadel/crew_objectives/cit_crewobjectives_civilian.dm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 57d54acf5a..eb1490c017 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -133,7 +133,8 @@ /datum/objective/crew/assistant/departmentclothes/check_completion() if(owner.current) - if(istype(owner.current.w_uniform, targetuniform)) + var/mob/living/carbon/human/H = owner.current + if(istype(H.w_uniform, targetuniform)) return 1 return 0 From a972a6272fad3761b933d2456bd23ff2bb70186e Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 6 Sep 2017 22:54:51 -0400 Subject: [PATCH 075/120] chef objective --- .../cit_crewobjectives_civilian.dm | 26 +++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index eb1490c017..dc461041dd 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -34,6 +34,32 @@ else return 0 +/datum/objective/crew/chef + +/datum/objective/crew/chef/foodhoard + var/datum/crafting_recipe/food/targetfood + var/obj/item/reagent_containers/food/foodpath + explanation_text = "Personally deliver at least (yo something broke) (report this to the developer discussion channel in citadels discord)s to Centcom." + +/datum/objective/crew/chef/foodhoard/New() + . = ..() + target_amount = rand(2,10) + var/blacklist = list(/datum/crafting_recipe/food) + var/possiblefoods = typesof(/datum/crafting_recipe/food) - blacklist + targetfood = pick(possiblefoods) + foodpath = targetfood.result + update_explanation_text() + +/datum/objective/crew/chef/foodhoard/update_explanation_text() + . = ..() + explanation_text = "Personally deliver at least [target_amount] [initial(foodpath.name)]s to Centcom." + +/datum/objective/crew/chef/foodhoard/check_completion() + if(owner.current && owner.current.check_contents_for(foodpath) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) + return 1 + else + return 0 + /datum/objective/crew/bartender /datum/objective/crew/bartender/responsibility From d5151ed91899aa08e0ca4170f302993aacb7422c Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 7 Sep 2017 01:01:23 -0400 Subject: [PATCH 076/120] fixes --- code/citadel/cit_crewobjectives.dm | 2 +- .../crew_objectives/cit_crewobjectives_civilian.dm | 12 ++++++------ code/modules/mob/dead/new_player/new_player.dm | 2 +- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 83422bd054..f40d1fff3c 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -1,6 +1,6 @@ /datum/controller/subsystem/ticker/proc/generate_crew_objectives() for(var/datum/mind/crewMind in SSticker.minds) - if(prob(10) && GLOB.master_mode != "extended")//extended is supposed to have less chaos + if(prob(10) && !issilicon(crewMind.current) && GLOB.master_mode != "extended")//extended is supposed to have less chaos generate_miscreant_objectives(crewMind) else generate_individual_objectives(crewMind) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index dc461041dd..188b825a3b 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -34,27 +34,27 @@ else return 0 -/datum/objective/crew/chef +/datum/objective/crew/cook -/datum/objective/crew/chef/foodhoard +/datum/objective/crew/cook/foodhoard var/datum/crafting_recipe/food/targetfood var/obj/item/reagent_containers/food/foodpath explanation_text = "Personally deliver at least (yo something broke) (report this to the developer discussion channel in citadels discord)s to Centcom." -/datum/objective/crew/chef/foodhoard/New() +/datum/objective/crew/cook/foodhoard/New() . = ..() target_amount = rand(2,10) var/blacklist = list(/datum/crafting_recipe/food) var/possiblefoods = typesof(/datum/crafting_recipe/food) - blacklist targetfood = pick(possiblefoods) - foodpath = targetfood.result + foodpath = initial(targetfood.result) update_explanation_text() -/datum/objective/crew/chef/foodhoard/update_explanation_text() +/datum/objective/crew/cook/foodhoard/update_explanation_text() . = ..() explanation_text = "Personally deliver at least [target_amount] [initial(foodpath.name)]s to Centcom." -/datum/objective/crew/chef/foodhoard/check_completion() +/datum/objective/crew/cook/foodhoard/check_completion() if(owner.current && owner.current.check_contents_for(foodpath) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) return 1 else diff --git a/code/modules/mob/dead/new_player/new_player.dm b/code/modules/mob/dead/new_player/new_player.dm index 428773bd9b..19ed0bed9d 100644 --- a/code/modules/mob/dead/new_player/new_player.dm +++ b/code/modules/mob/dead/new_player/new_player.dm @@ -367,7 +367,7 @@ if(GLOB.highlander) to_chat(humanc, "THERE CAN BE ONLY ONE!!!") humanc.make_scottish() - if(prob(10) && GLOB.master_mode != "extended") + if(prob(10) && !issilicon(humanc) && GLOB.master_mode != "extended") SSticker.generate_miscreant_objectives(humanc.mind) else SSticker.generate_individual_objectives(humanc.mind) From f8d149975ff0233209d2c7a72d15b7419d04b1ae Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 7 Sep 2017 15:43:17 -0400 Subject: [PATCH 077/120] engineering objectives, removes assistant petsplosion --- .../cit_crewobjectives_civilian.dm | 36 ++------------ .../cit_crewobjectives_engineering.dm | 47 +++++++++++++++++++ tgstation.dme | 1 + 3 files changed, 52 insertions(+), 32 deletions(-) create mode 100644 code/citadel/crew_objectives/cit_crewobjectives_engineering.dm diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 188b825a3b..65bb949c37 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -87,14 +87,14 @@ /datum/objective/crew/janitor/clean/update_explanation_text() . = ..() - explanation_text = "Ensure that the " + explanation_text = "Ensure that the" for(var/i in 1 to areas.len) var/area/A = areas[i] - explanation_text += "[A]" + explanation_text += " [A]" if(i != areas.len && areas.len >= 3) - explanation_text += ", " + explanation_text += "," if(i == areas.len - 1) - explanation_text += "and " + explanation_text += "and" explanation_text += " [(areas.len ==1) ? "is completely" : "are [(areas.len == 2) ? "completely" : "all"]"] clean at the end of the shift." /datum/objective/crew/janitor/clean/check_completion() @@ -163,31 +163,3 @@ if(istype(H.w_uniform, targetuniform)) return 1 return 0 - -/datum/objective/crew/assistant/petsplosion - explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." - -/datum/objective/crew/assistant/petsplosion/New() - . = ..() - target_amount = rand(10,20) - update_explanation_text() - -/datum/objective/crew/assistant/petsplosion/update_explanation_text() - . = ..() - explanation_text = "Ensure there are at least [target_amount] pets on the station by the end of the shift. Interpret this as you wish." - -/datum/objective/crew/assistant/petsplosion/check_completion() - var/petcount = target_amount - for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) - if(!P.stat == DEAD) - if(P.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) - petcount-- - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(!H.stat == DEAD) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) - petcount-- - if(petcount <= 0) - return 1 - else - return 0 diff --git a/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm new file mode 100644 index 0000000000..88eaa9e237 --- /dev/null +++ b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm @@ -0,0 +1,47 @@ +/* ENGINEERING OBJECTIVES */ + +/datum/objective/crew/chiefengineer + +/datum/objective/crew/chiefengineer/integrity //ported from old Hippie + explanation_text = "Ensure the station's integrity rating is at least (Yo something broke, yell on the development discussion channel of citadels discord about this)% when the shift ends." + +/datum/objective/crew/chiefengineer/integrity/New() + . = ..() + target_amount = rand(60,95) + update_explanation_text() + +/datum/objective/crew/chiefengineer/integrity/update_explanation_text() + . = ..() + explanation_text = "Ensure the station's integrity rating is at least [target_amount]% when the shift ends." + +/datum/objective/crew/chiefengineer/integrity/check_completion() + var/datum/station_state/end_state = new /datum/station_state() + end_state.count() + var/station_integrity = min(PERCENT(GLOB.start_state.score(end_state)), 100) + if(!SSticker.mode.station_was_nuked && station_integrity >= target_amount) + return 1 + else + return 0 + +/datum/objective/crew/stationengineer + +/datum/objective/crew/stationengineer/integrity + explanation_text = "Ensure the station's integrity rating is at least (Yo something broke, yell on the development discussion channel of citadels discord about this)% when the shift ends." + +/datum/objective/crew/stationengineer/integrity/New() + . = ..() + target_amount = rand(60,95) + update_explanation_text() + +/datum/objective/crew/stationengineer/integrity/update_explanation_text() + . = ..() + explanation_text = "Ensure the station's integrity rating is at least [target_amount]% when the shift ends." + +/datum/objective/crew/stationengineer/integrity/check_completion() + var/datum/station_state/end_state = new /datum/station_state() + end_state.count() + var/station_integrity = min(PERCENT(GLOB.start_state.score(end_state)), 100) + if(!SSticker.mode.station_was_nuked && station_integrity >= target_amount) + return 1 + else + return 0 diff --git a/tgstation.dme b/tgstation.dme index 3d44b7c398..da750b8b1d 100755 --- a/tgstation.dme +++ b/tgstation.dme @@ -178,6 +178,7 @@ #include "code\citadel\crew_objectives\cit_crewobjectives_cargo.dm" #include "code\citadel\crew_objectives\cit_crewobjectives_civilian.dm" #include "code\citadel\crew_objectives\cit_crewobjectives_command.dm" +#include "code\citadel\crew_objectives\cit_crewobjectives_engineering.dm" #include "code\citadel\crew_objectives\cit_crewobjectives_medical.dm" #include "code\citadel\crew_objectives\cit_crewobjectives_science.dm" #include "code\citadel\crew_objectives\cit_crewobjectives_security.dm" From 9116be1e53576f4a9a64284c5e8fedfdb926b4a2 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Fri, 8 Sep 2017 16:20:40 -0400 Subject: [PATCH 078/120] Extra objectives for assistants, poly objective for CE --- .../cit_crewobjectives_civilian.dm | 64 +++++++++++++++++-- .../cit_crewobjectives_engineering.dm | 12 +++- 2 files changed, 71 insertions(+), 5 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 65bb949c37..15c115128c 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -44,7 +44,7 @@ /datum/objective/crew/cook/foodhoard/New() . = ..() target_amount = rand(2,10) - var/blacklist = list(/datum/crafting_recipe/food) + var/blacklist = list(/datum/crafting_recipe/food, /datum/crafting_recipe/food/cak) var/possiblefoods = typesof(/datum/crafting_recipe/food) - blacklist targetfood = pick(possiblefoods) foodpath = initial(targetfood.result) @@ -63,7 +63,7 @@ /datum/objective/crew/bartender /datum/objective/crew/bartender/responsibility - explanation_text = "Make sure nobody dies of alchohol poisoning." + explanation_text = "Make sure nobody dies of alcohol poisoning." /datum/objective/crew/bartender/responsibility/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) @@ -76,11 +76,16 @@ /datum/objective/crew/janitor/clean //ported from old Hippie var/list/areas = list() + var/hardmode = 0 explanation_text = "Ensure sure that (Yo, something broke. Yell about this in citadels devlopmeent discussion channel.) remain spotless at the end of the shift." /datum/objective/crew/janitor/clean/New() . = ..() - var/list/possibleareas = GLOB.teleportlocs - /area - typesof(/area/space) - typesof(/area/lavaland) - typesof(/area/mine) - typesof(/area/ai_monitored/turret_protected) - typesof(/area/tcommsat) + if(prob(1)) + hardmode = 1 + var/list/blacklistnormal = list(typesof(/area/space) - typesof(/area/lavaland) - typesof(/area/mine) - typesof(/area/ai_monitored/turret_protected) - typesof(/area/tcommsat)) + var/list/blacklisthard = list(typesof(/area/lavaland) - typesof(/area/mine)) + var/list/possibleareas = GLOB.teleportlocs - /area - [(hardmode == 1) ? blacklisthard : blacklistnormal] for(var/i in 1 to rand(1,6)) areas |= pick_n_take(possibleareas) update_explanation_text() @@ -96,6 +101,8 @@ if(i == areas.len - 1) explanation_text += "and" explanation_text += " [(areas.len ==1) ? "is completely" : "are [(areas.len == 2) ? "completely" : "all"]"] clean at the end of the shift." + if(hardmode) + explanation_text += " Chop-chop." /datum/objective/crew/janitor/clean/check_completion() for(var/area/A in areas) @@ -120,7 +127,7 @@ /datum/objective/crew/clown/slipster/check_completion() var/list/uniqueslips = list() if(owner.current) - for(var/obj/item/device/pda/clown/PDA in owner.current.get_contents()) //100% open for badmin abuse + for(var/obj/item/device/pda/clown/PDA in owner.current.get_contents()) for(var/mob/living/carbon/human/H in PDA.slipvictims) uniqueslips |= H if(uniqueslips.len >= target_amount) @@ -163,3 +170,52 @@ if(istype(H.w_uniform, targetuniform)) return 1 return 0 + +/datum/objective/crew/assistant/spacesuit //ported from Goon + explanation_text = "Get your grubby hands on a space suit." + +/datum/objective/crew/assistant/spacesuit/New() + . = ..() + update_explanation_text() + +/datum/objective/crew/assistant/spacesuit/update_explanation_text() + . = ..() + if(owner.current) + var/mob/living/carbon/human/H = owner.current + explanation_text = "Get your " + if(H.dna.species.id == "avian") + explanation_text += "scratchy claws " + else if(H.dna.species.id == "mammal") + explanation_text += "dirty paws " + else if(H.dna.species.id == "aquatic") + explanation_text += "fishy hands " + else if(H.dna.species.id == "xeno") + explanation_text += "weird claws " + else if(H.dna.species.id == "guilmon") + explanation_text += "digital claws " + else if(H.dna.species.id == "lizard") + explanation_text += "slimy claws " + else if(H.dna.species.id == "datashark") + explanation_text += "glitchy hands " + else if(H.dna.species.id == "insect") + explanation_text += "gross grabbers " + else + explanation_text += "grubby hands " + explanation_text += "on a space suit." + +/datum/objective/crew/assistant/spacesuit/check_completion() + if(owner.current && owner.current.check_contents_for(typesof(/obj/item/clothing/suit/space))) + return 1 + else + return 0 + +/datum/objective/crew/assistant/promotion //ported from Goon + explanation_text = "Have a non-assistant ID registered to you at the end of the shift." + +/datum/objective/crew/assistant/promotion/check_completion() + if(owner.current) + var/mob/living/carbon/human/H = owner.current + if(istype(H.get_idcard()) + if(!H.get_assignment == "Assistant" && !H.get_assignment == "No id" && !H.get_assignment == "No job") + return 1 + return 0 \ No newline at end of file diff --git a/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm index 88eaa9e237..20347c1e60 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm @@ -23,9 +23,19 @@ else return 0 +/datum/objective/crew/chiefengineer/poly + explanation_text = "Make sure Poly keeps his headset, and stays alive until the end of the shift." + +/datum/objective/crew/chiefengineer/poly/check_completion() + for(var/mob/living/simple_animal/pet/parrot/Poly/dumbbird in GLOB.mob_list) + if(!dumbbird.stat == DEAD && dumbbird.ears) + if(istype(dumbbird.ears, /obj/item/device/radio/headset) + return 1 + return 0 + /datum/objective/crew/stationengineer -/datum/objective/crew/stationengineer/integrity +/datum/objective/crew/stationengineer/integrity //ported from old Hippie explanation_text = "Ensure the station's integrity rating is at least (Yo something broke, yell on the development discussion channel of citadels discord about this)% when the shift ends." /datum/objective/crew/stationengineer/integrity/New() From 547799c3acc4ad2c76c48ea614b2d815cd90d0d5 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Fri, 8 Sep 2017 16:26:33 -0400 Subject: [PATCH 079/120] bluh --- code/citadel/crew_objectives/cit_crewobjectives_civilian.dm | 2 +- code/citadel/crew_objectives/cit_crewobjectives_engineering.dm | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 15c115128c..c19059c85c 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -216,6 +216,6 @@ if(owner.current) var/mob/living/carbon/human/H = owner.current if(istype(H.get_idcard()) - if(!H.get_assignment == "Assistant" && !H.get_assignment == "No id" && !H.get_assignment == "No job") + if(!H.get_assignment() == "Assistant" && !H.get_assignment() == "No id" && !H.get_assignment() == "No job") return 1 return 0 \ No newline at end of file diff --git a/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm index 20347c1e60..38d113f764 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm @@ -29,7 +29,7 @@ /datum/objective/crew/chiefengineer/poly/check_completion() for(var/mob/living/simple_animal/pet/parrot/Poly/dumbbird in GLOB.mob_list) if(!dumbbird.stat == DEAD && dumbbird.ears) - if(istype(dumbbird.ears, /obj/item/device/radio/headset) + if(istype(dumbbird.ears, /obj/item/device/radio/headset)) return 1 return 0 From c85291071484b2d05f244687f8bd3390640069d8 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Fri, 8 Sep 2017 16:34:20 -0400 Subject: [PATCH 080/120] there we go --- code/citadel/crew_objectives/cit_crewobjectives_civilian.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index c19059c85c..4883481152 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -215,7 +215,7 @@ /datum/objective/crew/assistant/promotion/check_completion() if(owner.current) var/mob/living/carbon/human/H = owner.current - if(istype(H.get_idcard()) + if(istype(H.get_idcard())) if(!H.get_assignment() == "Assistant" && !H.get_assignment() == "No id" && !H.get_assignment() == "No job") return 1 return 0 \ No newline at end of file From 3852a246f8414745497816c683439671a80a2293 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Fri, 8 Sep 2017 16:47:42 -0400 Subject: [PATCH 081/120] byond cant handle ternaries --- code/citadel/crew_objectives/cit_crewobjectives_civilian.dm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 4883481152..66674a2c93 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -85,7 +85,10 @@ hardmode = 1 var/list/blacklistnormal = list(typesof(/area/space) - typesof(/area/lavaland) - typesof(/area/mine) - typesof(/area/ai_monitored/turret_protected) - typesof(/area/tcommsat)) var/list/blacklisthard = list(typesof(/area/lavaland) - typesof(/area/mine)) - var/list/possibleareas = GLOB.teleportlocs - /area - [(hardmode == 1) ? blacklisthard : blacklistnormal] + if(hardmode) + var/list/possibleareas = GLOB.teleportlocs - /area - blacklisthard + else + var/list/possibleareas = GLOB.teleportlocs - /area - blacklistnormal for(var/i in 1 to rand(1,6)) areas |= pick_n_take(possibleareas) update_explanation_text() From 591a086a4f9a5d1eb732cabbcfe684f182298adf Mon Sep 17 00:00:00 2001 From: deathride58 Date: Fri, 8 Sep 2017 17:17:59 -0400 Subject: [PATCH 082/120] .... apparently poly isn't a pet? --- code/citadel/crew_objectives/cit_crewobjectives_engineering.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm index 38d113f764..36a44ef9a7 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm @@ -27,7 +27,7 @@ explanation_text = "Make sure Poly keeps his headset, and stays alive until the end of the shift." /datum/objective/crew/chiefengineer/poly/check_completion() - for(var/mob/living/simple_animal/pet/parrot/Poly/dumbbird in GLOB.mob_list) + for(var/mob/living/simple_animal/parrot/Poly/dumbbird in GLOB.mob_list) if(!dumbbird.stat == DEAD && dumbbird.ears) if(istype(dumbbird.ears, /obj/item/device/radio/headset)) return 1 From bed1f4d88efe2ae00ccf244912f6032e1d5698cb Mon Sep 17 00:00:00 2001 From: deathride58 Date: Fri, 8 Sep 2017 17:27:57 -0400 Subject: [PATCH 083/120] gonna compile sooner or later --- code/citadel/crew_objectives/cit_crewobjectives_civilian.dm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 66674a2c93..008ee69996 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -85,10 +85,11 @@ hardmode = 1 var/list/blacklistnormal = list(typesof(/area/space) - typesof(/area/lavaland) - typesof(/area/mine) - typesof(/area/ai_monitored/turret_protected) - typesof(/area/tcommsat)) var/list/blacklisthard = list(typesof(/area/lavaland) - typesof(/area/mine)) + var/list/possibleareas = list() if(hardmode) - var/list/possibleareas = GLOB.teleportlocs - /area - blacklisthard + possibleareas = GLOB.teleportlocs - /area - blacklisthard else - var/list/possibleareas = GLOB.teleportlocs - /area - blacklistnormal + possibleareas = GLOB.teleportlocs - /area - blacklistnormal for(var/i in 1 to rand(1,6)) areas |= pick_n_take(possibleareas) update_explanation_text() From c1078c2c3ee1636d73a9116c8c8b4b9ae394e6eb Mon Sep 17 00:00:00 2001 From: deathride58 Date: Fri, 8 Sep 2017 17:56:42 -0400 Subject: [PATCH 084/120] eugh --- code/citadel/crew_objectives/cit_crewobjectives_civilian.dm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 008ee69996..c7324c2ff6 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -219,7 +219,8 @@ /datum/objective/crew/assistant/promotion/check_completion() if(owner.current) var/mob/living/carbon/human/H = owner.current - if(istype(H.get_idcard())) + var/obj/item/card/id/theID = H.get_idcard() + if(istype(theID)) if(!H.get_assignment() == "Assistant" && !H.get_assignment() == "No id" && !H.get_assignment() == "No job") return 1 return 0 \ No newline at end of file From 0ba79c0ad58f6b7ab92b4a65bac70ec774b05357 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Sun, 10 Sep 2017 02:46:06 -0400 Subject: [PATCH 085/120] i ded (replaces justicecrew for non-lawyer sec with a more open objective) --- .../cit_crewobjectives_security.dm | 114 ++++++++++++------ 1 file changed, 79 insertions(+), 35 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_security.dm b/code/citadel/crew_objectives/cit_crewobjectives_security.dm index b453bd8633..d0e2443591 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_security.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_security.dm @@ -2,17 +2,6 @@ /datum/objective/crew/headofsecurity/ -/datum/objective/crew/headofsecurity/justicecrew - explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." - -/datum/objective/crew/headofsecurity/justicecrew/check_completion() - if(owner.current) - for(var/datum/mind/M in SSticker.minds) - if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) - return 0 - return 1 - /datum/objective/crew/headofsecurity/datfukkendisk //Ported from old Hippie explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." @@ -22,44 +11,99 @@ else return 0 +/datum/objective/crew/headofsecurity/enjoyyourstay + explanation_text = "Welcome to Space Station 13. Enjoy your stay." + +/datum/objective/crew/headofsecurity/enjoyyourstay/New() + . = ..() + update_explanation_text() + +/datum/objective/crew/headofsecurity/enjoyyourstay/update_explanation_text() + . = ..() + var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.") + explanation_text = pick(edglines) + +/datum/objective/crew/headofsecurity/enjoyyourstay/check_completion() + explanation_text = "Enforce Space Law at all costs." + if(owner.current) + var/mob/living/carbon/human/H = owner.current + var/obj/item/card/id/theID = H.get_idcard() + if(istype(theID)) + if(!H.get_assignment() == "Head of Security") + return 0 + return 1 + /datum/objective/crew/securityofficer/ -/datum/objective/crew/securityofficer/justicecrew - explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." +/datum/objective/crew/securityofficer/enjoyyourstay + explanation_text = "Welcome to Space Station 13. Enjoy your stay." -/datum/objective/crew/securityofficer/justicecrew/check_completion() +/datum/objective/crew/securityofficer/enjoyyourstay/New() + . = ..() + update_explanation_text() + +/datum/objective/crew/securityofficer/enjoyyourstay/update_explanation_text() + . = ..() + var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.") + explanation_text = pick(edglines) + +/datum/objective/crew/securityofficer/enjoyyourstay/check_completion() + explanation_text = "Enforce Space Law at all costs." if(owner.current) - for(var/datum/mind/M in SSticker.minds) - if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) - return 0 - return 1 + var/mob/living/carbon/human/H = owner.current + var/obj/item/card/id/theID = H.get_idcard() + if(istype(theID)) + if(!H.get_assignment() == "Security Officer") + return 0 + return 1 /datum/objective/crew/warden/ -/datum/objective/crew/warden/justicecrew - explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." +/datum/objective/crew/warden/enjoyyourstay + explanation_text = "Welcome to Space Station 13. Enjoy your stay." -/datum/objective/crew/warden/justicecrew/check_completion() +/datum/objective/crew/warden/enjoyyourstay/New() + . = ..() + update_explanation_text() + +/datum/objective/crew/warden/enjoyyourstay/update_explanation_text() + . = ..() + var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.") + explanation_text = pick(edglines) + +/datum/objective/crew/warden/enjoyyourstay/check_completion() + explanation_text = "Enforce Space Law at all costs." if(owner.current) - for(var/datum/mind/M in SSticker.minds) - if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) - return 0 - return 1 + var/mob/living/carbon/human/H = owner.current + var/obj/item/card/id/theID = H.get_idcard() + if(istype(theID)) + if(!H.get_assignment() == "Warden") + return 0 + return 1 /datum/objective/crew/detective/ -/datum/objective/crew/detective/justicecrew - explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." +/datum/objective/crew/detective/enjoyyourstay + explanation_text = "Welcome to Space Station 13. Enjoy your stay." -/datum/objective/crew/detective/justicecrew/check_completion() +/datum/objective/crew/detective/enjoyyourstay/New() + . = ..() + update_explanation_text() + +/datum/objective/crew/detective/enjoyyourstay/update_explanation_text() + . = ..() + var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.", "Well, at least you know fashion.") + explanation_text = pick(edglines) + +/datum/objective/crew/detective/enjoyyourstay/check_completion() + explanation_text = "Enforce Space Law at all costs." if(owner.current) - for(var/datum/mind/M in SSticker.minds) - if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) - return 0 - return 1 + var/mob/living/carbon/human/H = owner.current + var/obj/item/card/id/theID = H.get_idcard() + if(istype(theID)) + if(!H.get_assignment() == "Detective") + return 0 + return 1 /datum/objective/crew/lawyer/ From 45330c909aebad902e6c082bf27f6ed1530eb0bf Mon Sep 17 00:00:00 2001 From: deathride58 Date: Sun, 10 Sep 2017 02:51:58 -0400 Subject: [PATCH 086/120] aphrodisiac is drugs now, no need to add them to the chemlist manually --- code/citadel/crew_objectives/cit_crewobjectives_civilian.dm | 2 +- code/citadel/crew_objectives/cit_crewobjectives_medical.dm | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index c7324c2ff6..4a51b1c3fa 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -13,7 +13,7 @@ var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) var/drugs = typesof(/datum/reagent/drug) - blacklist var/meds = typesof(/datum/reagent/medicine) - blacklist - var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac + var/chemlist = drugs + meds chempath = pick(chemlist) targetchem = initial(chempath.id) update_explanation_text() diff --git a/code/citadel/crew_objectives/cit_crewobjectives_medical.dm b/code/citadel/crew_objectives/cit_crewobjectives_medical.dm index 0e3c92b338..ea2b2dca77 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_medical.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_medical.dm @@ -22,7 +22,7 @@ var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) var/drugs = typesof(/datum/reagent/drug) - blacklist var/meds = typesof(/datum/reagent/medicine) - blacklist - var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac + var/chemlist = drugs + meds chempath = pick(chemlist) targetchem = initial(chempath.id) update_explanation_text() @@ -63,7 +63,7 @@ var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) var/drugs = typesof(/datum/reagent/drug) - blacklist var/meds = typesof(/datum/reagent/medicine) - blacklist - var/chemlist = drugs + meds + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac + var/chemlist = drugs + meds chempath = pick(chemlist) targetchem = initial(chempath.id) update_explanation_text() @@ -90,7 +90,7 @@ target_amount = rand(5,50) var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol) var/drugs = typesof(/datum/reagent/drug) - blacklist - var/chemlist = drugs + /datum/reagent/anaphrodisiac + /datum/reagent/aphrodisiac + var/chemlist = drugs chempath = pick(chemlist) targetchem = initial(chempath.id) update_explanation_text() From 9676b9f26dfe0d2663541d194afdbbe54ede500a Mon Sep 17 00:00:00 2001 From: deathride58 Date: Sat, 16 Sep 2017 23:18:57 -0400 Subject: [PATCH 087/120] places the cat firmly on a table --- .../cit_crewobjectives_cargo.dm | 12 ++-- .../cit_crewobjectives_civilian.dm | 36 ++++++------ .../cit_crewobjectives_command.dm | 18 +++--- .../cit_crewobjectives_engineering.dm | 12 ++-- .../cit_crewobjectives_medical.dm | 28 +++++----- .../cit_crewobjectives_science.dm | 8 +-- .../cit_crewobjectives_security.dm | 56 ++++++------------- 7 files changed, 73 insertions(+), 97 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm index 8ce77ed93b..bb3ef8b630 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm @@ -26,9 +26,9 @@ if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) petcount-- if(petcount <= 0) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/cargotechnician @@ -56,9 +56,9 @@ if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) petcount-- if(petcount <= 0) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/shaftminer @@ -68,5 +68,5 @@ /datum/objective/crew/shaftminer/bubblegum/check_completion() for(var/mob/living/simple_animal/hostile/megafauna/bubblegum/B in GLOB.mob_list) if(!B.stat == DEAD) - return 0 - return 1 + return FALSE + return TRUE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 4a51b1c3fa..500196bf98 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -30,9 +30,9 @@ if(P.reagents.has_reagent(targetchem)) pillcount-- if(pillcount <= 0) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/cook @@ -56,9 +56,9 @@ /datum/objective/crew/cook/foodhoard/check_completion() if(owner.current && owner.current.check_contents_for(foodpath) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/bartender @@ -69,8 +69,8 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.drunkenness >= 80) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) - return 0 - return 1 + return FALSE + return TRUE /datum/objective/crew/janitor @@ -111,8 +111,8 @@ /datum/objective/crew/janitor/clean/check_completion() for(var/area/A in areas) for(var/obj/effect/decal/cleanable/C in area_contents(A)) - return 0 - return 1 + return FALSE + return TRUE /datum/objective/crew/clown @@ -135,9 +135,9 @@ for(var/mob/living/carbon/human/H in PDA.slipvictims) uniqueslips |= H if(uniqueslips.len >= target_amount) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/mime @@ -148,8 +148,8 @@ if(owner.current) var/list/say_log = owner.current.logging[INDIVIDUAL_SAY_LOG] if(say_log.len > 0) - return 0 - return 1 + return FALSE + return TRUE /datum/objective/crew/assistant @@ -172,8 +172,8 @@ if(owner.current) var/mob/living/carbon/human/H = owner.current if(istype(H.w_uniform, targetuniform)) - return 1 - return 0 + return TRUE + return FALSE /datum/objective/crew/assistant/spacesuit //ported from Goon explanation_text = "Get your grubby hands on a space suit." @@ -209,9 +209,9 @@ /datum/objective/crew/assistant/spacesuit/check_completion() if(owner.current && owner.current.check_contents_for(typesof(/obj/item/clothing/suit/space))) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/assistant/promotion //ported from Goon explanation_text = "Have a non-assistant ID registered to you at the end of the shift." @@ -222,5 +222,5 @@ var/obj/item/card/id/theID = H.get_idcard() if(istype(theID)) if(!H.get_assignment() == "Assistant" && !H.get_assignment() == "No id" && !H.get_assignment() == "No job") - return 1 - return 0 \ No newline at end of file + return TRUE + return FALSE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_command.dm b/code/citadel/crew_objectives/cit_crewobjectives_command.dm index c82954d6b2..7ea715dfa8 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_command.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_command.dm @@ -7,18 +7,18 @@ /datum/objective/crew/captain/hat/check_completion() if(owner.current && owner.current.check_contents_for(/obj/item/clothing/head/caphat)) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/captain/datfukkendisk //Ported from old Hippie explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." /datum/objective/crew/captain/datfukkendisk/check_completion() if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/headofpersonnel/ @@ -29,15 +29,15 @@ if(owner.current) for(var/mob/living/simple_animal/pet/dog/corgi/Ian/goodboy in GLOB.mob_list) if(goodboy.stat != DEAD && SSshuttle.emergency.shuttle_areas[get_area(goodboy)]) - return 1 - return 0 - return 0 + return TRUE + return FALSE + return FALSE /datum/objective/crew/headofpersonnel/datfukkendisk //Ported from old Hippie explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." /datum/objective/crew/headofpersonnel/datfukkendisk/check_completion() if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) - return 1 + return TRUE else - return 0 + return FALSE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm index 36a44ef9a7..bb042f50aa 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm @@ -19,9 +19,9 @@ end_state.count() var/station_integrity = min(PERCENT(GLOB.start_state.score(end_state)), 100) if(!SSticker.mode.station_was_nuked && station_integrity >= target_amount) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/chiefengineer/poly explanation_text = "Make sure Poly keeps his headset, and stays alive until the end of the shift." @@ -30,8 +30,8 @@ for(var/mob/living/simple_animal/parrot/Poly/dumbbird in GLOB.mob_list) if(!dumbbird.stat == DEAD && dumbbird.ears) if(istype(dumbbird.ears, /obj/item/device/radio/headset)) - return 1 - return 0 + return TRUE + return FALSE /datum/objective/crew/stationengineer @@ -52,6 +52,6 @@ end_state.count() var/station_integrity = min(PERCENT(GLOB.start_state.score(end_state)), 100) if(!SSticker.mode.station_was_nuked && station_integrity >= target_amount) - return 1 + return TRUE else - return 0 + return FALSE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_medical.dm b/code/citadel/crew_objectives/cit_crewobjectives_medical.dm index ea2b2dca77..ec4228cc27 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_medical.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_medical.dm @@ -9,8 +9,8 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.z == ZLEVEL_STATION) if(get_area(H) != /area/medical/morgue) - return 0 - return 1 + return FALSE + return TRUE /datum/objective/crew/chiefmedicalofficer/chems //Ported from old Hippie var/targetchem = "none" @@ -35,9 +35,9 @@ if(owner.current) if(!owner.current.stat == DEAD && owner.current.reagents) if(owner.current.reagents.has_reagent(targetchem)) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/geneticist @@ -48,8 +48,8 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.z == ZLEVEL_STATION) if(get_area(H) != /area/medical/morgue) - return 0 - return 1 + return FALSE + return TRUE /datum/objective/crew/chemist/ @@ -76,9 +76,9 @@ if(owner.current) if(!owner.current.stat == DEAD && owner.current.reagents) if(owner.current.reagents.has_reagent(targetchem)) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/chemist/druglord //ported from old Hippie with adjustments var/targetchem = "none" @@ -107,9 +107,9 @@ if(P.reagents.has_reagent(targetchem)) pillcount-- if(pillcount <= 0) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/virologist @@ -121,8 +121,8 @@ if(!H.stat == DEAD) if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(H.check_virus() == 2) - return 0 - return 1 + return FALSE + return TRUE /datum/objective/crew/medicaldoctor @@ -133,5 +133,5 @@ for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.z == ZLEVEL_STATION) if(get_area(H) != /area/medical/morgue) - return 0 - return 1 + return FALSE + return TRUE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_science.dm b/code/citadel/crew_objectives/cit_crewobjectives_science.dm index a186242141..addca3dbbf 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_science.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_science.dm @@ -20,9 +20,9 @@ if(!R.stat == DEAD) borgcount-- if(borgcount <= 0) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/roboticist/ @@ -44,6 +44,6 @@ if(!R.stat == DEAD) borgcount-- if(borgcount <= 0) - return 1 + return TRUE else - return 0 + return FALSE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_security.dm b/code/citadel/crew_objectives/cit_crewobjectives_security.dm index d0e2443591..a20e48a6a5 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_security.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_security.dm @@ -7,9 +7,9 @@ /datum/objective/crew/headofsecurity/datfukkendisk/check_completion() if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/headofsecurity/enjoyyourstay explanation_text = "Welcome to Space Station 13. Enjoy your stay." @@ -20,18 +20,12 @@ /datum/objective/crew/headofsecurity/enjoyyourstay/update_explanation_text() . = ..() - var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.") + var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.", "Security is a mission, not an intermission.") explanation_text = pick(edglines) /datum/objective/crew/headofsecurity/enjoyyourstay/check_completion() - explanation_text = "Enforce Space Law at all costs." - if(owner.current) - var/mob/living/carbon/human/H = owner.current - var/obj/item/card/id/theID = H.get_idcard() - if(istype(theID)) - if(!H.get_assignment() == "Head of Security") - return 0 - return 1 + explanation_text = "Enforce Space Law to the best of your ability." + return TRUE /datum/objective/crew/securityofficer/ @@ -44,18 +38,12 @@ /datum/objective/crew/securityofficer/enjoyyourstay/update_explanation_text() . = ..() - var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.") + var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.", "Security is a mission, not an intermission.") explanation_text = pick(edglines) /datum/objective/crew/securityofficer/enjoyyourstay/check_completion() - explanation_text = "Enforce Space Law at all costs." - if(owner.current) - var/mob/living/carbon/human/H = owner.current - var/obj/item/card/id/theID = H.get_idcard() - if(istype(theID)) - if(!H.get_assignment() == "Security Officer") - return 0 - return 1 + explanation_text = "Enforce Space Law to the best of your ability." + return TRUE /datum/objective/crew/warden/ @@ -68,18 +56,12 @@ /datum/objective/crew/warden/enjoyyourstay/update_explanation_text() . = ..() - var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.") + var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.", "Security is a mission, not an intermission.") explanation_text = pick(edglines) /datum/objective/crew/warden/enjoyyourstay/check_completion() - explanation_text = "Enforce Space Law at all costs." - if(owner.current) - var/mob/living/carbon/human/H = owner.current - var/obj/item/card/id/theID = H.get_idcard() - if(istype(theID)) - if(!H.get_assignment() == "Warden") - return 0 - return 1 + explanation_text = "Enforce Space Law to the best of your ability." + return TRUE /datum/objective/crew/detective/ @@ -92,18 +74,12 @@ /datum/objective/crew/detective/enjoyyourstay/update_explanation_text() . = ..() - var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.", "Well, at least you know fashion.") + var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.", "Security is a mission, not an intermission.", "Well, at least you know fashion.") explanation_text = pick(edglines) /datum/objective/crew/detective/enjoyyourstay/check_completion() - explanation_text = "Enforce Space Law at all costs." - if(owner.current) - var/mob/living/carbon/human/H = owner.current - var/obj/item/card/id/theID = H.get_idcard() - if(istype(theID)) - if(!H.get_assignment() == "Detective") - return 0 - return 1 + explanation_text = "Enforce Space Law to the best of your ability." + return TRUE /datum/objective/crew/lawyer/ @@ -115,5 +91,5 @@ for(var/datum/mind/M in SSticker.minds) if(M.current && isliving(M.current)) if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) - return 0 - return 1 + return FALSE + return TRUE From a10f27ff144bfda15b5d6c088d61f3ca5cbd01c4 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Sat, 16 Sep 2017 23:44:39 -0400 Subject: [PATCH 088/120] runtime nerfs --- .../cit_crewobjectives_cargo.dm | 18 +++++++++--------- .../cit_crewobjectives_civilian.dm | 6 +++--- .../cit_crewobjectives_medical.dm | 8 ++++---- 3 files changed, 16 insertions(+), 16 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm index bb3ef8b630..aa2190e619 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm @@ -17,12 +17,12 @@ /datum/objective/crew/quartermaster/petsplosion/check_completion() var/petcount = target_amount for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) - if(!P.stat == DEAD) - if(P.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) + if!(P.stat == DEAD) + if(P.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(P)]) petcount-- for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(!H.stat == DEAD) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if!(H.stat == DEAD) + if(H.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) petcount-- if(petcount <= 0) @@ -47,12 +47,12 @@ /datum/objective/crew/cargotechnician/petsplosion/check_completion() var/petcount = target_amount for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) - if(!P.stat == DEAD) - if(P.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(P)]) + if!(P.stat == DEAD) + if(P.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(P)]) petcount-- for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(!H.stat == DEAD) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if!(H.stat == DEAD) + if(H.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) petcount-- if(petcount <= 0) @@ -67,6 +67,6 @@ /datum/objective/crew/shaftminer/bubblegum/check_completion() for(var/mob/living/simple_animal/hostile/megafauna/bubblegum/B in GLOB.mob_list) - if(!B.stat == DEAD) + if!(B.stat == DEAD) return FALSE return TRUE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 500196bf98..69307ed7f7 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -68,7 +68,7 @@ /datum/objective/crew/bartender/responsibility/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.drunkenness >= 80) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if(H.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(H)]) return FALSE return TRUE @@ -76,13 +76,13 @@ /datum/objective/crew/janitor/clean //ported from old Hippie var/list/areas = list() - var/hardmode = 0 + var/hardmode = FALSE explanation_text = "Ensure sure that (Yo, something broke. Yell about this in citadels devlopmeent discussion channel.) remain spotless at the end of the shift." /datum/objective/crew/janitor/clean/New() . = ..() if(prob(1)) - hardmode = 1 + hardmode = TRUE var/list/blacklistnormal = list(typesof(/area/space) - typesof(/area/lavaland) - typesof(/area/mine) - typesof(/area/ai_monitored/turret_protected) - typesof(/area/tcommsat)) var/list/blacklisthard = list(typesof(/area/lavaland) - typesof(/area/mine)) var/list/possibleareas = list() diff --git a/code/citadel/crew_objectives/cit_crewobjectives_medical.dm b/code/citadel/crew_objectives/cit_crewobjectives_medical.dm index ec4228cc27..4147884b09 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_medical.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_medical.dm @@ -7,7 +7,7 @@ /datum/objective/crew/chiefmedicalofficer/morgue/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(H.stat == DEAD && H.z == ZLEVEL_STATION) + if(H.stat == DEAD && H.z == ZLEVEL_STATION_PRIMARY) if(get_area(H) != /area/medical/morgue) return FALSE return TRUE @@ -46,7 +46,7 @@ /datum/objective/crew/geneticist/morgue/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(H.stat == DEAD && H.z == ZLEVEL_STATION) + if(H.stat == DEAD && H.z == ZLEVEL_STATION_PRIMARY) if(get_area(H) != /area/medical/morgue) return FALSE return TRUE @@ -119,7 +119,7 @@ /datum/objective/crew/virologist/noinfections/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) if(!H.stat == DEAD) - if(H.z == ZLEVEL_STATION || SSshuttle.emergency.shuttle_areas[get_area(H)]) + if(H.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(H.check_virus() == 2) return FALSE return TRUE @@ -131,7 +131,7 @@ /datum/objective/crew/medicaldoctor/morgue/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(H.stat == DEAD && H.z == ZLEVEL_STATION) + if(H.stat == DEAD && H.z == ZLEVEL_STATION_PRIMARY) if(get_area(H) != /area/medical/morgue) return FALSE return TRUE From e8c7cb4f518a1acaaad3644e280ffc6f87bcfd5a Mon Sep 17 00:00:00 2001 From: deathride58 Date: Sun, 17 Sep 2017 00:35:03 -0400 Subject: [PATCH 089/120] there we go --- .../crew_objectives/cit_crewobjectives_cargo.dm | 10 +++++----- .../crew_objectives/cit_crewobjectives_science.dm | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm index aa2190e619..1215d0ce14 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm @@ -17,11 +17,11 @@ /datum/objective/crew/quartermaster/petsplosion/check_completion() var/petcount = target_amount for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) - if!(P.stat == DEAD) + if !(P.stat == DEAD) if(P.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(P)]) petcount-- for(var/mob/living/carbon/human/H in GLOB.mob_list) - if!(H.stat == DEAD) + if !(H.stat == DEAD) if(H.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) petcount-- @@ -47,11 +47,11 @@ /datum/objective/crew/cargotechnician/petsplosion/check_completion() var/petcount = target_amount for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) - if!(P.stat == DEAD) + if !(P.stat == DEAD) if(P.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(P)]) petcount-- for(var/mob/living/carbon/human/H in GLOB.mob_list) - if!(H.stat == DEAD) + if !(H.stat == DEAD) if(H.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) petcount-- @@ -67,6 +67,6 @@ /datum/objective/crew/shaftminer/bubblegum/check_completion() for(var/mob/living/simple_animal/hostile/megafauna/bubblegum/B in GLOB.mob_list) - if!(B.stat == DEAD) + if !(B.stat == DEAD) return FALSE return TRUE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_science.dm b/code/citadel/crew_objectives/cit_crewobjectives_science.dm index addca3dbbf..2aaa47928e 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_science.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_science.dm @@ -17,7 +17,7 @@ /datum/objective/crew/researchdirector/cyborgs/check_completion() var/borgcount = target_amount for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) - if(!R.stat == DEAD) + if !(R.stat == DEAD) borgcount-- if(borgcount <= 0) return TRUE @@ -41,7 +41,7 @@ /datum/objective/crew/roboticist/cyborgs/check_completion() var/borgcount = target_amount for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) - if(!R.stat == DEAD) + if !(R.stat == DEAD) borgcount-- if(borgcount <= 0) return TRUE From e20d45f3d51b8b5f0fafb53d3ff88d7028629be6 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Sun, 17 Sep 2017 00:47:14 -0400 Subject: [PATCH 090/120] how is this intuitive in any way, shape, or form --- .../crew_objectives/cit_crewobjectives_cargo.dm | 10 +++++----- .../crew_objectives/cit_crewobjectives_science.dm | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm index 1215d0ce14..e82a001883 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm @@ -17,11 +17,11 @@ /datum/objective/crew/quartermaster/petsplosion/check_completion() var/petcount = target_amount for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) - if !(P.stat == DEAD) + !(P.stat == DEAD) if(P.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(P)]) petcount-- for(var/mob/living/carbon/human/H in GLOB.mob_list) - if !(H.stat == DEAD) + !(H.stat == DEAD) if(H.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) petcount-- @@ -47,11 +47,11 @@ /datum/objective/crew/cargotechnician/petsplosion/check_completion() var/petcount = target_amount for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) - if !(P.stat == DEAD) + !(P.stat == DEAD) if(P.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(P)]) petcount-- for(var/mob/living/carbon/human/H in GLOB.mob_list) - if !(H.stat == DEAD) + !(H.stat == DEAD) if(H.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) petcount-- @@ -67,6 +67,6 @@ /datum/objective/crew/shaftminer/bubblegum/check_completion() for(var/mob/living/simple_animal/hostile/megafauna/bubblegum/B in GLOB.mob_list) - if !(B.stat == DEAD) + !(B.stat == DEAD) return FALSE return TRUE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_science.dm b/code/citadel/crew_objectives/cit_crewobjectives_science.dm index 2aaa47928e..5f7d6cbf7f 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_science.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_science.dm @@ -17,7 +17,7 @@ /datum/objective/crew/researchdirector/cyborgs/check_completion() var/borgcount = target_amount for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) - if !(R.stat == DEAD) + !(R.stat == DEAD) borgcount-- if(borgcount <= 0) return TRUE @@ -41,7 +41,7 @@ /datum/objective/crew/roboticist/cyborgs/check_completion() var/borgcount = target_amount for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) - if !(R.stat == DEAD) + !(R.stat == DEAD) borgcount-- if(borgcount <= 0) return TRUE From 428a416447dac3f90318bb61c74838de13829494 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Sun, 17 Sep 2017 01:10:12 -0400 Subject: [PATCH 091/120] friendly reminder that mekhi anderson belongs on the table --- .../crew_objectives/cit_crewobjectives_cargo.dm | 10 +++++----- .../crew_objectives/cit_crewobjectives_science.dm | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm index e82a001883..dac2e15435 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm @@ -17,11 +17,11 @@ /datum/objective/crew/quartermaster/petsplosion/check_completion() var/petcount = target_amount for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) - !(P.stat == DEAD) + if(!(P.stat == DEAD)) if(P.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(P)]) petcount-- for(var/mob/living/carbon/human/H in GLOB.mob_list) - !(H.stat == DEAD) + if(!(H.stat == DEAD)) if(H.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) petcount-- @@ -47,11 +47,11 @@ /datum/objective/crew/cargotechnician/petsplosion/check_completion() var/petcount = target_amount for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) - !(P.stat == DEAD) + if(!(P.stat == DEAD)) if(P.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(P)]) petcount-- for(var/mob/living/carbon/human/H in GLOB.mob_list) - !(H.stat == DEAD) + if(!(H.stat == DEAD)) if(H.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) petcount-- @@ -67,6 +67,6 @@ /datum/objective/crew/shaftminer/bubblegum/check_completion() for(var/mob/living/simple_animal/hostile/megafauna/bubblegum/B in GLOB.mob_list) - !(B.stat == DEAD) + if(!(B.stat == DEAD)) return FALSE return TRUE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_science.dm b/code/citadel/crew_objectives/cit_crewobjectives_science.dm index 5f7d6cbf7f..552414746f 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_science.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_science.dm @@ -17,7 +17,7 @@ /datum/objective/crew/researchdirector/cyborgs/check_completion() var/borgcount = target_amount for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) - !(R.stat == DEAD) + if(!(R.stat == DEAD)) borgcount-- if(borgcount <= 0) return TRUE @@ -41,7 +41,7 @@ /datum/objective/crew/roboticist/cyborgs/check_completion() var/borgcount = target_amount for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) - !(R.stat == DEAD) + if(!(R.stat == DEAD)) borgcount-- if(borgcount <= 0) return TRUE From d2ffa0def679a365bb09af16f99b918465ba3b05 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Sun, 17 Sep 2017 01:20:29 -0400 Subject: [PATCH 092/120] fixed. 100% fixed. i hope. --- code/citadel/crew_objectives/cit_crewobjectives_civilian.dm | 2 +- code/citadel/crew_objectives/cit_crewobjectives_engineering.dm | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 69307ed7f7..a3bc8e10df 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -221,6 +221,6 @@ var/mob/living/carbon/human/H = owner.current var/obj/item/card/id/theID = H.get_idcard() if(istype(theID)) - if(!H.get_assignment() == "Assistant" && !H.get_assignment() == "No id" && !H.get_assignment() == "No job") + if(!(H.get_assignment() == "Assistant") && !(H.get_assignment() == "No id") && !(H.get_assignment() == "No job")) return TRUE return FALSE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm index bb042f50aa..5c2f9bd03d 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm @@ -28,7 +28,7 @@ /datum/objective/crew/chiefengineer/poly/check_completion() for(var/mob/living/simple_animal/parrot/Poly/dumbbird in GLOB.mob_list) - if(!dumbbird.stat == DEAD && dumbbird.ears) + if(!(dumbbird.stat == DEAD) && dumbbird.ears) if(istype(dumbbird.ears, /obj/item/device/radio/headset)) return TRUE return FALSE From e0837a45b63b5f57154a76e2fb36984e67daead9 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 19 Sep 2017 20:29:03 -0400 Subject: [PATCH 093/120] basic config stuff --- code/citadel/cit_crewobjectives.dm | 5 +++-- code/controllers/configuration.dm | 10 ++++++++++ config/game_options.txt | 11 +++++++++++ 3 files changed, 24 insertions(+), 2 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index f40d1fff3c..849dcef544 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -1,9 +1,10 @@ /datum/controller/subsystem/ticker/proc/generate_crew_objectives() for(var/datum/mind/crewMind in SSticker.minds) - if(prob(10) && !issilicon(crewMind.current) && GLOB.master_mode != "extended")//extended is supposed to have less chaos + if(prob(10) && !issilicon(crewMind.current) && GLOB.miscreants_allowed) generate_miscreant_objectives(crewMind) else - generate_individual_objectives(crewMind) + if(config.allow_crew_objectives) + generate_individual_objectives(crewMind) return /datum/controller/subsystem/ticker/proc/generate_individual_objectives(var/datum/mind/crewMind) diff --git a/code/controllers/configuration.dm b/code/controllers/configuration.dm index d19484fd3f..43b7a2f258 100644 --- a/code/controllers/configuration.dm +++ b/code/controllers/configuration.dm @@ -286,6 +286,10 @@ GLOBAL_PROTECT(config_dir) var/debug_admin_hrefs = FALSE //turns off admin href token protection for debugging purposes + var/allow_crew_objectives = FALSE + var/allow_miscreants = FALSE + var/allow_extended_miscreants = FALSE + /datum/configuration/New() gamemode_cache = typecacheof(/datum/game_mode,TRUE) for(var/T in gamemode_cache) @@ -816,6 +820,12 @@ GLOBAL_PROTECT(config_dir) arrivals_shuttle_require_safe_latejoin = TRUE if("mice_roundstart") mice_roundstart = text2num(value) + if("allow_crew_objectives") + allow_crew_objectives = TRUE + if("allow_miscreants") + allow_miscreants = TRUE + if("allow_extended_miscreants") + allow_extended_miscreants = TRUE else WRITE_FILE(GLOB.config_error_log, "Unknown setting in configuration: '[name]'") else if(type == "policies") diff --git a/config/game_options.txt b/config/game_options.txt index bc178fcfcd..2f2f22165d 100644 --- a/config/game_options.txt +++ b/config/game_options.txt @@ -491,3 +491,14 @@ ARRIVALS_SHUTTLE_DOCK_WINDOW 55 MICE_ROUNDSTART 10 + +## CREW OBJECTIVES ## +## Comment to disable objectives for innocent crew members. +ALLOW_CREW_OBJECTIVES + +## MISCREANTS ## +## Comment to allow miscreants to spawn. Miscreants are a mini-antag with objectives that are not tracked. +ALLOW_MISCREANTS + +## Uncomment to let miscreants spawn during Extended. I hold no responsibility for fun that may occur while this is enabled. +#ALLOW_EXTENDED_MISCREANTS \ No newline at end of file From fac0e751036bf240323eb8042844eda1561ec05c Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 19 Sep 2017 20:49:42 -0400 Subject: [PATCH 094/120] blegh --- code/citadel/_cit_helpers.dm | 3 +++ code/citadel/cit_crewobjectives.dm | 5 ++++- code/citadel/cit_miscreants.dm | 11 +++++++---- code/controllers/subsystem/ticker.dm | 4 ++++ 4 files changed, 18 insertions(+), 5 deletions(-) diff --git a/code/citadel/_cit_helpers.dm b/code/citadel/_cit_helpers.dm index f20e59b0b6..9ac58122fe 100644 --- a/code/citadel/_cit_helpers.dm +++ b/code/citadel/_cit_helpers.dm @@ -93,6 +93,9 @@ GLOBAL_LIST_EMPTY(mentors) GLOBAL_VAR_INIT(looc_allowed, 1) GLOBAL_VAR_INIT(dlooc_allowed, 1) +//Crew objective and miscreants stuff +GLOBAL_VAR_INIT(miscreants_allowed, FALSE) + /client/proc/reload_mentors() set name = "Reload Mentors" set category = "Admin" diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 849dcef544..7a4e68850b 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -8,6 +8,8 @@ return /datum/controller/subsystem/ticker/proc/generate_individual_objectives(var/datum/mind/crewMind) + if(!config.allow_crew_objectives) + return if(!crewMind) return if(!crewMind.current || !crewMind.objectives || crewMind.special_role) @@ -27,7 +29,8 @@ return newObjective.owner = crewMind crewMind.objectives += newObjective - crewMind.announce_objectives() + to_chat(crewMind, "Your objective: [newObjective.explanation_text]") + //crewMind.announce_objectives() /datum/objective/crew/ explanation_text = "Yell on the development discussion channel on Citadels discord if this ever shows up. Something just broke here, dude" diff --git a/code/citadel/cit_miscreants.dm b/code/citadel/cit_miscreants.dm index 19e75047f5..cc5a3afa98 100644 --- a/code/citadel/cit_miscreants.dm +++ b/code/citadel/cit_miscreants.dm @@ -1,12 +1,14 @@ /datum/controller/subsystem/ticker/proc/generate_miscreant_objectives(var/datum/mind/crewMind) - if(GLOB.master_mode == "extended") - return //Thinking about it, extended's chaos whether or not mini-antags are present. But eh, whatever. Here's a sanity check. + if(!GLOB.miscreants_allowed) + return if(!crewMind) return if(!crewMind.current || !crewMind.objectives || crewMind.special_role) return if(!crewMind.assigned_role) return + if(jobban_isbanned(crewMind, "Syndicate")) + return var/list/objectiveTypes = typesof(/datum/objective/miscreant) - /datum/objective/miscreant if(!objectiveTypes.len) return @@ -18,8 +20,9 @@ crewMind.objectives += newObjective crewMind.special_role = "miscreant" to_chat(crewMind, "You are a Miscreant.") - to_chat(crewMind, "Pursuing your objective is entirely optional, but it isn't tracked. Performing traitorous acts not directly related to your objective may result in permanent termination of your employment.") - crewMind.announce_objectives() + to_chat(crewMind, "Pursuing your objective is entirely optional, but it isn't tracked. Performing traitorous acts not directly related to your objective may result in permanent termination of your employment.") + to_chat(crewMind, "Your objective: [newObjective.explanation_text]") + //crewMind.announce_objectives() /datum/objective/miscreant explanation_text = "Something broke. Horribly. Dear god, im so sorry. Yell about this in the development discussion channel of citadels discord." diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index 6d458cb0ee..cee83cb3b8 100755 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -211,6 +211,10 @@ SUBSYSTEM_DEF(ticker) GLOB.start_landmarks_list = shuffle(GLOB.start_landmarks_list) //Shuffle the order of spawn points so they dont always predictably spawn bottom-up and right-to-left create_characters() //Create player characters collect_minds() + if(config.allow_extended_miscreants && GLOB.master_mode == "extended") + GLOB.miscreants_allowed = TRUE + if(config.allow_miscreants && GLOB.master_mode != "extended") + GLOB.miscreants_allowed = TRUE generate_crew_objectives() equip_characters() From 5f65202cfd0fb36f78e2adb661f0ef72b3940706 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 19 Sep 2017 20:56:16 -0400 Subject: [PATCH 095/120] added config option to enable or disable miscreants and crew objectives --- code/citadel/cit_crewobjectives.dm | 2 +- code/modules/mob/dead/new_player/new_player.dm | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 7a4e68850b..172f1b59d3 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -1,6 +1,6 @@ /datum/controller/subsystem/ticker/proc/generate_crew_objectives() for(var/datum/mind/crewMind in SSticker.minds) - if(prob(10) && !issilicon(crewMind.current) && GLOB.miscreants_allowed) + if(prob(10) && !issilicon(crewMind.current) && !jobban_isbanned(crewMind, "Syndicate") && GLOB.miscreants_allowed) generate_miscreant_objectives(crewMind) else if(config.allow_crew_objectives) diff --git a/code/modules/mob/dead/new_player/new_player.dm b/code/modules/mob/dead/new_player/new_player.dm index 349ee546a4..bf8836fb72 100644 --- a/code/modules/mob/dead/new_player/new_player.dm +++ b/code/modules/mob/dead/new_player/new_player.dm @@ -367,10 +367,11 @@ if(GLOB.highlander) to_chat(humanc, "THERE CAN BE ONLY ONE!!!") humanc.make_scottish() - if(prob(10) && !issilicon(humanc) && GLOB.master_mode != "extended") + if(prob(10) && !issilicon(humanc) && !jobban_isbanned(humanc.mind, "Syndicate") && GLOB.miscreants_allowed) SSticker.generate_miscreant_objectives(humanc.mind) else - SSticker.generate_individual_objectives(humanc.mind) + if(config.allow_crew_objectives) + SSticker.generate_individual_objectives(humanc.mind) GLOB.joined_player_list += character.ckey GLOB.latejoiners += character From 2c528bb0e36793aaca5c4308dbfb0224a0fee651 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 19 Sep 2017 21:11:25 -0400 Subject: [PATCH 096/120] removes some of the more tide-y objectives, cleans comments --- code/citadel/cit_crewobjectives.dm | 1 - code/citadel/cit_miscreants.dm | 7 ------- 2 files changed, 8 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 172f1b59d3..6b620215b4 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -30,7 +30,6 @@ newObjective.owner = crewMind crewMind.objectives += newObjective to_chat(crewMind, "Your objective: [newObjective.explanation_text]") - //crewMind.announce_objectives() /datum/objective/crew/ explanation_text = "Yell on the development discussion channel on Citadels discord if this ever shows up. Something just broke here, dude" diff --git a/code/citadel/cit_miscreants.dm b/code/citadel/cit_miscreants.dm index cc5a3afa98..f33f6815af 100644 --- a/code/citadel/cit_miscreants.dm +++ b/code/citadel/cit_miscreants.dm @@ -22,7 +22,6 @@ to_chat(crewMind, "You are a Miscreant.") to_chat(crewMind, "Pursuing your objective is entirely optional, but it isn't tracked. Performing traitorous acts not directly related to your objective may result in permanent termination of your employment.") to_chat(crewMind, "Your objective: [newObjective.explanation_text]") - //crewMind.announce_objectives() /datum/objective/miscreant explanation_text = "Something broke. Horribly. Dear god, im so sorry. Yell about this in the development discussion channel of citadels discord." @@ -35,9 +34,6 @@ /datum/objective/miscreant/incompetent explanation_text = "Be as useless and incompetent as possible without getting killed." -/datum/objective/miscreant/strike - explanation_text = "Try to convince your department to go on strike, and refuse to do any work." - /datum/objective/miscreant/litterbug explanation_text = "Make a huge mess wherever you go." @@ -56,9 +52,6 @@ /datum/objective/miscreant/whiny explanation_text = "Complain incessantly about every minor issue you find." -/datum/objective/miscreant/damage - explanation_text = "Cause as much property damage as possible without actually harming anyone." - /* Citadel's Miscreant Objectives */ /datum/objective/miscreant/immersions From f2b63c11595c45b03e695f0f3ed78df79bfd3317 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 19 Sep 2017 22:33:00 -0400 Subject: [PATCH 097/120] *foaming at mouth in far distance* --- .../crew_objectives/cit_crewobjectives_civilian.dm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index a3bc8e10df..61f4c4efe9 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -166,10 +166,10 @@ /datum/objective/crew/assistant/departmentclothes/update_explanation_text() . = ..() - explanation_text = "Be wearing a [targetuniform] at the end of the shift." + explanation_text = "Be wearing a [initial(targetuniform.name)] at the end of the shift." /datum/objective/crew/assistant/departmentclothes/check_completion() - if(owner.current) + if(owner && owner.current) var/mob/living/carbon/human/H = owner.current if(istype(H.w_uniform, targetuniform)) return TRUE @@ -184,7 +184,7 @@ /datum/objective/crew/assistant/spacesuit/update_explanation_text() . = ..() - if(owner.current) + if(owner && owner.current) var/mob/living/carbon/human/H = owner.current explanation_text = "Get your " if(H.dna.species.id == "avian") @@ -217,7 +217,7 @@ explanation_text = "Have a non-assistant ID registered to you at the end of the shift." /datum/objective/crew/assistant/promotion/check_completion() - if(owner.current) + if(owner && owner.current) var/mob/living/carbon/human/H = owner.current var/obj/item/card/id/theID = H.get_idcard() if(istype(theID)) From ba05e177fd813a5a6976ceeebbcdb20699ccd851 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 19 Sep 2017 22:53:47 -0400 Subject: [PATCH 098/120] ffs work already --- .../cit_crewobjectives_civilian.dm | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 61f4c4efe9..7caaffcde4 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -187,21 +187,21 @@ if(owner && owner.current) var/mob/living/carbon/human/H = owner.current explanation_text = "Get your " - if(H.dna.species.id == "avian") + if(H.dna.species == /datum/species/avian) explanation_text += "scratchy claws " - else if(H.dna.species.id == "mammal") + else if(H.dna.species == /datum/species/mammal) explanation_text += "dirty paws " - else if(H.dna.species.id == "aquatic") + else if(H.dna.species == /datum/species/aquatic) explanation_text += "fishy hands " - else if(H.dna.species.id == "xeno") + else if(H.dna.species == /datum/species/xeno) explanation_text += "weird claws " - else if(H.dna.species.id == "guilmon") + else if(H.dna.species == /datum/species/guilmon) explanation_text += "digital claws " - else if(H.dna.species.id == "lizard") + else if(H.dna.species == /datum/species/lizard) explanation_text += "slimy claws " - else if(H.dna.species.id == "datashark") + else if(H.dna.species == /datum/species/datashark) explanation_text += "glitchy hands " - else if(H.dna.species.id == "insect") + else if(H.dna.species == /datum/species/insect) explanation_text += "gross grabbers " else explanation_text += "grubby hands " From f69ab93a2c4ecb9b8c76241d756938f95508f21a Mon Sep 17 00:00:00 2001 From: deathride58 Date: Tue, 19 Sep 2017 23:31:08 -0400 Subject: [PATCH 099/120] theres a proc for that --- .../cit_crewobjectives_civilian.dm | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 7caaffcde4..1da2294a70 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -187,21 +187,21 @@ if(owner && owner.current) var/mob/living/carbon/human/H = owner.current explanation_text = "Get your " - if(H.dna.species == /datum/species/avian) + if(is_species(H, /datum/species/avian)) explanation_text += "scratchy claws " - else if(H.dna.species == /datum/species/mammal) + else if(is_species(H, /datum/species/mammal)) explanation_text += "dirty paws " - else if(H.dna.species == /datum/species/aquatic) + else if(is_species(H, /datum/species/aquatic)) explanation_text += "fishy hands " - else if(H.dna.species == /datum/species/xeno) + else if(is_species(H, /datum/species/xeno)) explanation_text += "weird claws " - else if(H.dna.species == /datum/species/guilmon) + else if(is_species(H, /datum/species/guilmon)) explanation_text += "digital claws " - else if(H.dna.species == /datum/species/lizard) + else if(is_species(H, /datum/species/lizard)) explanation_text += "slimy claws " - else if(H.dna.species == /datum/species/datashark) + else if(is_species(H, /datum/species/shark/datashark)) explanation_text += "glitchy hands " - else if(H.dna.species == /datum/species/insect) + else if(is_species(H, /datum/species/insect)) explanation_text += "gross grabbers " else explanation_text += "grubby hands " From fb7f2d0ab89f2361c92d40e865ffb37f5fc7c7e4 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 20 Sep 2017 16:03:56 -0400 Subject: [PATCH 100/120] fixes all the roundstart related issues --- code/controllers/subsystem/ticker.dm | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index cee83cb3b8..94d4d90d23 100755 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -211,11 +211,6 @@ SUBSYSTEM_DEF(ticker) GLOB.start_landmarks_list = shuffle(GLOB.start_landmarks_list) //Shuffle the order of spawn points so they dont always predictably spawn bottom-up and right-to-left create_characters() //Create player characters collect_minds() - if(config.allow_extended_miscreants && GLOB.master_mode == "extended") - GLOB.miscreants_allowed = TRUE - if(config.allow_miscreants && GLOB.master_mode != "extended") - GLOB.miscreants_allowed = TRUE - generate_crew_objectives() equip_characters() SSoverlays.Flush() //Flush the majority of the shit @@ -258,6 +253,13 @@ SUBSYSTEM_DEF(ticker) //Deleting Startpoints but we need the ai point to AI-ize people later if(S.name != "AI") qdel(S) + + //assign crew objectives and generate miscreants + if(config.allow_extended_miscreants && GLOB.master_mode == "extended") + GLOB.miscreants_allowed = TRUE + if(config.allow_miscreants && GLOB.master_mode != "extended") + GLOB.miscreants_allowed = TRUE + generate_crew_objectives() var/list/adm = get_admin_counts() var/list/allmins = adm["present"] From 4473b24180a37c098e2d1d8bdb2b67fdaad8db30 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 20 Sep 2017 21:58:42 -0400 Subject: [PATCH 101/120] work dammit --- .../cit_crewobjectives_civilian.dm | 41 ++++++++++--------- 1 file changed, 21 insertions(+), 20 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 1da2294a70..92779c573f 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -186,26 +186,27 @@ . = ..() if(owner && owner.current) var/mob/living/carbon/human/H = owner.current - explanation_text = "Get your " - if(is_species(H, /datum/species/avian)) - explanation_text += "scratchy claws " - else if(is_species(H, /datum/species/mammal)) - explanation_text += "dirty paws " - else if(is_species(H, /datum/species/aquatic)) - explanation_text += "fishy hands " - else if(is_species(H, /datum/species/xeno)) - explanation_text += "weird claws " - else if(is_species(H, /datum/species/guilmon)) - explanation_text += "digital claws " - else if(is_species(H, /datum/species/lizard)) - explanation_text += "slimy claws " - else if(is_species(H, /datum/species/shark/datashark)) - explanation_text += "glitchy hands " - else if(is_species(H, /datum/species/insect)) - explanation_text += "gross grabbers " - else - explanation_text += "grubby hands " - explanation_text += "on a space suit." + if(H && H.dna && H.dna.species) + explanation_text = "Get your " + if(H.dna.species == /datum/species/avian) + explanation_text += "scratchy claws " + else if(H.dna.species == /datum/species/mammal) + explanation_text += "dirty paws " + else if(H.dna.species == /datum/species/aquatic) + explanation_text += "fishy hands " + else if(H.dna.species == /datum/species/xeno) + explanation_text += "weird claws " + else if(H.dna.species == /datum/species/guilmon) + explanation_text += "digital claws " + else if(H.dna.species == /datum/species/lizard) + explanation_text += "slimy claws " + else if(H.dna.species == /datum/species/shark/datashark) + explanation_text += "glitchy hands " + else if(H.dna.species == /datum/species/insect) + explanation_text += "gross grabbers " + else + explanation_text += "grubby hands " + explanation_text += "on a space suit." /datum/objective/crew/assistant/spacesuit/check_completion() if(owner.current && owner.current.check_contents_for(typesof(/obj/item/clothing/suit/space))) From b55ad7383ea4b7d00a317a56bbb5f65dcea6b787 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 21 Sep 2017 00:14:03 -0400 Subject: [PATCH 102/120] i give up --- .../cit_crewobjectives_civilian.dm | 21 ++++++++++--------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 92779c573f..922430fd62 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -178,6 +178,7 @@ /datum/objective/crew/assistant/spacesuit //ported from Goon explanation_text = "Get your grubby hands on a space suit." +/* DM is not a sane language in any way, shape, or form. If anyone wants to try to get this bit functioning proper, I hold no responsibility for broken keyboards. /datum/objective/crew/assistant/spacesuit/New() . = ..() update_explanation_text() @@ -186,27 +187,27 @@ . = ..() if(owner && owner.current) var/mob/living/carbon/human/H = owner.current - if(H && H.dna && H.dna.species) + if(H && H.dna && H.dna.species && H.dna.species.id) explanation_text = "Get your " - if(H.dna.species == /datum/species/avian) + if(H.dna.species.id == "avian") explanation_text += "scratchy claws " - else if(H.dna.species == /datum/species/mammal) + else if(H.dna.species.id == "mammal") explanation_text += "dirty paws " - else if(H.dna.species == /datum/species/aquatic) + else if(H.dna.species.id == "aquatic") explanation_text += "fishy hands " - else if(H.dna.species == /datum/species/xeno) + else if(H.dna.species.id == "xeno") explanation_text += "weird claws " - else if(H.dna.species == /datum/species/guilmon) + else if(H.dna.species.id == "guilmon") explanation_text += "digital claws " - else if(H.dna.species == /datum/species/lizard) + else if(H.dna.species.id == "lizard") explanation_text += "slimy claws " - else if(H.dna.species == /datum/species/shark/datashark) + else if(H.dna.species.id == "datashark") explanation_text += "glitchy hands " - else if(H.dna.species == /datum/species/insect) + else if(H.dna.species.id == "insect") explanation_text += "gross grabbers " else explanation_text += "grubby hands " - explanation_text += "on a space suit." + explanation_text += "on a space suit."*/ /datum/objective/crew/assistant/spacesuit/check_completion() if(owner.current && owner.current.check_contents_for(typesof(/obj/item/clothing/suit/space))) From 160246396eee40a27459bd4699ca9cad0e90a49f Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 21 Sep 2017 00:57:51 -0400 Subject: [PATCH 103/120] spacesuit objective rebrand --- .../cit_crewobjectives_civilian.dm | 20 +++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 922430fd62..ddcb20dfce 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -175,16 +175,20 @@ return TRUE return FALSE -/datum/objective/crew/assistant/spacesuit //ported from Goon - explanation_text = "Get your grubby hands on a space suit." +/datum/objective/crew/assistant/pwrgame //ported from Goon + var/obj/item/clothing/targettidegarb + explanation_text = "Get your grubby hands on a [Dear god something broke. Report this to Citadel's development dicussion channel]." -/* DM is not a sane language in any way, shape, or form. If anyone wants to try to get this bit functioning proper, I hold no responsibility for broken keyboards. -/datum/objective/crew/assistant/spacesuit/New() +/datum/objective/crew/assistant/pwrgame/New() . = ..() + var/list/muhvalids = list(/obj/item/clothing/mask/gas, /obj/item/clothing/head/welding, /obj/item/clothing/head/ushanka, /obj/item/clothing/gloves/color/yellow, /obj/item/clothing/mask/gas/owl_mask, /obj/item/clothing/suit/space) + targettidegarb = pick(muhvalids) update_explanation_text() -/datum/objective/crew/assistant/spacesuit/update_explanation_text() +/datum/objective/crew/assistant/pwrgame/update_explanation_text() . = ..() + explanation_text = "Get your grubby hands on a [initial(targettidegarb.name)]." +/* DM is not a sane language in any way, shape, or form. If anyone wants to try to get this bit functioning proper, I hold no responsibility for broken keyboards. if(owner && owner.current) var/mob/living/carbon/human/H = owner.current if(H && H.dna && H.dna.species && H.dna.species.id) @@ -207,10 +211,10 @@ explanation_text += "gross grabbers " else explanation_text += "grubby hands " - explanation_text += "on a space suit."*/ + explanation_text += "on a space suit."//replace this if you're making this monstrosity work */ -/datum/objective/crew/assistant/spacesuit/check_completion() - if(owner.current && owner.current.check_contents_for(typesof(/obj/item/clothing/suit/space))) +/datum/objective/crew/assistant/pwrgame/check_completion() + if(owner.current && owner.current.check_contents_for(typesof(targettidegarb))) return TRUE else return FALSE From 7e1d0afac793c1aeb0baa67ac77b2c5506aaff66 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Sat, 23 Sep 2017 01:40:47 -0400 Subject: [PATCH 104/120] fixes runtimes --- code/citadel/crew_objectives/cit_crewobjectives_civilian.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index ddcb20dfce..ca884977b9 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -177,7 +177,7 @@ /datum/objective/crew/assistant/pwrgame //ported from Goon var/obj/item/clothing/targettidegarb - explanation_text = "Get your grubby hands on a [Dear god something broke. Report this to Citadel's development dicussion channel]." + explanation_text = "Get your grubby hands on a (Dear god something broke. Report this to Citadel's development dicussion channel)." /datum/objective/crew/assistant/pwrgame/New() . = ..() @@ -211,7 +211,7 @@ explanation_text += "gross grabbers " else explanation_text += "grubby hands " - explanation_text += "on a space suit."//replace this if you're making this monstrosity work */ + explanation_text += "on a space suit." replace this if you're making this monstrosity work */ /datum/objective/crew/assistant/pwrgame/check_completion() if(owner.current && owner.current.check_contents_for(typesof(targettidegarb))) From 43574eefe11b73eea42b93c4e84bdded00e59121 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 28 Sep 2017 00:30:38 -0400 Subject: [PATCH 105/120] adds chaplain and curator objectives --- .../cit_crewobjectives_civilian.dm | 57 ++++++++++++++++++- 1 file changed, 55 insertions(+), 2 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index ca884977b9..94ac116446 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -130,7 +130,7 @@ /datum/objective/crew/clown/slipster/check_completion() var/list/uniqueslips = list() - if(owner.current) + if(owner && owner.current) for(var/obj/item/device/pda/clown/PDA in owner.current.get_contents()) for(var/mob/living/carbon/human/H in PDA.slipvictims) uniqueslips |= H @@ -145,12 +145,65 @@ explanation_text = "Never break your vow of silence." /datum/objective/crew/mime/vow/check_completion() - if(owner.current) + if(owner && owner.current) var/list/say_log = owner.current.logging[INDIVIDUAL_SAY_LOG] if(say_log.len > 0) return FALSE return TRUE +/datum/objective/crew/chaplain + +/datum/objective/crew/chaplain/nullrod + explanation_text = "Don't lose your holy rod." + +/datum/objective/crew/chaplain/nullrod/New() + . = ..() + update_explanation_text() + +/datum/objective/crew/chaplain/nullrod/update_explanation_text() + . = ..() + explanation_text = "Don't lose your holy rod." + if(owner && owner.current) + if(owner.current.getorgan(/obj/item/organ/genital/penis)) + explanation_text += " Interpret this as you wish." + +/datum/objective/crew/chaplain/nullrod/check_completion() + explanation_text = "Don't lose your holy rod." + if(owner && owner.current) + if(owner.current.check_contents_for(typesof(/obj/item/nullrod))) + return 1 + if(owner.current.getorgan(/obj/item/organ/genital/penis)) + return 1 + return 0 + +/datum/objective/crew/curator + +/datum/objective/crew/curator/reporter //ported from old hippie + var/charcount = 100 + explanation_text = "Write at least (Yo something broke) articles containing at least (Report this to Citadels development channel) characters." + +/datum/objective/crew/curator/reporter/New() + . = ..() + target_amount = rand(2,10) + charcount = rand(20,250) + update_explanation_text() + +/datum/objective/crew/curator/reporter/update_explanation_text() + . = ..() + explanation_text = "Write at least [target_amount] articles containing at least [charcount] characters." + +/datum/objective/crew/curator/reporter/check_completion() + if(owner && owner.current) + for(var/datum/newscaster/feed_channel/chan in GLOB.news_network.network_channels) + for(var/datum/newscaster/feed_message/msg in chan.messages) + if(msg.returnAuthor() == owner.current.real_name) + if(length(msg.returnBody()) >= charcount) + target_amount-- + if(target_amount <= 0) + return 1 + else + return 0 + /datum/objective/crew/assistant /datum/objective/crew/assistant/departmentclothes From 226ad9ddde38cd9ebaf9457f2e60c5e4c8b340cb Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 28 Sep 2017 01:10:42 -0400 Subject: [PATCH 106/120] adjustments --- code/citadel/cit_crewobjectives.dm | 2 +- code/citadel/cit_miscreants.dm | 2 +- .../cit_crewobjectives_civilian.dm | 10 +++++----- code/controllers/subsystem/ticker.dm | 16 ++++++++-------- code/modules/mob/dead/new_player/new_player.dm | 2 +- 5 files changed, 16 insertions(+), 16 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 6b620215b4..73e6787334 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -1,6 +1,6 @@ /datum/controller/subsystem/ticker/proc/generate_crew_objectives() for(var/datum/mind/crewMind in SSticker.minds) - if(prob(10) && !issilicon(crewMind.current) && !jobban_isbanned(crewMind, "Syndicate") && GLOB.miscreants_allowed) + if(prob(2) && !issilicon(crewMind.current) && !jobban_isbanned(crewMind, "Syndicate") && GLOB.miscreants_allowed) generate_miscreant_objectives(crewMind) else if(config.allow_crew_objectives) diff --git a/code/citadel/cit_miscreants.dm b/code/citadel/cit_miscreants.dm index f33f6815af..f828127b55 100644 --- a/code/citadel/cit_miscreants.dm +++ b/code/citadel/cit_miscreants.dm @@ -20,7 +20,7 @@ crewMind.objectives += newObjective crewMind.special_role = "miscreant" to_chat(crewMind, "You are a Miscreant.") - to_chat(crewMind, "Pursuing your objective is entirely optional, but it isn't tracked. Performing traitorous acts not directly related to your objective may result in permanent termination of your employment.") + to_chat(crewMind, "Pursuing your objective is entirely optional, as the completion of your objective is unable to be tracked. Performing traitorous acts not directly related to your objective may result in permanent termination of your employment.") to_chat(crewMind, "Your objective: [newObjective.explanation_text]") /datum/objective/miscreant diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 94ac116446..3b81007a17 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -171,10 +171,10 @@ explanation_text = "Don't lose your holy rod." if(owner && owner.current) if(owner.current.check_contents_for(typesof(/obj/item/nullrod))) - return 1 + return TRUE if(owner.current.getorgan(/obj/item/organ/genital/penis)) - return 1 - return 0 + return TRUE + return FALSE /datum/objective/crew/curator @@ -200,9 +200,9 @@ if(length(msg.returnBody()) >= charcount) target_amount-- if(target_amount <= 0) - return 1 + return TRUE else - return 0 + return FALSE /datum/objective/crew/assistant diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index 82b91bfa67..db0ab6abda 100755 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -614,21 +614,21 @@ SUBSYSTEM_DEF(ticker) to_chat(crewMind.current, "
Your objective: [CO.explanation_text] Failed.") if (successfulCrew.len) - to_chat(world, "The following crew members completed their Crew Objectives:") + var/completedObjectives = "The following crew members completed their Crew Objectives:
" for(var/i in successfulCrew) - to_chat(world, "[i]") - to_chat(world, "
") + completedObjectives += "[i]
" + to_chat(world, "[completedObjectives]
") else - to_chat(world, "Nobody completed their Crew Objectives!") - to_chat(world, "
") + if(config.allow_crew_objectives) + to_chat(world, "Nobody completed their Crew Objectives!
") CHECK_TICK if (miscreants.len) - to_chat(world, " The following crew members were miscreants:") + var/miscreantObjectives = "The following crew members were miscreants:
" for(var/i in miscreants) - to_chat(world, "[i]") - to_chat(world, "
") + miscreantObjectives += "[i]
" + to_chat(world, "[miscreantObjectives]
") CHECK_TICK diff --git a/code/modules/mob/dead/new_player/new_player.dm b/code/modules/mob/dead/new_player/new_player.dm index 00f664b59c..ff6eadb42c 100644 --- a/code/modules/mob/dead/new_player/new_player.dm +++ b/code/modules/mob/dead/new_player/new_player.dm @@ -370,7 +370,7 @@ if(GLOB.highlander) to_chat(humanc, "THERE CAN BE ONLY ONE!!!") humanc.make_scottish() - if(prob(10) && !issilicon(humanc) && !jobban_isbanned(humanc.mind, "Syndicate") && GLOB.miscreants_allowed) + if(prob(2) && !issilicon(humanc) && !jobban_isbanned(humanc.mind, "Syndicate") && GLOB.miscreants_allowed) SSticker.generate_miscreant_objectives(humanc.mind) else if(config.allow_crew_objectives) From 3711461873ad67f66617a7ba843069671d1c25dd Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 28 Sep 2017 01:32:58 -0400 Subject: [PATCH 107/120] makes the nukedisk objective exclusive to captain --- .../crew_objectives/cit_crewobjectives_command.dm | 9 --------- .../crew_objectives/cit_crewobjectives_security.dm | 9 --------- 2 files changed, 18 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_command.dm b/code/citadel/crew_objectives/cit_crewobjectives_command.dm index 7ea715dfa8..1ee6beaee6 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_command.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_command.dm @@ -32,12 +32,3 @@ return TRUE return FALSE return FALSE - -/datum/objective/crew/headofpersonnel/datfukkendisk //Ported from old Hippie - explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." - -/datum/objective/crew/headofpersonnel/datfukkendisk/check_completion() - if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) - return TRUE - else - return FALSE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_security.dm b/code/citadel/crew_objectives/cit_crewobjectives_security.dm index a20e48a6a5..b0b9bb3b55 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_security.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_security.dm @@ -2,15 +2,6 @@ /datum/objective/crew/headofsecurity/ -/datum/objective/crew/headofsecurity/datfukkendisk //Ported from old Hippie - explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." - -/datum/objective/crew/headofsecurity/datfukkendisk/check_completion() - if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) - return TRUE - else - return FALSE - /datum/objective/crew/headofsecurity/enjoyyourstay explanation_text = "Welcome to Space Station 13. Enjoy your stay." From de15e8fa6be779cc581409575bc07b0c627afdb0 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 28 Sep 2017 19:08:35 -0400 Subject: [PATCH 108/120] Fixes reporter objective --- .../cit_crewobjectives_civilian.dm | 19 ++++--------------- 1 file changed, 4 insertions(+), 15 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 3b81007a17..f6defe3242 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -156,19 +156,7 @@ /datum/objective/crew/chaplain/nullrod explanation_text = "Don't lose your holy rod." -/datum/objective/crew/chaplain/nullrod/New() - . = ..() - update_explanation_text() - -/datum/objective/crew/chaplain/nullrod/update_explanation_text() - . = ..() - explanation_text = "Don't lose your holy rod." - if(owner && owner.current) - if(owner.current.getorgan(/obj/item/organ/genital/penis)) - explanation_text += " Interpret this as you wish." - /datum/objective/crew/chaplain/nullrod/check_completion() - explanation_text = "Don't lose your holy rod." if(owner && owner.current) if(owner.current.check_contents_for(typesof(/obj/item/nullrod))) return TRUE @@ -180,7 +168,7 @@ /datum/objective/crew/curator/reporter //ported from old hippie var/charcount = 100 - explanation_text = "Write at least (Yo something broke) articles containing at least (Report this to Citadels development channel) characters." + explanation_text = "Publish at least (Yo something broke) articles containing at least (Report this to Citadels development channel) characters." /datum/objective/crew/curator/reporter/New() . = ..() @@ -190,13 +178,14 @@ /datum/objective/crew/curator/reporter/update_explanation_text() . = ..() - explanation_text = "Write at least [target_amount] articles containing at least [charcount] characters." + explanation_text = "Publish at least [target_amount] articles containing at least [charcount] characters." /datum/objective/crew/curator/reporter/check_completion() if(owner && owner.current) + var/ownername = "[ckey(owner.current.real_name)][ckey(owner.assigned_role)]" for(var/datum/newscaster/feed_channel/chan in GLOB.news_network.network_channels) for(var/datum/newscaster/feed_message/msg in chan.messages) - if(msg.returnAuthor() == owner.current.real_name) + if(ckey(msg.returnAuthor()) == ckey(ownername)) if(length(msg.returnBody()) >= charcount) target_amount-- if(target_amount <= 0) From bf3644d64eca5ddfaabe15da6c76c70cf29fa9f4 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 28 Sep 2017 19:41:13 -0400 Subject: [PATCH 109/120] adds points objective for cargonians --- .../cit_crewobjectives_cargo.dm | 34 +++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm index dac2e15435..e396f57a9e 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm @@ -30,6 +30,23 @@ else return FALSE +/datum/objective/crew/quartermaster/points //ported from old hippie + explanation_text = "Make sure the station has at least (Something broke, report this to the development discussion channel of citadels discord) supply points at the end of the shift." + +/datum/objective/crew/quartermaster/points/New() + . = ..() + target_amount = rand(25000,100000) + update_explanation_text() + +/datum/objective/crew/quartermaster/points/update_explanation_text() + explanation_text = "Make sure the station has at least [target_amount] supply points at the end of the shift." + +/datum/objective/crew/quartermaster/points/check_completion() + if(SSshuttle.points >= target_amount) + return TRUE + else + return FALSE + /datum/objective/crew/cargotechnician /datum/objective/crew/cargotechnician/petsplosion @@ -60,6 +77,23 @@ else return FALSE +/datum/objective/crew/cargotechnician/points //ported from old hippie + explanation_text = "Make sure the station has at least (Something broke, report this to the development discussion channel of citadels discord) supply points at the end of the shift." + +/datum/objective/crew/cargotechnician/points/New() + . = ..() + target_amount = rand(25000,100000) + update_explanation_text() + +/datum/objective/crew/cargotechnician/points/update_explanation_text() + explanation_text = "Make sure the station has at least [target_amount] supply points at the end of the shift." + +/datum/objective/crew/cargotechnician/points/check_completion() + if(SSshuttle.points >= target_amount) + return TRUE + else + return FALSE + /datum/objective/crew/shaftminer /datum/objective/crew/shaftminer/bubblegum From 77048785cd5ebaa35d4e3f3d634bc42b8a275506 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 28 Sep 2017 19:53:11 -0400 Subject: [PATCH 110/120] gives miners a quest for fat stacks --- .../cit_crewobjectives_cargo.dm | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm index e396f57a9e..392ec3a7e1 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm @@ -39,6 +39,7 @@ update_explanation_text() /datum/objective/crew/quartermaster/points/update_explanation_text() + . = ..() explanation_text = "Make sure the station has at least [target_amount] supply points at the end of the shift." /datum/objective/crew/quartermaster/points/check_completion() @@ -86,6 +87,7 @@ update_explanation_text() /datum/objective/crew/cargotechnician/points/update_explanation_text() + . = ..() explanation_text = "Make sure the station has at least [target_amount] supply points at the end of the shift." /datum/objective/crew/cargotechnician/points/check_completion() @@ -104,3 +106,24 @@ if(!(B.stat == DEAD)) return FALSE return TRUE + +/datum/objective/crew/shaftminer/fatstacks //ported from old hippie + explanation_text = "Have at least (something broke, report this to the development discussion channel of citadels discord) mining points on your ID at the end of the shift." + +/datum/objective/crew/shaftminer/fatstacks/New() + . = ..() + target_amount = rand(15000,50000) + update_explanation_text() + +/datum/objective/crew/shaftminer/fatstacks/update_explanation_text() + . = ..() + explanation_text = "Have at least [target_amount] mining points on your ID at the end of the shift." + +/datum/objective/crew/shaftminer/fatstacks/check_completion() + if(owner && owner.current) + var/mob/living/carbon/human/H = owner.current + var/obj/item/card/id/theID = H.get_idcard() + if(istype(theID)) + if(theID.mining_points >= target_amount) + return TRUE + return FALSE From e81d692b8c88286f0cbe304e8db6af40653faaf1 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 28 Sep 2017 20:30:53 -0400 Subject: [PATCH 111/120] adds research objective for scientists --- .../cit_crewobjectives_science.dm | 42 +++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_science.dm b/code/citadel/crew_objectives/cit_crewobjectives_science.dm index 552414746f..d028a453bc 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_science.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_science.dm @@ -24,6 +24,48 @@ else return FALSE +/datum/objective/crew/researchdirector/research //inspired by old hippie's research level objective. should hopefully be compatible with techwebs when that gets finished. hopefully. should be easy to update in the event that it is incompatible with techwebs. + var/datum/design/targetdesign + explanation_text = "Make sure the research required to produce a (something broke, yell on citadel's development discussion channel about this) is available on the R&D server by the end of the shift." + +/datum/objective/crew/researchdirector/research/New() + . = ..() + targetdesign = pick(subtypesof(/datum/design)) + update_explanation_text() + +/datum/objective/crew/researchdirector/research/update_explanation_text() + . = ..() + explanation_text = "Make sure the research required to produce a [initial(targetdesign.name)] is available on the R&D server by the end of the shift." + +/datum/objective/crew/researchdirector/research/check_completion() + for(var/obj/machinery/r_n_d/server/S in GLOB.machines) + if(S && S.files && S.files.known_designs) + if(targetdesign in S.files.known_designs) + return TRUE + return FALSE + +/datum/objective/crew/scientist/ + +/datum/objective/crew/scientist/research //inspired by old hippie's research level objective. should hopefully be compatible with techwebs when that gets finished. hopefully. should be easy to update in the event that it is incompatible with techwebs. + var/datum/design/targetdesign + explanation_text = "Make sure the research required to produce a (something broke, yell on citadel's development discussion channel about this) is available on the R&D server by the end of the shift." + +/datum/objective/crew/scientist/research/New() + . = ..() + targetdesign = pick(subtypesof(/datum/design)) + update_explanation_text() + +/datum/objective/crew/scientist/research/update_explanation_text() + . = ..() + explanation_text = "Make sure the research required to produce a [initial(targetdesign.name)] is available on the R&D server by the end of the shift." + +/datum/objective/crew/scientist/research/check_completion() + for(var/obj/machinery/r_n_d/server/S in GLOB.machines) + if(S && S.files && S.files.known_designs) + if(targetdesign in S.files.known_designs) + return TRUE + return FALSE + /datum/objective/crew/roboticist/ /datum/objective/crew/roboticist/cyborgs //Ported from old Hippie From f2f5c6d53ef9e591168cfca4287fbb9118a44c7f Mon Sep 17 00:00:00 2001 From: deathride58 Date: Fri, 29 Sep 2017 16:55:38 -0400 Subject: [PATCH 112/120] completely reworks how objectives are selected, reduces copypasta --- code/citadel/cit_crewobjectives.dm | 23 ++-- .../cit_crewobjectives_cargo.dm | 84 ++++----------- .../cit_crewobjectives_civilian.dm | 101 ++++++++---------- .../cit_crewobjectives_command.dm | 19 ++-- .../cit_crewobjectives_engineering.dm | 39 ++----- .../cit_crewobjectives_medical.dm | 85 +++------------ .../cit_crewobjectives_science.dm | 68 ++---------- .../cit_crewobjectives_security.dm | 81 +++----------- 8 files changed, 139 insertions(+), 361 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 73e6787334..ed2a05bdd6 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -16,22 +16,31 @@ return if(!crewMind.assigned_role) return - var/rolePathString = "/datum/objective/crew/[ckey(crewMind.assigned_role)]" - var/rolePath = text2path(rolePathString) - if (isnull(rolePath)) + var/validobjs = get_valid_crew_objs(ckey(crewMind.assigned_role)) + if(isnull(validobjs)) return - var/list/objectiveTypes = typesof(rolePath) - rolePath - if(!objectiveTypes.len) + if(!validobjs.len) return - var/selectedType = pick(objectiveTypes) - var/datum/objective/crew/newObjective = new selectedType + var/selectedObj = pick(validobjs) + var/datum/objective/crew/newObjective = new selectedObj if(!newObjective) return newObjective.owner = crewMind crewMind.objectives += newObjective to_chat(crewMind, "Your objective: [newObjective.explanation_text]") +/datum/controller/subsystem/ticker/proc/get_valid_crew_objs(var/job = "")//taken from old hippie with adjustments + var/list/objpaths = typesof(/datum/objective/crew) + var/list/objlist = list() + for(/datum/objective/crew/obj in objpaths) + if(obj && initial(obj.jobs)) + var/list/availableto = splittext(initial(obj.jobs),",") + if(job in availableto) + objlist += obj + return objlist + /datum/objective/crew/ + var/jobs = "" explanation_text = "Yell on the development discussion channel on Citadels discord if this ever shows up. Something just broke here, dude" /datum/objective/crew/proc/setup() diff --git a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm index 392ec3a7e1..d164123c4d 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_cargo.dm @@ -1,20 +1,19 @@ /* CARGO OBJECTIVES */ -/datum/objective/crew/quartermaster - -/datum/objective/crew/quartermaster/petsplosion +/datum/objective/crew/petsplosion explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." + jobs = "quartermaster,cargotechnician" -/datum/objective/crew/quartermaster/petsplosion/New() +/datum/objective/crew/petsplosion/New() . = ..() target_amount = rand(10,30) update_explanation_text() -/datum/objective/crew/quartermaster/petsplosion/update_explanation_text() +/datum/objective/crew/petsplosion/update_explanation_text() . = ..() explanation_text = "Ensure there are at least [target_amount] pets on the station by the end of the shift. Interpret this as you wish." -/datum/objective/crew/quartermaster/petsplosion/check_completion() +/datum/objective/crew/petsplosion/check_completion() var/petcount = target_amount for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) if(!(P.stat == DEAD)) @@ -30,96 +29,49 @@ else return FALSE -/datum/objective/crew/quartermaster/points //ported from old hippie +/datum/objective/crew/points //ported from old hippie explanation_text = "Make sure the station has at least (Something broke, report this to the development discussion channel of citadels discord) supply points at the end of the shift." + jobs = "quartermaster,cargotechnician" -/datum/objective/crew/quartermaster/points/New() +/datum/objective/crew/points/New() . = ..() target_amount = rand(25000,100000) update_explanation_text() -/datum/objective/crew/quartermaster/points/update_explanation_text() +/datum/objective/crew/points/update_explanation_text() . = ..() explanation_text = "Make sure the station has at least [target_amount] supply points at the end of the shift." -/datum/objective/crew/quartermaster/points/check_completion() +/datum/objective/crew/points/check_completion() if(SSshuttle.points >= target_amount) return TRUE else return FALSE -/datum/objective/crew/cargotechnician - -/datum/objective/crew/cargotechnician/petsplosion - explanation_text = "Ensure there are at least (If you see this, yell on citadels discord in the development discussion channel) pets on the station by the end of the shift. Interpret this as you wish." - -/datum/objective/crew/cargotechnician/petsplosion/New() - . = ..() - target_amount = rand(10,30) - update_explanation_text() - -/datum/objective/crew/cargotechnician/petsplosion/update_explanation_text() - . = ..() - explanation_text = "Ensure there are at least [target_amount] pets on the station by the end of the shift. Interpret this as you wish." - -/datum/objective/crew/cargotechnician/petsplosion/check_completion() - var/petcount = target_amount - for(var/mob/living/simple_animal/pet/P in GLOB.mob_list) - if(!(P.stat == DEAD)) - if(P.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(P)]) - petcount-- - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(!(H.stat == DEAD)) - if(H.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(H)]) - if(istype(H.wear_neck, /obj/item/clothing/neck/petcollar)) - petcount-- - if(petcount <= 0) - return TRUE - else - return FALSE - -/datum/objective/crew/cargotechnician/points //ported from old hippie - explanation_text = "Make sure the station has at least (Something broke, report this to the development discussion channel of citadels discord) supply points at the end of the shift." - -/datum/objective/crew/cargotechnician/points/New() - . = ..() - target_amount = rand(25000,100000) - update_explanation_text() - -/datum/objective/crew/cargotechnician/points/update_explanation_text() - . = ..() - explanation_text = "Make sure the station has at least [target_amount] supply points at the end of the shift." - -/datum/objective/crew/cargotechnician/points/check_completion() - if(SSshuttle.points >= target_amount) - return TRUE - else - return FALSE - -/datum/objective/crew/shaftminer - -/datum/objective/crew/shaftminer/bubblegum +/datum/objective/crew/bubblegum explanation_text = "Ensure Bubblegum is dead at the end of the shift." + jobs = "shaftminer" -/datum/objective/crew/shaftminer/bubblegum/check_completion() +/datum/objective/crew/bubblegum/check_completion() for(var/mob/living/simple_animal/hostile/megafauna/bubblegum/B in GLOB.mob_list) if(!(B.stat == DEAD)) return FALSE return TRUE -/datum/objective/crew/shaftminer/fatstacks //ported from old hippie +/datum/objective/crew/fatstacks //ported from old hippie explanation_text = "Have at least (something broke, report this to the development discussion channel of citadels discord) mining points on your ID at the end of the shift." + jobs = "shaftminer" -/datum/objective/crew/shaftminer/fatstacks/New() +/datum/objective/crew/fatstacks/New() . = ..() target_amount = rand(15000,50000) update_explanation_text() -/datum/objective/crew/shaftminer/fatstacks/update_explanation_text() +/datum/objective/crew/fatstacks/update_explanation_text() . = ..() explanation_text = "Have at least [target_amount] mining points on your ID at the end of the shift." -/datum/objective/crew/shaftminer/fatstacks/check_completion() +/datum/objective/crew/fatstacks/check_completion() if(owner && owner.current) var/mob/living/carbon/human/H = owner.current var/obj/item/card/id/theID = H.get_idcard() diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index f6defe3242..054e707fd9 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -1,13 +1,12 @@ /* CIVILIAN OBJECTIVES */ -/datum/objective/crew/botanist - -/datum/objective/crew/botanist/druglord //ported from old Hippie with adjustments +/datum/objective/crew/druglordbot //ported from old Hippie with adjustments var/targetchem = "none" var/datum/reagent/chempath explanation_text = "Have at least (somethin broke here) harvested plants containing (report this on the development discussion channel of citadel's discord) when the shift ends." + jobs = "botanist" -/datum/objective/crew/botanist/druglord/New() +/datum/objective/crew/druglordbot/New() . = ..() target_amount = rand(3,20) var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) @@ -18,11 +17,11 @@ targetchem = initial(chempath.id) update_explanation_text() -/datum/objective/crew/botanist/druglord/update_explanation_text() +/datum/objective/crew/druglordbot/update_explanation_text() . = ..() explanation_text = "Have at least [target_amount] harvested plants containing [initial(chempath.name)] when the shift ends." -/datum/objective/crew/botanist/druglord/check_completion() +/datum/objective/crew/druglordbot/check_completion() var/pillcount = target_amount if(owner.current) if(owner.current.contents) @@ -34,14 +33,13 @@ else return FALSE -/datum/objective/crew/cook - -/datum/objective/crew/cook/foodhoard +/datum/objective/crew/foodhoard var/datum/crafting_recipe/food/targetfood var/obj/item/reagent_containers/food/foodpath explanation_text = "Personally deliver at least (yo something broke) (report this to the developer discussion channel in citadels discord)s to Centcom." + jobs = "cook" -/datum/objective/crew/cook/foodhoard/New() +/datum/objective/crew/foodhoard/New() . = ..() target_amount = rand(2,10) var/blacklist = list(/datum/crafting_recipe/food, /datum/crafting_recipe/food/cak) @@ -50,36 +48,34 @@ foodpath = initial(targetfood.result) update_explanation_text() -/datum/objective/crew/cook/foodhoard/update_explanation_text() +/datum/objective/crew/foodhoard/update_explanation_text() . = ..() explanation_text = "Personally deliver at least [target_amount] [initial(foodpath.name)]s to Centcom." -/datum/objective/crew/cook/foodhoard/check_completion() +/datum/objective/crew/foodhoard/check_completion() if(owner.current && owner.current.check_contents_for(foodpath) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) return TRUE else return FALSE -/datum/objective/crew/bartender - -/datum/objective/crew/bartender/responsibility +/datum/objective/crew/responsibility explanation_text = "Make sure nobody dies of alcohol poisoning." + jobs = "bartender" -/datum/objective/crew/bartender/responsibility/check_completion() +/datum/objective/crew/responsibility/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.drunkenness >= 80) if(H.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(H)]) return FALSE return TRUE -/datum/objective/crew/janitor - -/datum/objective/crew/janitor/clean //ported from old Hippie +/datum/objective/crew/clean //ported from old Hippie var/list/areas = list() var/hardmode = FALSE explanation_text = "Ensure sure that (Yo, something broke. Yell about this in citadels devlopmeent discussion channel.) remain spotless at the end of the shift." + jobs = "janitor" -/datum/objective/crew/janitor/clean/New() +/datum/objective/crew/clean/New() . = ..() if(prob(1)) hardmode = TRUE @@ -94,7 +90,7 @@ areas |= pick_n_take(possibleareas) update_explanation_text() -/datum/objective/crew/janitor/clean/update_explanation_text() +/datum/objective/crew/clean/update_explanation_text() . = ..() explanation_text = "Ensure that the" for(var/i in 1 to areas.len) @@ -108,27 +104,26 @@ if(hardmode) explanation_text += " Chop-chop." -/datum/objective/crew/janitor/clean/check_completion() +/datum/objective/crew/clean/check_completion() for(var/area/A in areas) for(var/obj/effect/decal/cleanable/C in area_contents(A)) return FALSE return TRUE -/datum/objective/crew/clown - -/datum/objective/crew/clown/slipster //ported from old Hippie with adjustments +/datum/objective/crew/slipster //ported from old Hippie with adjustments explanation_text = "Slip at least (Yell on citadel's development discussion channel if you see this) different people with your PDA, and have it on you at the end of the shift." + jobs = "clown" -/datum/objective/crew/clown/slipster/New() +/datum/objective/crew/slipster/New() . = ..() target_amount = rand(5, 20) update_explanation_text() -/datum/objective/crew/clown/slipster/update_explanation_text() +/datum/objective/crew/slipster/update_explanation_text() . = ..() explanation_text = "Slip at least [target_amount] different people with your PDA, and have it on you at the end of the shift." -/datum/objective/crew/clown/slipster/check_completion() +/datum/objective/crew/slipster/check_completion() var/list/uniqueslips = list() if(owner && owner.current) for(var/obj/item/device/pda/clown/PDA in owner.current.get_contents()) @@ -139,24 +134,22 @@ else return FALSE -/datum/objective/crew/mime - -/datum/objective/crew/mime/vow //ported from old Hippie +/datum/objective/crew/vow //ported from old Hippie explanation_text = "Never break your vow of silence." + jobs = "mime" -/datum/objective/crew/mime/vow/check_completion() +/datum/objective/crew/vow/check_completion() if(owner && owner.current) var/list/say_log = owner.current.logging[INDIVIDUAL_SAY_LOG] if(say_log.len > 0) return FALSE return TRUE -/datum/objective/crew/chaplain - -/datum/objective/crew/chaplain/nullrod +/datum/objective/crew/nullrod explanation_text = "Don't lose your holy rod." + jobs = "chaplain" -/datum/objective/crew/chaplain/nullrod/check_completion() +/datum/objective/crew/nullrod/check_completion() if(owner && owner.current) if(owner.current.check_contents_for(typesof(/obj/item/nullrod))) return TRUE @@ -164,23 +157,22 @@ return TRUE return FALSE -/datum/objective/crew/curator - -/datum/objective/crew/curator/reporter //ported from old hippie +/datum/objective/crew/reporter //ported from old hippie var/charcount = 100 explanation_text = "Publish at least (Yo something broke) articles containing at least (Report this to Citadels development channel) characters." + jobs = "curator" -/datum/objective/crew/curator/reporter/New() +/datum/objective/crew/reporter/New() . = ..() target_amount = rand(2,10) charcount = rand(20,250) update_explanation_text() -/datum/objective/crew/curator/reporter/update_explanation_text() +/datum/objective/crew/reporter/update_explanation_text() . = ..() explanation_text = "Publish at least [target_amount] articles containing at least [charcount] characters." -/datum/objective/crew/curator/reporter/check_completion() +/datum/objective/crew/reporter/check_completion() if(owner && owner.current) var/ownername = "[ckey(owner.current.real_name)][ckey(owner.assigned_role)]" for(var/datum/newscaster/feed_channel/chan in GLOB.news_network.network_channels) @@ -193,41 +185,41 @@ else return FALSE -/datum/objective/crew/assistant - -/datum/objective/crew/assistant/departmentclothes +/datum/objective/crew/departmentclothes var/obj/item/clothing/under/rank/targetuniform explanation_text = "Be wearing a (Yo, this objective broke. report this to citadels discord via the development channel) at the end of the shift." + jobs = "assistant" -/datum/objective/crew/assistant/departmentclothes/New() +/datum/objective/crew/departmentclothes/New() . = ..() var/list/blacklist = list(/obj/item/clothing/under/rank, /obj/item/clothing/under/rank/miner, /obj/item/clothing/under/rank/medical/blue, /obj/item/clothing/under/rank/medical/green, /obj/item/clothing/under/rank/medical/purple, /obj/item/clothing/under/rank/security/grey, /obj/item/clothing/under/rank/warden/grey, /obj/item/clothing/under/rank/head_of_security/grey, /obj/item/clothing/under/rank/mailman, /obj/item/clothing/under/rank/psyche, /obj/item/clothing/under/rank/clown/sexy, /obj/item/clothing/under/rank/centcom_officer, /obj/item/clothing/under/rank/centcom_commander, /obj/item/clothing/under/rank/security/navyblue/russian, /obj/item/clothing/under/rank/security/blueshirt) var/list/validclothes = typesof(/obj/item/clothing/under/rank) - blacklist targetuniform = pick(validclothes) update_explanation_text() -/datum/objective/crew/assistant/departmentclothes/update_explanation_text() +/datum/objective/crew/departmentclothes/update_explanation_text() . = ..() explanation_text = "Be wearing a [initial(targetuniform.name)] at the end of the shift." -/datum/objective/crew/assistant/departmentclothes/check_completion() +/datum/objective/crew/departmentclothes/check_completion() if(owner && owner.current) var/mob/living/carbon/human/H = owner.current if(istype(H.w_uniform, targetuniform)) return TRUE return FALSE -/datum/objective/crew/assistant/pwrgame //ported from Goon +/datum/objective/crew/pwrgame //ported from Goon with adjustments var/obj/item/clothing/targettidegarb explanation_text = "Get your grubby hands on a (Dear god something broke. Report this to Citadel's development dicussion channel)." + jobs = "assistant" -/datum/objective/crew/assistant/pwrgame/New() +/datum/objective/crew/pwrgame/New() . = ..() var/list/muhvalids = list(/obj/item/clothing/mask/gas, /obj/item/clothing/head/welding, /obj/item/clothing/head/ushanka, /obj/item/clothing/gloves/color/yellow, /obj/item/clothing/mask/gas/owl_mask, /obj/item/clothing/suit/space) targettidegarb = pick(muhvalids) update_explanation_text() -/datum/objective/crew/assistant/pwrgame/update_explanation_text() +/datum/objective/crew/pwrgame/update_explanation_text() . = ..() explanation_text = "Get your grubby hands on a [initial(targettidegarb.name)]." /* DM is not a sane language in any way, shape, or form. If anyone wants to try to get this bit functioning proper, I hold no responsibility for broken keyboards. @@ -255,16 +247,17 @@ explanation_text += "grubby hands " explanation_text += "on a space suit." replace this if you're making this monstrosity work */ -/datum/objective/crew/assistant/pwrgame/check_completion() +/datum/objective/crew/pwrgame/check_completion() if(owner.current && owner.current.check_contents_for(typesof(targettidegarb))) return TRUE else return FALSE -/datum/objective/crew/assistant/promotion //ported from Goon +/datum/objective/crew/promotion //ported from Goon explanation_text = "Have a non-assistant ID registered to you at the end of the shift." + jobs = "assistant" -/datum/objective/crew/assistant/promotion/check_completion() +/datum/objective/crew/promotion/check_completion() if(owner && owner.current) var/mob/living/carbon/human/H = owner.current var/obj/item/card/id/theID = H.get_idcard() diff --git a/code/citadel/crew_objectives/cit_crewobjectives_command.dm b/code/citadel/crew_objectives/cit_crewobjectives_command.dm index 1ee6beaee6..b4f0d07c08 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_command.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_command.dm @@ -1,31 +1,30 @@ /* COMMAND OBJECTIVES */ -/datum/objective/crew/captain/ - -/datum/objective/crew/captain/hat //Ported from Goon +/datum/objective/crew/caphat //Ported from Goon explanation_text = "Don't lose your hat." + jobs = "captain" -/datum/objective/crew/captain/hat/check_completion() +/datum/objective/crew/caphat/check_completion() if(owner.current && owner.current.check_contents_for(/obj/item/clothing/head/caphat)) return TRUE else return FALSE -/datum/objective/crew/captain/datfukkendisk //Ported from old Hippie +/datum/objective/crew/datfukkendisk //Ported from old Hippie explanation_text = "Defend the nuclear authentication disk at all costs, and be the one to personally deliver it to Centcom." + jobs = "captain" //give this to other heads at your own risk. -/datum/objective/crew/captain/datfukkendisk/check_completion() +/datum/objective/crew/datfukkendisk/check_completion() if(owner.current && owner.current.check_contents_for(/obj/item/disk/nuclear) && SSshuttle.emergency.shuttle_areas[get_area(owner.current)]) return TRUE else return FALSE -/datum/objective/crew/headofpersonnel/ - -/datum/objective/crew/headofpersonnel/ian //Ported from old Hippie +/datum/objective/crew/ian //Ported from old Hippie explanation_text = "Defend Ian at all costs, and ensure he gets delivered to Centcom at the end of the shift." + jobs = "headofpersonnel" -/datum/objective/crew/headofpersonnel/ian/check_completion() +/datum/objective/crew/ian/check_completion() if(owner.current) for(var/mob/living/simple_animal/pet/dog/corgi/Ian/goodboy in GLOB.mob_list) if(goodboy.stat != DEAD && SSshuttle.emergency.shuttle_areas[get_area(goodboy)]) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm index 5c2f9bd03d..7cf523fd2c 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_engineering.dm @@ -1,20 +1,19 @@ /* ENGINEERING OBJECTIVES */ -/datum/objective/crew/chiefengineer - -/datum/objective/crew/chiefengineer/integrity //ported from old Hippie +/datum/objective/crew/integrity //ported from old Hippie explanation_text = "Ensure the station's integrity rating is at least (Yo something broke, yell on the development discussion channel of citadels discord about this)% when the shift ends." + jobs = "chiefengineer,stationengineer" -/datum/objective/crew/chiefengineer/integrity/New() +/datum/objective/crew/integrity/New() . = ..() target_amount = rand(60,95) update_explanation_text() -/datum/objective/crew/chiefengineer/integrity/update_explanation_text() +/datum/objective/crew/integrity/update_explanation_text() . = ..() explanation_text = "Ensure the station's integrity rating is at least [target_amount]% when the shift ends." -/datum/objective/crew/chiefengineer/integrity/check_completion() +/datum/objective/crew/integrity/check_completion() var/datum/station_state/end_state = new /datum/station_state() end_state.count() var/station_integrity = min(PERCENT(GLOB.start_state.score(end_state)), 100) @@ -23,35 +22,13 @@ else return FALSE -/datum/objective/crew/chiefengineer/poly +/datum/objective/crew/poly explanation_text = "Make sure Poly keeps his headset, and stays alive until the end of the shift." + jobs = "chiefengineer" -/datum/objective/crew/chiefengineer/poly/check_completion() +/datum/objective/crew/poly/check_completion() for(var/mob/living/simple_animal/parrot/Poly/dumbbird in GLOB.mob_list) if(!(dumbbird.stat == DEAD) && dumbbird.ears) if(istype(dumbbird.ears, /obj/item/device/radio/headset)) return TRUE return FALSE - -/datum/objective/crew/stationengineer - -/datum/objective/crew/stationengineer/integrity //ported from old Hippie - explanation_text = "Ensure the station's integrity rating is at least (Yo something broke, yell on the development discussion channel of citadels discord about this)% when the shift ends." - -/datum/objective/crew/stationengineer/integrity/New() - . = ..() - target_amount = rand(60,95) - update_explanation_text() - -/datum/objective/crew/stationengineer/integrity/update_explanation_text() - . = ..() - explanation_text = "Ensure the station's integrity rating is at least [target_amount]% when the shift ends." - -/datum/objective/crew/stationengineer/integrity/check_completion() - var/datum/station_state/end_state = new /datum/station_state() - end_state.count() - var/station_integrity = min(PERCENT(GLOB.start_state.score(end_state)), 100) - if(!SSticker.mode.station_was_nuked && station_integrity >= target_amount) - return TRUE - else - return FALSE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_medical.dm b/code/citadel/crew_objectives/cit_crewobjectives_medical.dm index 4147884b09..9a9010930d 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_medical.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_medical.dm @@ -1,23 +1,23 @@ /* MEDICAL OBJECTIVES */ -/datum/objective/crew/chiefmedicalofficer/ - -/datum/objective/crew/chiefmedicalofficer/morgue //Ported from old Hippie +/datum/objective/crew/morgue //Ported from old Hippie explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." + jobs = "chiefmedicalofficer,geneticist,medicaldoctor" -/datum/objective/crew/chiefmedicalofficer/morgue/check_completion() +/datum/objective/crew/morgue/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) if(H.stat == DEAD && H.z == ZLEVEL_STATION_PRIMARY) if(get_area(H) != /area/medical/morgue) return FALSE return TRUE -/datum/objective/crew/chiefmedicalofficer/chems //Ported from old Hippie +/datum/objective/crew/chems //Ported from old Hippie var/targetchem = "none" var/datum/reagent/chempath explanation_text = "Have (yell about this in the development discussion channel of citadel's discord, something broke) in your bloodstream when the shift ends." + jobs = "chiefmedicalofficer,chemist" -/datum/objective/crew/chiefmedicalofficer/chems/New() +/datum/objective/crew/chems/New() . = ..() var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) var/drugs = typesof(/datum/reagent/drug) - blacklist @@ -27,11 +27,11 @@ targetchem = initial(chempath.id) update_explanation_text() -/datum/objective/crew/chiefmedicalofficer/chems/update_explanation_text() +/datum/objective/crew/chems/update_explanation_text() . = ..() explanation_text = "Have [initial(chempath.name)] in your bloodstream when the shift ends." -/datum/objective/crew/chiefmedicalofficer/chems/check_completion() +/datum/objective/crew/chems/check_completion() if(owner.current) if(!owner.current.stat == DEAD && owner.current.reagents) if(owner.current.reagents.has_reagent(targetchem)) @@ -39,53 +39,13 @@ else return FALSE -/datum/objective/crew/geneticist - -/datum/objective/crew/geneticist/morgue //Ported from old Hippie - explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." - -/datum/objective/crew/geneticist/morgue/check_completion() - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(H.stat == DEAD && H.z == ZLEVEL_STATION_PRIMARY) - if(get_area(H) != /area/medical/morgue) - return FALSE - return TRUE - -/datum/objective/crew/chemist/ - -/datum/objective/crew/chemist/chems //Ported from old Hippie - var/targetchem = "none" - var/datum/reagent/chempath - explanation_text = "Have (yell about this in the development discussion channel of citadel's discord, something broke) in your bloodstream when the shift ends." - -/datum/objective/crew/chemist/chems/New() - . = ..() - var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol, /datum/reagent/medicine, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/adminordrazine/nanites, /datum/reagent/medicine/mine_salve, /datum/reagent/medicine/omnizine, /datum/reagent/medicine/syndicate_nanites, /datum/reagent/medicine/earthsblood, /datum/reagent/medicine/strange_reagent, /datum/reagent/medicine/miningnanites, /datum/reagent/medicine/changelingAdrenaline, /datum/reagent/medicine/changelingAdrenaline2) - var/drugs = typesof(/datum/reagent/drug) - blacklist - var/meds = typesof(/datum/reagent/medicine) - blacklist - var/chemlist = drugs + meds - chempath = pick(chemlist) - targetchem = initial(chempath.id) - update_explanation_text() - -/datum/objective/crew/chemist/chems/update_explanation_text() - . = ..() - explanation_text = "Have [initial(chempath.name)] in your bloodstream when the shift ends." - -/datum/objective/crew/chemist/chems/check_completion() - if(owner.current) - if(!owner.current.stat == DEAD && owner.current.reagents) - if(owner.current.reagents.has_reagent(targetchem)) - return TRUE - else - return FALSE - -/datum/objective/crew/chemist/druglord //ported from old Hippie with adjustments +/datum/objective/crew/druglordchem //ported from old Hippie with adjustments var/targetchem = "none" var/datum/reagent/chempath explanation_text = "Have at least (somethin broke here) pills containing (report this on the development discussion channel of citadel's discord) when the shift ends." + jobs = "chemist" -/datum/objective/crew/chemist/druglord/New() +/datum/objective/crew/druglordchem/New() . = ..() target_amount = rand(5,50) var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol) @@ -95,11 +55,11 @@ targetchem = initial(chempath.id) update_explanation_text() -/datum/objective/crew/chemist/druglord/update_explanation_text() +/datum/objective/crew/druglordchem/update_explanation_text() . = ..() explanation_text = "Have at least [target_amount] pills containing [initial(chempath.name)] when the shift ends." -/datum/objective/crew/chemist/druglord/check_completion() +/datum/objective/crew/druglordchem/check_completion() var/pillcount = target_amount if(owner.current) if(owner.current.contents) @@ -111,27 +71,14 @@ else return FALSE -/datum/objective/crew/virologist - -/datum/objective/crew/virologist/noinfections +/datum/objective/crew/noinfections explanation_text = "Ensure no living crew members are infected with harmful viruses at the end of the shift" + jobs = "virologist" -/datum/objective/crew/virologist/noinfections/check_completion() +/datum/objective/crew/noinfections/check_completion() for(var/mob/living/carbon/human/H in GLOB.mob_list) if(!H.stat == DEAD) if(H.z == ZLEVEL_STATION_PRIMARY || SSshuttle.emergency.shuttle_areas[get_area(H)]) if(H.check_virus() == 2) return FALSE return TRUE - -/datum/objective/crew/medicaldoctor - -/datum/objective/crew/medicaldoctor/morgue //Ported from old Hippie - explanation_text = "Ensure there are no corpses on the station outside of the morgue when the shift ends." - -/datum/objective/crew/medicaldoctor/morgue/check_completion() - for(var/mob/living/carbon/human/H in GLOB.mob_list) - if(H.stat == DEAD && H.z == ZLEVEL_STATION_PRIMARY) - if(get_area(H) != /area/medical/morgue) - return FALSE - return TRUE diff --git a/code/citadel/crew_objectives/cit_crewobjectives_science.dm b/code/citadel/crew_objectives/cit_crewobjectives_science.dm index d028a453bc..f04f97b174 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_science.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_science.dm @@ -1,20 +1,19 @@ /* SCIENCE OBJECTIVES */ -/datum/objective/crew/researchdirector/ - -/datum/objective/crew/researchdirector/cyborgs //Ported from old Hippie +/datum/objective/crew/cyborgs //Ported from old Hippie explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's development discussion channel about this) functioning cyborgs when the shift ends." + jobs = "researchdirector,roboticist" -/datum/objective/crew/researchdirector/cyborgs/New() +/datum/objective/crew/cyborgs/New() . = ..() target_amount = rand(3,10) update_explanation_text() -/datum/objective/crew/researchdirector/cyborgs/update_explanation_text() +/datum/objective/crew/cyborgs/update_explanation_text() . = ..() explanation_text = "Ensure there are at least [target_amount] functioning cyborgs when the shift ends." -/datum/objective/crew/researchdirector/cyborgs/check_completion() +/datum/objective/crew/cyborgs/check_completion() var/borgcount = target_amount for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) if(!(R.stat == DEAD)) @@ -24,68 +23,23 @@ else return FALSE -/datum/objective/crew/researchdirector/research //inspired by old hippie's research level objective. should hopefully be compatible with techwebs when that gets finished. hopefully. should be easy to update in the event that it is incompatible with techwebs. +/datum/objective/crew/research //inspired by old hippie's research level objective. should hopefully be compatible with techwebs when that gets finished. hopefully. should be easy to update in the event that it is incompatible with techwebs. var/datum/design/targetdesign explanation_text = "Make sure the research required to produce a (something broke, yell on citadel's development discussion channel about this) is available on the R&D server by the end of the shift." + jobs = "researchdirector,scientist" -/datum/objective/crew/researchdirector/research/New() +/datum/objective/crew/research/New() . = ..() targetdesign = pick(subtypesof(/datum/design)) update_explanation_text() -/datum/objective/crew/researchdirector/research/update_explanation_text() +/datum/objective/crew/research/update_explanation_text() . = ..() explanation_text = "Make sure the research required to produce a [initial(targetdesign.name)] is available on the R&D server by the end of the shift." -/datum/objective/crew/researchdirector/research/check_completion() +/datum/objective/crew/research/check_completion() for(var/obj/machinery/r_n_d/server/S in GLOB.machines) if(S && S.files && S.files.known_designs) if(targetdesign in S.files.known_designs) return TRUE - return FALSE - -/datum/objective/crew/scientist/ - -/datum/objective/crew/scientist/research //inspired by old hippie's research level objective. should hopefully be compatible with techwebs when that gets finished. hopefully. should be easy to update in the event that it is incompatible with techwebs. - var/datum/design/targetdesign - explanation_text = "Make sure the research required to produce a (something broke, yell on citadel's development discussion channel about this) is available on the R&D server by the end of the shift." - -/datum/objective/crew/scientist/research/New() - . = ..() - targetdesign = pick(subtypesof(/datum/design)) - update_explanation_text() - -/datum/objective/crew/scientist/research/update_explanation_text() - . = ..() - explanation_text = "Make sure the research required to produce a [initial(targetdesign.name)] is available on the R&D server by the end of the shift." - -/datum/objective/crew/scientist/research/check_completion() - for(var/obj/machinery/r_n_d/server/S in GLOB.machines) - if(S && S.files && S.files.known_designs) - if(targetdesign in S.files.known_designs) - return TRUE - return FALSE - -/datum/objective/crew/roboticist/ - -/datum/objective/crew/roboticist/cyborgs //Ported from old Hippie - explanation_text = "Ensure there are at least (Yo something broke here, yell on citadel's development discussion channel about this) functioning cyborgs when the shift ends." - -/datum/objective/crew/roboticist/cyborgs/New() - . = ..() - target_amount = rand(3,10) - update_explanation_text() - -/datum/objective/crew/roboticist/cyborgs/update_explanation_text() - . = ..() - explanation_text = "Ensure there are at least [target_amount] functioning cyborgs when the shift ends." - -/datum/objective/crew/roboticist/cyborgs/check_completion() - var/borgcount = target_amount - for(var/mob/living/silicon/robot/R in GLOB.living_mob_list) - if(!(R.stat == DEAD)) - borgcount-- - if(borgcount <= 0) - return TRUE - else - return FALSE + return FALSE \ No newline at end of file diff --git a/code/citadel/crew_objectives/cit_crewobjectives_security.dm b/code/citadel/crew_objectives/cit_crewobjectives_security.dm index b0b9bb3b55..4e1ca87582 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_security.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_security.dm @@ -1,86 +1,33 @@ /* SECURITY OBJECTIVES */ -/datum/objective/crew/headofsecurity/ - -/datum/objective/crew/headofsecurity/enjoyyourstay +/datum/objective/crew/enjoyyourstay explanation_text = "Welcome to Space Station 13. Enjoy your stay." - -/datum/objective/crew/headofsecurity/enjoyyourstay/New() - . = ..() - update_explanation_text() - -/datum/objective/crew/headofsecurity/enjoyyourstay/update_explanation_text() - . = ..() + jobs = "headofsecurity,securityofficer,warden,detective" var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.", "Security is a mission, not an intermission.") - explanation_text = pick(edglines) -/datum/objective/crew/headofsecurity/enjoyyourstay/check_completion() - explanation_text = "Enforce Space Law to the best of your ability." - return TRUE - -/datum/objective/crew/securityofficer/ - -/datum/objective/crew/securityofficer/enjoyyourstay - explanation_text = "Welcome to Space Station 13. Enjoy your stay." - -/datum/objective/crew/securityofficer/enjoyyourstay/New() +/datum/objective/crew/enjoyyourstay/New() . = ..() update_explanation_text() -/datum/objective/crew/securityofficer/enjoyyourstay/update_explanation_text() +/datum/objective/crew/enjoyyourstay/update_explanation_text() . = ..() - var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.", "Security is a mission, not an intermission.") explanation_text = pick(edglines) -/datum/objective/crew/securityofficer/enjoyyourstay/check_completion() +/datum/objective/crew/enjoyyourstay/check_completion() explanation_text = "Enforce Space Law to the best of your ability." - return TRUE + if(owner && owner.current) + if(owner.current.stat != DEAD) + return TRUE + return FALSE -/datum/objective/crew/warden/ - -/datum/objective/crew/warden/enjoyyourstay - explanation_text = "Welcome to Space Station 13. Enjoy your stay." - -/datum/objective/crew/warden/enjoyyourstay/New() - . = ..() - update_explanation_text() - -/datum/objective/crew/warden/enjoyyourstay/update_explanation_text() - . = ..() - var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.", "Security is a mission, not an intermission.") - explanation_text = pick(edglines) - -/datum/objective/crew/warden/enjoyyourstay/check_completion() - explanation_text = "Enforce Space Law to the best of your ability." - return TRUE - -/datum/objective/crew/detective/ - -/datum/objective/crew/detective/enjoyyourstay - explanation_text = "Welcome to Space Station 13. Enjoy your stay." - -/datum/objective/crew/detective/enjoyyourstay/New() - . = ..() - update_explanation_text() - -/datum/objective/crew/detective/enjoyyourstay/update_explanation_text() - . = ..() - var/list/edglines = list("Welcome to Space Station 13. Enjoy your stay.", "You signed up for this.", "Abandon hope.", "The tide's gonna stop eventually.", "Hey, someone's gotta do it.", "No, you can't resign.", "Security is a mission, not an intermission.", "Well, at least you know fashion.") - explanation_text = pick(edglines) - -/datum/objective/crew/detective/enjoyyourstay/check_completion() - explanation_text = "Enforce Space Law to the best of your ability." - return TRUE - -/datum/objective/crew/lawyer/ - -/datum/objective/crew/lawyer/justicecrew +/datum/objective/crew/justicecrew explanation_text = "Ensure there are no innocent crew members in the brig when the shift ends." + jobs = "lawyer" -/datum/objective/crew/lawyer/justicecrew/check_completion() - if(owner.current) +/datum/objective/crew/justicecrew/check_completion() + if(owner && owner.current) for(var/datum/mind/M in SSticker.minds) if(M.current && isliving(M.current)) - if(!M.special_role && !M.assigned_role == "Security Officer" && !M.assigned_role == "Detective" && !M.assigned_role == "Head of Security" && !M.assigned_role == "Lawyer" && !M.assigned_role == "Warden" && get_area(M.current) != typesof(/area/security)) + if(!M.special_role && !(M.assigned_role == "Security Officer") && !(M.assigned_role == "Detective") && !(M.assigned_role == "Head of Security") && !(M.assigned_role == "Lawyer") && !(M.assigned_role == "Warden") && get_area(M.current) != typesof(/area/security)) return FALSE return TRUE From 808b0b6d9affa39c165518516283baf749cdb287 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Fri, 29 Sep 2017 17:02:19 -0400 Subject: [PATCH 113/120] guess whos bad at coding --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index ed2a05bdd6..91b7594e6a 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -32,7 +32,7 @@ /datum/controller/subsystem/ticker/proc/get_valid_crew_objs(var/job = "")//taken from old hippie with adjustments var/list/objpaths = typesof(/datum/objective/crew) var/list/objlist = list() - for(/datum/objective/crew/obj in objpaths) + for(var/datum/objective/crew/obj in objpaths) if(obj && initial(obj.jobs)) var/list/availableto = splittext(initial(obj.jobs),",") if(job in availableto) From 6b81ecbeb0d65f26bdc71cf92b7c34e93288ca84 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Fri, 29 Sep 2017 17:46:59 -0400 Subject: [PATCH 114/120] time for 150 hours of testing --- code/citadel/cit_crewobjectives.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 91b7594e6a..1675ca8f03 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -16,7 +16,7 @@ return if(!crewMind.assigned_role) return - var/validobjs = get_valid_crew_objs(ckey(crewMind.assigned_role)) + var/list/validobjs = get_valid_crew_objs(ckey(crewMind.assigned_role)) if(isnull(validobjs)) return if(!validobjs.len) From e04e05d8b78423e7913268e185315886610e3405 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Sun, 1 Oct 2017 19:37:15 -0400 Subject: [PATCH 115/120] 150 HOURS OF CODING --- code/citadel/cit_crewobjectives.dm | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 1675ca8f03..0dad401786 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -17,9 +17,7 @@ if(!crewMind.assigned_role) return var/list/validobjs = get_valid_crew_objs(ckey(crewMind.assigned_role)) - if(isnull(validobjs)) - return - if(!validobjs.len) + if(!validobjs || !validobjs.len) return var/selectedObj = pick(validobjs) var/datum/objective/crew/newObjective = new selectedObj @@ -32,11 +30,11 @@ /datum/controller/subsystem/ticker/proc/get_valid_crew_objs(var/job = "")//taken from old hippie with adjustments var/list/objpaths = typesof(/datum/objective/crew) var/list/objlist = list() - for(var/datum/objective/crew/obj in objpaths) - if(obj && initial(obj.jobs)) - var/list/availableto = splittext(initial(obj.jobs),",") - if(job in availableto) - objlist += obj + for(var/hoorayhackyshit in objpaths) + var/datum/objective/crew/obj = hoorayhackyshit //dm is not a sane language in any way, shape, or form. + var/list/availableto = splittext(initial(obj.jobs),",") + if(job in availableto) + objlist += obj return objlist /datum/objective/crew/ From 70f06cfe356b35d6b42db922ada1cf593b42f313 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Sun, 1 Oct 2017 19:56:44 -0400 Subject: [PATCH 116/120] config. > CONFIG_GET --- code/controllers/configuration/entries/game_options.dm | 4 ++++ code/controllers/subsystem/ticker.dm | 6 +++--- code/modules/mob/dead/new_player/new_player.dm | 2 +- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/code/controllers/configuration/entries/game_options.dm b/code/controllers/configuration/entries/game_options.dm index 106804a576..65c7dbaf4c 100644 --- a/code/controllers/configuration/entries/game_options.dm +++ b/code/controllers/configuration/entries/game_options.dm @@ -256,6 +256,10 @@ CONFIG_DEF(number/bombcap) value = 14 min_val = 4 +CONFIG_DEF(flag/allow_crew_objectives) +CONFIG_DEF(flag/allow_miscreants) +CONFIG_DEF(flag/allow_extended_miscreants) + /datum/config_entry/number/bombcap/ValidateAndSet(str_val) . = ..() if(.) diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index 6cbd70fd96..911b72e4da 100755 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -260,9 +260,9 @@ SUBSYSTEM_DEF(ticker) qdel(S) //assign crew objectives and generate miscreants - if(config.allow_extended_miscreants && GLOB.master_mode == "extended") + if(CONFIG_GET(flag/allow_extended_miscreants) && GLOB.master_mode == "extended") GLOB.miscreants_allowed = TRUE - if(config.allow_miscreants && GLOB.master_mode != "extended") + if(CONFIG_GET(flag/allow_miscreants) && GLOB.master_mode != "extended") GLOB.miscreants_allowed = TRUE generate_crew_objectives() @@ -484,7 +484,7 @@ SUBSYSTEM_DEF(ticker) completedObjectives += "[i]
" to_chat(world, "[completedObjectives]
") else - if(config.allow_crew_objectives) + if(CONFIG_GET(flag/allow_crew_objectives)) to_chat(world, "Nobody completed their Crew Objectives!
") CHECK_TICK diff --git a/code/modules/mob/dead/new_player/new_player.dm b/code/modules/mob/dead/new_player/new_player.dm index 5fe72f1938..167f1037c3 100644 --- a/code/modules/mob/dead/new_player/new_player.dm +++ b/code/modules/mob/dead/new_player/new_player.dm @@ -376,7 +376,7 @@ if(prob(2) && !issilicon(humanc) && !jobban_isbanned(humanc.mind, "Syndicate") && GLOB.miscreants_allowed) SSticker.generate_miscreant_objectives(humanc.mind) else - if(config.allow_crew_objectives) + if(CONFIG_GET(flag/allow_crew_objectives)) SSticker.generate_individual_objectives(humanc.mind) GLOB.joined_player_list += character.ckey From f7c6c8b4400c00be180489d35a3a49c4e94adbaa Mon Sep 17 00:00:00 2001 From: deathride58 Date: Mon, 2 Oct 2017 18:53:57 -0400 Subject: [PATCH 117/120] config. > CONFIG_GET 2: "all checks have failed" boogaloo --- code/citadel/cit_crewobjectives.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/citadel/cit_crewobjectives.dm b/code/citadel/cit_crewobjectives.dm index 0dad401786..2d9149f5b1 100644 --- a/code/citadel/cit_crewobjectives.dm +++ b/code/citadel/cit_crewobjectives.dm @@ -3,12 +3,12 @@ if(prob(2) && !issilicon(crewMind.current) && !jobban_isbanned(crewMind, "Syndicate") && GLOB.miscreants_allowed) generate_miscreant_objectives(crewMind) else - if(config.allow_crew_objectives) + if(CONFIG_GET(flag/allow_crew_objectives)) generate_individual_objectives(crewMind) return /datum/controller/subsystem/ticker/proc/generate_individual_objectives(var/datum/mind/crewMind) - if(!config.allow_crew_objectives) + if(!(CONFIG_GET(flag/allow_crew_objectives))) return if(!crewMind) return From b37556a9511ffedbcd2e760bf7bf09a280570e22 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 4 Oct 2017 20:19:43 -0400 Subject: [PATCH 118/120] makes responsibility objective a little more clear --- code/citadel/crew_objectives/cit_crewobjectives_civilian.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm index 054e707fd9..81427c7951 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_civilian.dm @@ -59,7 +59,7 @@ return FALSE /datum/objective/crew/responsibility - explanation_text = "Make sure nobody dies of alcohol poisoning." + explanation_text = "Make sure nobody dies with alcohol poisoning." jobs = "bartender" /datum/objective/crew/responsibility/check_completion() From 7ca2bd48a564cd892e2cc5b20a0fa4e862a57571 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Fri, 6 Oct 2017 09:56:42 -0400 Subject: [PATCH 119/120] Crew objectives no longer count towards antags greentexting --- code/game/gamemodes/changeling/changeling.dm | 21 +++++++++++++------- code/game/gamemodes/traitor/traitor.dm | 20 +++++++++++++------ code/game/gamemodes/wizard/wizard.dm | 20 +++++++++++++------ 3 files changed, 42 insertions(+), 19 deletions(-) diff --git a/code/game/gamemodes/changeling/changeling.dm b/code/game/gamemodes/changeling/changeling.dm index ae09e8ee12..eafc5cd717 100644 --- a/code/game/gamemodes/changeling/changeling.dm +++ b/code/game/gamemodes/changeling/changeling.dm @@ -245,13 +245,21 @@ GLOBAL_LIST_INIT(slot2type, list("head" = /obj/item/clothing/head/changeling, "w if(changeling.objectives.len) var/count = 1 for(var/datum/objective/objective in changeling.objectives) - if(objective.check_completion()) - text += "
Objective #[count]: [objective.explanation_text] Success!" - SSblackbox.add_details("changeling_objective","[objective.type]|SUCCESS") + if(istype(objective, /datum/objective/crew)) + if(objective.check_completion()) + text += "
Objective #[count]: [objective.explanation_text] Success! (Optional)" + SSblackbox.add_details("changeling_objective","[objective.type]|SUCCESS") + else + text += "
Objective #[count]: [objective.explanation_text] Fail. (Optional)" + SSblackbox.add_details("changeling_objective","[objective.type]|FAIL") else - text += "
Objective #[count]: [objective.explanation_text] Fail." - SSblackbox.add_details("changeling_objective","[objective.type]|FAIL") - changelingwin = 0 + if(objective.check_completion()) + text += "
Objective #[count]: [objective.explanation_text] Success!" + SSblackbox.add_details("changeling_objective","[objective.type]|SUCCESS") + else + text += "
Objective #[count]: [objective.explanation_text] Fail." + SSblackbox.add_details("changeling_objective","[objective.type]|FAIL") + changelingwin = 0 count++ if(changelingwin) @@ -520,4 +528,3 @@ GLOBAL_LIST_INIT(slot2type, list("head" = /obj/item/clothing/head/changeling, "w var/datum/atom_hud/antag/hud = GLOB.huds[ANTAG_HUD_CHANGELING] hud.leave_hud(changling_mind.current) set_antag_hud(changling_mind.current, null) - diff --git a/code/game/gamemodes/traitor/traitor.dm b/code/game/gamemodes/traitor/traitor.dm index 64d4f84eec..9881c49b68 100644 --- a/code/game/gamemodes/traitor/traitor.dm +++ b/code/game/gamemodes/traitor/traitor.dm @@ -111,13 +111,21 @@ if(traitor.objectives.len)//If the traitor had no objectives, don't need to process this. var/count = 1 for(var/datum/objective/objective in traitor.objectives) - if(objective.check_completion()) - objectives += "
Objective #[count]: [objective.explanation_text] Success!" - SSblackbox.add_details("traitor_objective","[objective.type]|SUCCESS") + if(istype(objective, /datum/objective/crew)) + if(objective.check_completion()) + objectives += "
Objective #[count]: [objective.explanation_text] Success! (Optional)" + SSblackbox.add_details("traitor_objective","[objective.type]|SUCCESS") + else + objectives += "
Objective #[count]: [objective.explanation_text] Fail. (Optional)" + SSblackbox.add_details("traitor_objective","[objective.type]|FAIL") else - objectives += "
Objective #[count]: [objective.explanation_text] Fail." - SSblackbox.add_details("traitor_objective","[objective.type]|FAIL") - traitorwin = 0 + if(objective.check_completion()) + objectives += "
Objective #[count]: [objective.explanation_text] Success!" + SSblackbox.add_details("traitor_objective","[objective.type]|SUCCESS") + else + objectives += "
Objective #[count]: [objective.explanation_text] Fail." + SSblackbox.add_details("traitor_objective","[objective.type]|FAIL") + traitorwin = 0 count++ if(uplink_true) diff --git a/code/game/gamemodes/wizard/wizard.dm b/code/game/gamemodes/wizard/wizard.dm index d25c7613bc..dee9ab4a3d 100644 --- a/code/game/gamemodes/wizard/wizard.dm +++ b/code/game/gamemodes/wizard/wizard.dm @@ -212,13 +212,21 @@ var/count = 1 var/wizardwin = 1 for(var/datum/objective/objective in wizard.objectives) - if(objective.check_completion()) - text += "
Objective #[count]: [objective.explanation_text] Success!" - SSblackbox.add_details("wizard_objective","[objective.type]|SUCCESS") + if(istype(objective, /datum/objective/crew)) + if(objective.check_completion()) + text += "
Objective #[count]: [objective.explanation_text] Success! (Optional)" + SSblackbox.add_details("wizard_objective","[objective.type]|SUCCESS") + else + text += "
Objective #[count]: [objective.explanation_text] Fail. (Optional)" + SSblackbox.add_details("wizard_objective","[objective.type]|FAIL") else - text += "
Objective #[count]: [objective.explanation_text] Fail." - SSblackbox.add_details("wizard_objective","[objective.type]|FAIL") - wizardwin = 0 + if(objective.check_completion()) + text += "
Objective #[count]: [objective.explanation_text] Success!" + SSblackbox.add_details("wizard_objective","[objective.type]|SUCCESS") + else + text += "
Objective #[count]: [objective.explanation_text] Fail." + SSblackbox.add_details("wizard_objective","[objective.type]|FAIL") + wizardwin = 0 count++ if(wizard.current && wizard.current.stat!=2 && wizardwin) From 16e7cdea6cdce88263d7bbdcfe8eeafed3777468 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Fri, 6 Oct 2017 10:10:02 -0400 Subject: [PATCH 120/120] makes chemist druglord objective harder to cheese --- .../citadel/crew_objectives/cit_crewobjectives_medical.dm | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/code/citadel/crew_objectives/cit_crewobjectives_medical.dm b/code/citadel/crew_objectives/cit_crewobjectives_medical.dm index 9a9010930d..43d470f2f3 100644 --- a/code/citadel/crew_objectives/cit_crewobjectives_medical.dm +++ b/code/citadel/crew_objectives/cit_crewobjectives_medical.dm @@ -42,12 +42,14 @@ /datum/objective/crew/druglordchem //ported from old Hippie with adjustments var/targetchem = "none" var/datum/reagent/chempath - explanation_text = "Have at least (somethin broke here) pills containing (report this on the development discussion channel of citadel's discord) when the shift ends." + var/chemamount = 0 + explanation_text = "Have at least (somethin broke here) pills containing at least (like really broke) units of(report this on the development discussion channel of citadel's discord) when the shift ends." jobs = "chemist" /datum/objective/crew/druglordchem/New() . = ..() target_amount = rand(5,50) + chemamount = rand(1,20) var/blacklist = list(/datum/reagent/drug, /datum/reagent/drug/nicotine, /datum/reagent/drug/menthol) var/drugs = typesof(/datum/reagent/drug) - blacklist var/chemlist = drugs @@ -57,14 +59,14 @@ /datum/objective/crew/druglordchem/update_explanation_text() . = ..() - explanation_text = "Have at least [target_amount] pills containing [initial(chempath.name)] when the shift ends." + explanation_text = "Have at least [target_amount] pills containing at least [chemamount] units of [initial(chempath.name)] when the shift ends." /datum/objective/crew/druglordchem/check_completion() var/pillcount = target_amount if(owner.current) if(owner.current.contents) for(var/obj/item/reagent_containers/pill/P in owner.current.get_contents()) - if(P.reagents.has_reagent(targetchem)) + if(P.reagents.has_reagent(targetchem, chemamount)) pillcount-- if(pillcount <= 0) return TRUE