diff --git a/code/__HELPERS/roundend.dm b/code/__HELPERS/roundend.dm index 9ba1c767b7..3b346f7e1c 100644 --- a/code/__HELPERS/roundend.dm +++ b/code/__HELPERS/roundend.dm @@ -47,7 +47,7 @@ antag_info["antagonist_name"] = A.name //For auto and custom roles antag_info["objectives"] = list() antag_info["team"] = list() - var/datum/objective_team/T = A.get_team() + var/datum/team/T = A.get_team() if(T) antag_info["team"]["type"] = T.type antag_info["team"]["name"] = T.name @@ -84,9 +84,9 @@ //Set news report and mode result mode.set_round_result() - + send2irc("Server", "Round just ended.") - + if(CONFIG_GET(string/cross_server_address)) send_news_report() @@ -142,15 +142,15 @@ parts += mode.special_report() CHECK_TICK - + //AI laws parts += law_report() - + CHECK_TICK //Antagonists parts += antag_report() - + CHECK_TICK //Medals parts += medal_report() @@ -202,7 +202,7 @@ /datum/controller/subsystem/ticker/proc/show_roundend_report(client/C,common_report) var/list/report_parts = list() - + report_parts += personal_report(C) report_parts += common_report @@ -212,7 +212,7 @@ roundend_report.set_content(report_parts.Join()) roundend_report.stylesheets = list() roundend_report.add_stylesheet("roundend",'html/browser/roundend.css') - + roundend_report.open(0) /datum/controller/subsystem/ticker/proc/personal_report(client/C) @@ -311,7 +311,7 @@ all_teams |= A.get_team() all_antagonists += A - for(var/datum/objective_team/T in all_teams) + for(var/datum/team/T in all_teams) result += T.roundend_report() for(var/datum/antagonist/X in all_antagonists) if(X.get_team() == T) @@ -336,7 +336,7 @@ previous_category = A result += A.roundend_report() result += "
" - + if(all_antagonists.len) var/datum/antagonist/last = all_antagonists[all_antagonists.len] result += last.roundend_report_footer() diff --git a/code/datums/antagonists/abductor.dm b/code/datums/antagonists/abductor.dm index 3b8935d9fa..a98acf054e 100644 --- a/code/datums/antagonists/abductor.dm +++ b/code/datums/antagonists/abductor.dm @@ -2,7 +2,7 @@ name = "Abductor" roundend_category = "abductors" job_rank = ROLE_ABDUCTOR - var/datum/objective_team/abductor_team/team + var/datum/team/abductor_team/team var/sub_role var/outfit var/landmark_type @@ -20,7 +20,7 @@ landmark_type = /obj/effect/landmark/abductor/scientist greet_text = "Use your stealth technology and equipment to incapacitate humans for your scientist to retrieve." -/datum/antagonist/abductor/create_team(datum/objective_team/abductor_team/new_team) +/datum/antagonist/abductor/create_team(datum/team/abductor_team/new_team) if(!new_team) return if(!istype(new_team)) @@ -73,20 +73,20 @@ A.scientist = TRUE -/datum/objective_team/abductor_team - member_name = "abductor" +/datum/team/abductor_team + member_name = "abductor" var/team_number var/list/datum/mind/abductees = list() -/datum/objective_team/abductor_team/is_solo() +/datum/team/abductor_team/is_solo() return FALSE -/datum/objective_team/abductor_team/proc/add_objective(datum/objective/O) +/datum/team/abductor_team/proc/add_objective(datum/objective/O) O.team = src O.update_explanation_text() objectives += O -/datum/objective_team/abductor_team/roundend_report() +/datum/team/abductor_team/roundend_report() var/list/result = list() var/won = TRUE @@ -127,7 +127,7 @@ var/datum/objective/abductee/O = new objtype() objectives += O owner.objectives += objectives - + /datum/antagonist/abductee/apply_innate_effects(mob/living/mob_override) SSticker.mode.update_abductor_icons_added(mob_override ? mob_override.mind : owner) diff --git a/code/datums/antagonists/antag_datum.dm b/code/datums/antagonists/antag_datum.dm index 6b5a573eff..9b5dbb6d75 100644 --- a/code/datums/antagonists/antag_datum.dm +++ b/code/datums/antagonists/antag_datum.dm @@ -49,7 +49,7 @@ GLOBAL_LIST_EMPTY(antagonists) return //Assign default team and creates one for one of a kind team antagonists -/datum/antagonist/proc/create_team(datum/objective_team/team) +/datum/antagonist/proc/create_team(datum/team/team) return //Proc called when the datum is given to a mind. @@ -84,7 +84,7 @@ GLOBAL_LIST_EMPTY(antagonists) LAZYREMOVE(owner.antag_datums, src) if(!silent && owner.current) farewell() - var/datum/objective_team/team = get_team() + var/datum/team/team = get_team() if(team) team.remove_member(owner) qdel(src) @@ -155,6 +155,6 @@ GLOBAL_LIST_EMPTY(antagonists) else already_registered_objectives |= A.objectives objectives = owner.objectives - already_registered_objectives - + //This one is created by admin tools for custom objectives /datum/antagonist/custom \ No newline at end of file diff --git a/code/datums/antagonists/brother.dm b/code/datums/antagonists/brother.dm index dd3bdef9d2..b06c75e4fa 100644 --- a/code/datums/antagonists/brother.dm +++ b/code/datums/antagonists/brother.dm @@ -2,12 +2,12 @@ name = "Brother" job_rank = ROLE_BROTHER var/special_role = "blood brother" - var/datum/objective_team/brother_team/team + var/datum/team/brother_team/team /datum/antagonist/brother/New(datum/mind/new_owner) return ..() -/datum/antagonist/brother/create_team(datum/objective_team/brother_team/new_team) +/datum/antagonist/brother/create_team(datum/team/brother_team/new_team) if(!new_team) return if(!istype(new_team)) @@ -57,15 +57,15 @@ SSticker.mode.update_brother_icons_added(owner) -/datum/objective_team/brother_team +/datum/team/brother_team name = "brotherhood" member_name = "blood brother" var/meeting_area -/datum/objective_team/brother_team/is_solo() +/datum/team/brother_team/is_solo() return FALSE -/datum/objective_team/brother_team/proc/update_name() +/datum/team/brother_team/proc/update_name() var/list/last_names = list() for(var/datum/mind/M in members) var/list/split_name = splittext(M.name," ") @@ -73,7 +73,7 @@ name = last_names.Join(" & ") -/datum/objective_team/brother_team/roundend_report() +/datum/team/brother_team/roundend_report() var/list/parts = list() parts += "The blood brothers of [name] were:" @@ -95,14 +95,14 @@ return "
[parts.Join("
")]
" -/datum/objective_team/brother_team/proc/add_objective(datum/objective/O, needs_target = FALSE) +/datum/team/brother_team/proc/add_objective(datum/objective/O, needs_target = FALSE) O.team = src if(needs_target) O.find_target() O.update_explanation_text() objectives += O -/datum/objective_team/brother_team/proc/forge_brother_objectives() +/datum/team/brother_team/proc/forge_brother_objectives() objectives = list() var/is_hijacker = prob(10) for(var/i = 1 to max(1, CONFIG_GET(number/brother_objectives_amount) + (members.len > 2) - is_hijacker)) @@ -113,7 +113,7 @@ else if(!locate(/datum/objective/escape) in objectives) add_objective(new/datum/objective/escape) -/datum/objective_team/brother_team/proc/forge_single_objective() +/datum/team/brother_team/proc/forge_single_objective() if(prob(50)) if(LAZYLEN(active_ais()) && prob(100/GLOB.joined_player_list.len)) add_objective(new/datum/objective/destroy, TRUE) diff --git a/code/datums/antagonists/clockcult.dm b/code/datums/antagonists/clockcult.dm index 5f99ccc5dd..48f9b53425 100644 --- a/code/datums/antagonists/clockcult.dm +++ b/code/datums/antagonists/clockcult.dm @@ -4,7 +4,7 @@ roundend_category = "clock cultists" job_rank = ROLE_SERVANT_OF_RATVAR var/datum/action/innate/hierophant/hierophant_network = new() - var/datum/objective_team/clockcult/clock_team + var/datum/team/clockcult/clock_team var/make_team = TRUE //This should be only false for tutorial scarabs /datum/antagonist/clockcult/silent @@ -17,14 +17,14 @@ /datum/antagonist/clockcult/get_team() return clock_team -/datum/antagonist/clockcult/create_team(datum/objective_team/clockcult/new_team) +/datum/antagonist/clockcult/create_team(datum/team/clockcult/new_team) if(!new_team && make_team) //TODO blah blah same as the others, allow multiple for(var/datum/antagonist/clockcult/H in GLOB.antagonists) if(H.clock_team) clock_team = H.clock_team return - clock_team = new /datum/objective_team/clockcult + clock_team = new /datum/team/clockcult return if(make_team && !istype(new_team)) stack_trace("Wrong team type passed to [type] initialization.") @@ -175,7 +175,7 @@ SSticker.mode.servants_of_ratvar -= owner SSticker.mode.update_servant_icons_removed(owner) if(!silent) - owner.current.visible_message("[owner] seems to have remembered their true allegiance!", ignored_mob = owner.current) + owner.current.visible_message("[owner] seems to have remembered their true allegiance!", ignored_mob = owner.current) to_chat(owner, "A cold, cold darkness flows through your mind, extinguishing the Justiciar's light and all of your memories as his servant.") owner.current.log_message("Has renounced the cult of Ratvar!", INDIVIDUAL_ATTACK_LOG) owner.wipe_memory() @@ -185,19 +185,19 @@ . = ..() -/datum/objective_team/clockcult +/datum/team/clockcult name = "Clockcult" var/list/objective var/datum/mind/eminence -/datum/objective_team/clockcult/proc/check_clockwork_victory() +/datum/team/clockcult/proc/check_clockwork_victory() if(GLOB.clockwork_gateway_activated) return TRUE return FALSE -/datum/objective_team/clockcult/roundend_report() +/datum/team/clockcult/roundend_report() var/list/parts = list() - + if(check_clockwork_victory()) parts += "Ratvar's servants defended the Ark until its activation!" else @@ -213,5 +213,5 @@ if(members.len) parts += "Ratvar's servants were:" parts += printplayerlist(members - eminence) - + return "
[parts.Join("
")]
" \ No newline at end of file diff --git a/code/datums/antagonists/cult.dm b/code/datums/antagonists/cult.dm index bce9123fb3..916123ddff 100644 --- a/code/datums/antagonists/cult.dm +++ b/code/datums/antagonists/cult.dm @@ -9,19 +9,19 @@ var/ignore_implant = FALSE var/give_equipment = FALSE - var/datum/objective_team/cult/cult_team + var/datum/team/cult/cult_team /datum/antagonist/cult/get_team() return cult_team -/datum/antagonist/cult/create_team(datum/objective_team/cult/new_team) +/datum/antagonist/cult/create_team(datum/team/cult/new_team) if(!new_team) //todo remove this and allow admin buttons to create more than one cult for(var/datum/antagonist/cult/H in GLOB.antagonists) if(H.cult_team) cult_team = H.cult_team return - cult_team = new /datum/objective_team/cult + cult_team = new /datum/team/cult cult_team.setup_objectives() return if(!istype(new_team)) @@ -59,7 +59,7 @@ SSticker.mode.cult += owner // Only add after they've been given objectives SSticker.mode.update_cult_icons_added(owner) current.log_message("Has been converted to the cult of Nar'Sie!", INDIVIDUAL_ATTACK_LOG) - + if(cult_team.blood_target && cult_team.blood_target_image && current.client) current.client.images += cult_team.blood_target_image @@ -183,28 +183,28 @@ current.update_action_buttons_icon() current.remove_status_effect(/datum/status_effect/cult_master) -/datum/objective_team/cult +/datum/team/cult name = "Cult" var/blood_target var/image/blood_target_image var/blood_target_reset_timer - + var/cult_vote_called = FALSE var/cult_mastered = FALSE var/reckoning_complete = FALSE -/datum/objective_team/cult/proc/setup_objectives() +/datum/team/cult/proc/setup_objectives() //SAC OBJECTIVE , todo: move this to objective internals var/list/target_candidates = list() var/datum/objective/sacrifice/sac_objective = new sac_objective.team = src - + for(var/mob/living/carbon/human/player in GLOB.player_list) if(player.mind && !player.mind.has_antag_datum(ANTAG_DATUM_CULT) && !is_convertable_to_cult(player) && player.stat != DEAD) target_candidates += player.mind - + if(target_candidates.len == 0) message_admins("Cult Sacrifice: Could not find unconvertable target, checking for convertable target.") for(var/mob/living/carbon/human/player in GLOB.player_list) @@ -214,7 +214,7 @@ if(LAZYLEN(target_candidates)) sac_objective.target = pick(target_candidates) sac_objective.update_explanation_text() - + var/datum/job/sacjob = SSjob.GetJob(sac_objective.target.assigned_role) var/datum/preferences/sacface = sac_objective.target.current.client.prefs var/icon/reshape = get_flat_human_icon(null, sacjob, sacface) @@ -235,7 +235,7 @@ summon_objective.team = src objectives += summon_objective -/datum/objective/sacrifice +/datum/objective/sacrifice var/sacced = FALSE var/sac_image @@ -268,13 +268,13 @@ /datum/objective/eldergod/check_completion() return summoned || completed -/datum/objective_team/cult/proc/check_cult_victory() +/datum/team/cult/proc/check_cult_victory() for(var/datum/objective/O in objectives) if(!O.check_completion()) return FALSE return TRUE -/datum/objective_team/cult/roundend_report() +/datum/team/cult/roundend_report() var/list/parts = list() if(check_cult_victory()) @@ -291,9 +291,9 @@ else parts += "Objective #[count]: [objective.explanation_text] Fail." count++ - + if(members.len) parts += "The cultists were:" parts += printplayerlist(members) - + return "
[parts.Join("
")]
" \ No newline at end of file diff --git a/code/datums/antagonists/pirate.dm b/code/datums/antagonists/pirate.dm index e0ce38c1e4..9bf20a4bf5 100644 --- a/code/datums/antagonists/pirate.dm +++ b/code/datums/antagonists/pirate.dm @@ -2,7 +2,7 @@ name = "Space Pirate" job_rank = ROLE_TRAITOR roundend_category = "space pirates" - var/datum/objective_team/pirate/crew + var/datum/team/pirate/crew /datum/antagonist/pirate/greet() to_chat(owner, "You are a Space Pirate!") @@ -12,15 +12,16 @@ /datum/antagonist/pirate/get_team() return crew -/datum/antagonist/pirate/create_team(datum/objective_team/pirate/new_team) +/datum/antagonist/pirate/create_team(datum/team/pirate/new_team) if(!new_team) for(var/datum/antagonist/pirate/P in GLOB.antagonists) if(P.crew) - new_team = P.crew + crew = P.crew + return if(!new_team) - crew = new /datum/objective_team/pirate + crew = new /datum/team/pirate crew.forge_objectives() - return + return if(!istype(new_team)) stack_trace("Wrong team type passed to [type] initialization.") crew = new_team @@ -35,10 +36,10 @@ owner.objectives -= crew.objectives . = ..() -/datum/objective_team/pirate +/datum/team/pirate name = "Pirate crew" -/datum/objective_team/pirate/proc/forge_objectives() +/datum/team/pirate/proc/forge_objectives() var/datum/objective/loot/getbooty = new() getbooty.team = src getbooty.storage_area = locate(/area/shuttle/pirate/vault) in GLOB.sortedAreas @@ -104,13 +105,11 @@ GLOBAL_LIST_INIT(pirate_loot_cache, typecacheof(list( /datum/objective/loot/check_completion() return ..() || get_loot_value() >= target_value - - -/datum/objective_team/pirate/roundend_report() +/datum/team/pirate/roundend_report() var/list/parts = list() parts += "Space Pirates were:" - + var/all_dead = TRUE for(var/datum/mind/M in members) if(considered_alive(M)) @@ -126,5 +125,5 @@ GLOBAL_LIST_INIT(pirate_loot_cache, typecacheof(list( parts += "The pirate crew was successful!" else parts += "The pirate crew has failed." - - return parts.Join("
") \ No newline at end of file + + return "
[parts.Join("
")]
" \ No newline at end of file diff --git a/code/datums/antagonists/revolution.dm b/code/datums/antagonists/revolution.dm index 14c6d1ab0e..3209b9221c 100644 --- a/code/datums/antagonists/revolution.dm +++ b/code/datums/antagonists/revolution.dm @@ -6,7 +6,7 @@ roundend_category = "revolutionaries" // if by some miracle revolutionaries without revolution happen job_rank = ROLE_REV var/hud_type = "rev" - var/datum/objective_team/revolution/rev_team + var/datum/team/revolution/rev_team /datum/antagonist/rev/can_be_owned(datum/mind/new_owner) . = ..() @@ -40,17 +40,17 @@ . = ..() /datum/antagonist/rev/greet() - to_chat(owner, " You are now a revolutionary! Help your cause. Do not harm your fellow freedom fighters. You can identify your comrades by the red \"R\" icons, and your leaders by the blue \"R\" icons. Help them kill the heads to win the revolution!") + to_chat(owner, "You are now a revolutionary! Help your cause. Do not harm your fellow freedom fighters. You can identify your comrades by the red \"R\" icons, and your leaders by the blue \"R\" icons. Help them kill the heads to win the revolution!") owner.announce_objectives() -/datum/antagonist/rev/create_team(datum/objective_team/revolution/new_team) +/datum/antagonist/rev/create_team(datum/team/revolution/new_team) if(!new_team) //For now only one revolution at a time for(var/datum/antagonist/rev/head/H in GLOB.antagonists) if(H.rev_team) rev_team = H.rev_team return - rev_team = new /datum/objective_team/revolution + rev_team = new /datum/team/revolution rev_team.update_objectives() rev_team.update_heads() return @@ -78,7 +78,7 @@ old_owner.add_antag_datum(new_revhead,old_team) new_revhead.silent = FALSE to_chat(old_owner, "You have proved your devotion to revolution! You are a head revolutionary now!") - + /datum/antagonist/rev/head name = "Head Revolutionary" @@ -132,14 +132,14 @@ old_owner.add_antag_datum(new_rev,old_team) new_rev.silent = FALSE to_chat(old_owner, "Revolution has been disappointed of your leader traits! You are a regular revolutionary now!") - + /datum/antagonist/rev/farewell() if(ishuman(owner.current)) - owner.current.visible_message("[owner.current] looks like they just remembered their real allegiance!") - to_chat(owner, "You are no longer a brainwashed revolutionary! Your memory is hazy from the time you were a rebel...the only thing you remember is the name of the one who brainwashed you...") + owner.current.visible_message("[owner.current] looks like they just remembered their real allegiance!", ignored_mob = owner.current) + to_chat(owner, "You are no longer a brainwashed revolutionary! Your memory is hazy from the time you were a rebel...the only thing you remember is the name of the one who brainwashed you...") else if(issilicon(owner.current)) - owner.current.visible_message("The frame beeps contentedly, purging the hostile memory engram from the MMI before initalizing it.") - to_chat(owner, "The frame's firmware detects and deletes your neural reprogramming! You remember nothing but the name of the one who flashed you.") + owner.current.visible_message("The frame beeps contentedly, purging the hostile memory engram from the MMI before initalizing it.", ignored_mob = owner.current) + to_chat(owner, "The frame's firmware detects and deletes your neural reprogramming! You remember nothing but the name of the one who flashed you.") /datum/antagonist/rev/proc/remove_revolutionary(borged, deconverter) log_attack("[owner.current] (Key: [key_name(owner.current)]) has been deconverted from the revolution by [deconverter] (Key: [key_name(deconverter)])!") @@ -164,7 +164,7 @@ if(remove_clumsy && owner.assigned_role == "Clown") to_chat(owner, "Your training has allowed you to overcome your clownish nature, allowing you to wield weapons without harming yourself.") H.dna.remove_mutation(CLOWNMUT) - + if(give_flash) var/obj/item/device/assembly/flash/T = new(H) var/list/slots = list ( @@ -177,17 +177,17 @@ to_chat(H, "The Syndicate were unfortunately unable to get you a flash.") else to_chat(H, "The flash in your [where] will help you to persuade the crew to join your cause.") - + if(give_hud) var/obj/item/organ/cyberimp/eyes/hud/security/syndicate/S = new(H) S.Insert(H, special = FALSE, drop_if_replaced = FALSE) to_chat(H, "Your eyes have been implanted with a cybernetic security HUD which will help you keep track of who is mindshield-implanted, and therefore unable to be recruited.") -/datum/objective_team/revolution +/datum/team/revolution name = "Revolution" var/max_headrevs = 3 -/datum/objective_team/revolution/proc/update_objectives(initial = FALSE) +/datum/team/revolution/proc/update_objectives(initial = FALSE) var/untracked_heads = SSjob.get_all_heads() for(var/datum/objective/mutiny/O in objectives) untracked_heads -= O.target @@ -199,16 +199,16 @@ objectives += new_target for(var/datum/mind/M in members) M.objectives |= objectives - + addtimer(CALLBACK(src,.proc/update_objectives),HEAD_UPDATE_PERIOD,TIMER_UNIQUE) -/datum/objective_team/revolution/proc/head_revolutionaries() +/datum/team/revolution/proc/head_revolutionaries() . = list() for(var/datum/mind/M in members) if(M.has_antag_datum(/datum/antagonist/rev/head)) . += M -/datum/objective_team/revolution/proc/update_heads() +/datum/team/revolution/proc/update_heads() if(SSticker.HasRoundStarted()) var/list/datum/mind/head_revolutionaries = head_revolutionaries() var/list/datum/mind/heads = SSjob.get_all_heads() @@ -229,7 +229,7 @@ addtimer(CALLBACK(src,.proc/update_heads),HEAD_UPDATE_PERIOD,TIMER_UNIQUE) -/datum/objective_team/revolution/roundend_report() +/datum/team/revolution/roundend_report() if(!members.len) return diff --git a/code/datums/antagonists/wizard.dm b/code/datums/antagonists/wizard.dm index 7f23215d6c..e856a6642f 100644 --- a/code/datums/antagonists/wizard.dm +++ b/code/datums/antagonists/wizard.dm @@ -11,7 +11,7 @@ var/strip = TRUE //strip before equipping var/allow_rename = TRUE var/hud_version = "wizard" - var/datum/objective_team/wizard/wiz_team //Only created if wizard summons apprentices + var/datum/team/wizard/wiz_team //Only created if wizard summons apprentices var/move_to_lair = TRUE var/outfit_type = /datum/outfit/wizard var/wiz_age = WIZARD_AGE_MIN /* Wizards by nature cannot be too young. */ @@ -33,7 +33,7 @@ /datum/antagonist/wizard/proc/unregister() SSticker.mode.wizards -= src -/datum/antagonist/wizard/create_team(datum/objective_team/wizard/new_team) +/datum/antagonist/wizard/create_team(datum/team/wizard/new_team) if(!new_team) return if(!istype(new_team)) @@ -43,7 +43,7 @@ /datum/antagonist/wizard/get_team() return wiz_team -/datum/objective_team/wizard +/datum/team/wizard name = "wizard team" var/datum/antagonist/wizard/master_wizard @@ -307,18 +307,18 @@ parts += "The wizard was successful!" else parts += "The wizard has failed!" - + if(owner.spell_list.len>0) parts += "[owner.name] used the following spells: " var/list/spell_names = list() for(var/obj/effect/proc_holder/spell/S in owner.spell_list) spell_names += S.name parts += spell_names.Join(", ") - + return parts.Join("
") //Wizard with apprentices report -/datum/objective_team/wizard/roundend_report() +/datum/team/wizard/roundend_report() var/list/parts = list() parts += "Wizards/witches of [master_wizard.owner.name] team were:" @@ -326,5 +326,5 @@ parts += " " parts += "[master_wizard.owner.name] apprentices were:" parts += printplayerlist(members - master_wizard.owner) - + return "
[parts.Join("
")]
" \ No newline at end of file diff --git a/code/datums/mind.dm b/code/datums/mind.dm index dbbb30e231..231ce66f28 100644 --- a/code/datums/mind.dm +++ b/code/datums/mind.dm @@ -149,7 +149,7 @@ return LAZYADD(antag_datums, A) A.create_team(team) - var/datum/objective_team/antag_team = A.get_team() + var/datum/team/antag_team = A.get_team() if(antag_team) antag_team.add_member(src) A.on_gain() @@ -206,7 +206,7 @@ var/datum/antagonist/nukeop/nuke = has_antag_datum(/datum/antagonist/nukeop,TRUE) if(nuke) remove_antag_datum(nuke.type) -special_role = null + special_role = null /datum/mind/proc/remove_wizard() remove_antag_datum(/datum/antagonist/wizard) @@ -333,7 +333,7 @@ special_role = null N.send_to_spawnpoint = FALSE N.nukeop_outfit = null add_antag_datum(N,converter.nuke_team) - + enslaved_to = creator @@ -775,13 +775,13 @@ special_role = null objective = locate(href_list["obj_edit"]) if (!objective) return - + for(var/datum/antagonist/A in antag_datums) if(objective in A.objectives) target_antag = A objective_pos = A.objectives.Find(objective) break - + if(!target_antag) //Shouldn't happen stack_trace("objective without antagonist found") objective_pos = objectives.Find(objective) @@ -943,7 +943,7 @@ special_role = null var/datum/objective/objective = locate(href_list["obj_delete"]) if(!istype(objective)) return - + for(var/datum/antagonist/A in antag_datums) if(objective in A.objectives) A.objectives -= objective diff --git a/code/game/gamemodes/antag_spawner.dm b/code/game/gamemodes/antag_spawner.dm index e413f0ebaf..d8ba1f5fa1 100644 --- a/code/game/gamemodes/antag_spawner.dm +++ b/code/game/gamemodes/antag_spawner.dm @@ -73,7 +73,7 @@ C.prefs.copy_to(M) M.key = C.key var/datum/mind/app_mind = M.mind - + var/datum/antagonist/wizard/apprentice/app = new(app_mind) app.master = user app.school = kind @@ -165,7 +165,7 @@ var/datum/antagonist/nukeop/creator_op = user.has_antag_datum(/datum/antagonist/nukeop,TRUE) if(!creator_op) return - + switch(borg_to_spawn) if("Medical") R = new /mob/living/silicon/robot/modules/syndicate/medical(T) @@ -187,7 +187,7 @@ R.real_name = R.name R.key = C.key - + var/datum/antagonist/nukeop/new_borg = new(R.mind) new_borg.send_to_spawnpoint = FALSE R.mind.add_antag_datum(new_borg,creator_op.nuke_team) diff --git a/code/game/gamemodes/brother/traitor_bro.dm b/code/game/gamemodes/brother/traitor_bro.dm index 978f871ba2..609f5bb6ab 100644 --- a/code/game/gamemodes/brother/traitor_bro.dm +++ b/code/game/gamemodes/brother/traitor_bro.dm @@ -1,6 +1,6 @@ /datum/game_mode var/list/datum/mind/brothers = list() - var/list/datum/objective_team/brother_team/brother_teams = list() + var/list/datum/team/brother_team/brother_teams = list() /datum/game_mode/traitor/bros name = "traitor+brothers" @@ -13,7 +13,7 @@ Blood Brothers: Accomplish your objectives.\n\ Crew: Do not let the traitors or brothers succeed!" - var/list/datum/objective_team/brother_team/pre_brother_teams = list() + var/list/datum/team/brother_team/pre_brother_teams = list() var/const/team_amount = 2 //hard limit on brother teams if scaling is turned off var/const/min_team_size = 2 traitors_required = FALSE //Only teams are possible @@ -36,7 +36,7 @@ for(var/j = 1 to num_teams) if(possible_brothers.len < min_team_size || antag_candidates.len <= required_enemies) break - var/datum/objective_team/brother_team/team = new + var/datum/team/brother_team/team = new var/team_size = prob(10) ? min(3, possible_brothers.len) : 2 for(var/k = 1 to team_size) var/datum/mind/bro = pick(possible_brothers) @@ -49,7 +49,7 @@ return ..() /datum/game_mode/traitor/bros/post_setup() - for(var/datum/objective_team/brother_team/team in pre_brother_teams) + for(var/datum/team/brother_team/team in pre_brother_teams) team.meeting_area = pick(meeting_areas) meeting_areas -= team.meeting_area team.forge_brother_objectives() diff --git a/code/game/gamemodes/clock_cult/clock_cult.dm b/code/game/gamemodes/clock_cult/clock_cult.dm index 778cf41022..e4f75ea563 100644 --- a/code/game/gamemodes/clock_cult/clock_cult.dm +++ b/code/game/gamemodes/clock_cult/clock_cult.dm @@ -112,8 +112,8 @@ Credit where due: var/servants_to_serve = list() var/roundstart_player_count var/ark_time //In minutes, how long the Ark waits before activation; this is equal to 30 + (number of players / 5) (max 40 mins.) - - var/datum/objective_team/clockcult/main_clockcult + + var/datum/team/clockcult/main_clockcult /datum/game_mode/clockwork_cult/pre_setup() if(CONFIG_GET(flag/protect_roles_from_antagonist)) @@ -189,10 +189,9 @@ Credit where due: return FALSE /datum/game_mode/clockwork_cult/check_finished() - var/obj/structure/destructible/clockwork/massive/celestial_gateway/G = GLOB.ark_of_the_clockwork_justiciar - if(G && !GLOB.ratvar_awakens) // Doesn't end until the Ark is destroyed or completed + if(GLOB.ark_of_the_clockwork_justiciar && !GLOB.ratvar_awakens) // Doesn't end until the Ark is destroyed or completed return FALSE - . = ..() + return ..() /datum/game_mode/clockwork_cult/proc/check_clockwork_victory() return main_clockcult.check_clockwork_victory() diff --git a/code/game/gamemodes/cult/cult.dm b/code/game/gamemodes/cult/cult.dm index 67e2225772..697a5c8eba 100644 --- a/code/game/gamemodes/cult/cult.dm +++ b/code/game/gamemodes/cult/cult.dm @@ -6,13 +6,13 @@ /proc/iscultist(mob/living/M) return istype(M) && M.mind && M.mind.has_antag_datum(ANTAG_DATUM_CULT) -/datum/objective_team/cult/proc/is_sacrifice_target(datum/mind/mind) +/datum/team/cult/proc/is_sacrifice_target(datum/mind/mind) for(var/datum/objective/sacrifice/sac_objective in objectives) if(mind == sac_objective.target) return TRUE return FALSE - -/proc/is_convertable_to_cult(mob/living/M,datum/objective_team/cult/specific_cult) + +/proc/is_convertable_to_cult(mob/living/M,datum/team/cult/specific_cult) if(!istype(M)) return FALSE if(M.mind) @@ -54,7 +54,7 @@ var/list/cultists_to_cult = list() //the cultists we'll convert - var/datum/objective_team/cult/main_cult + var/datum/team/cult/main_cult /datum/game_mode/cult/pre_setup() @@ -96,7 +96,7 @@ var/datum/antagonist/cult/new_cultist = new(cult_mind) new_cultist.give_equipment = equip - + if(cult_mind.add_antag_datum(new_cultist)) if(stun) cult_mind.current.Unconscious(100) diff --git a/code/game/gamemodes/cult/cult_comms.dm b/code/game/gamemodes/cult/cult_comms.dm index 2938f5abf4..b809f2419c 100644 --- a/code/game/gamemodes/cult/cult_comms.dm +++ b/code/game/gamemodes/cult/cult_comms.dm @@ -30,7 +30,7 @@ user.whisper("O bidai nabora se[pick("'","`")]sma!", language = /datum/language/common) user.whisper(html_decode(message)) var/title = "Acolyte" - var/span = "cultitalic" + var/span = "cult italic" if(user.mind && user.mind.has_antag_datum(ANTAG_DATUM_CULT_MASTER)) span = "cultlarge" if(ishuman(user)) @@ -97,7 +97,7 @@ var/datum/antagonist/cult/C = owner.mind.has_antag_datum(/datum/antagonist/cult,TRUE) pollCultists(owner,C.cult_team) -/proc/pollCultists(var/mob/living/Nominee,datum/objective_team/cult/team) //Cult Master Poll +/proc/pollCultists(var/mob/living/Nominee,datum/team/cult/team) //Cult Master Poll if(world.time < CULT_POLL_WAIT) to_chat(Nominee, "It would be premature to select a leader while everyone is still settling in, try again in [DisplayTimeText(CULT_POLL_WAIT-world.time)].") return @@ -276,7 +276,7 @@ return FALSE var/datum/antagonist/cult/C = caller.mind.has_antag_datum(/datum/antagonist/cult,TRUE) - + if(target in view(7, get_turf(ranged_ability_user))) C.cult_team.blood_target = target var/area/A = get_area(target) @@ -297,7 +297,7 @@ return TRUE return FALSE -/proc/reset_blood_target(datum/objective_team/cult/team) +/proc/reset_blood_target(datum/team/cult/team) for(var/datum/mind/B in team.members) if(B.current && B.current.stat != DEAD && B.current.client) if(team.blood_target) diff --git a/code/game/gamemodes/cult/runes.dm b/code/game/gamemodes/cult/runes.dm index fc6a36376b..ff85499029 100644 --- a/code/game/gamemodes/cult/runes.dm +++ b/code/game/gamemodes/cult/runes.dm @@ -407,8 +407,8 @@ structure_check() searches for nearby cultist structures required for the invoca var/datum/antagonist/cult/C = first_invoker.mind.has_antag_datum(/datum/antagonist/cult,TRUE) if(!C) return - - + + var/big_sac = FALSE if((((ishuman(sacrificial) || iscyborg(sacrificial)) && sacrificial.stat != DEAD) || C.cult_team.is_sacrifice_target(sacrificial.mind)) && invokers.len < 3) for(var/M in invokers) @@ -510,10 +510,10 @@ structure_check() searches for nearby cultist structures required for the invoca message_admins("[key_name_admin(user)] erased a Narsie rune with a null rod") ..() -//Rite of Resurrection: Requires a dead or inactive cultist. When reviving the dead, you can only perform one revival for every sacrifice your cult has carried out. +//Rite of Resurrection: Requires the corpse of a cultist and that there have been less revives than the number of people GLOB.sacrificed /obj/effect/rune/raise_dead - cultist_name = "Revive Cultist" - cultist_desc = "requires a dead, mindless, or inactive cultist placed upon the rune. Provided there have been sufficient sacrifices, they will be given a new life." + cultist_name = "Resurrect Cultist" + cultist_desc = "requires the corpse of a cultist placed upon the rune. Provided there have been sufficient sacrifices, they will be revived." invocation = "Pasnar val'keriam usinar. Savrae ines amutan. Yam'toth remium il'tarat!" //Depends on the name of the user - see below icon_state = "1" color = RUNE_COLOR_MEDIUMRED @@ -534,11 +534,16 @@ structure_check() searches for nearby cultist structures required for the invoca return rune_in_use = TRUE for(var/mob/living/M in T.contents) - if(iscultist(M) && (M.stat == DEAD || !M.client || M.client.is_afk())) + if(iscultist(M) && M.stat == DEAD) potential_revive_mobs |= M if(!potential_revive_mobs.len) to_chat(user, "There are no dead cultists on the rune!") - log_game("Raise Dead rune failed - no cultists to revive") + log_game("Raise Dead rune failed - no corpses to revive") + fail_invoke() + rune_in_use = FALSE + return + if(LAZYLEN(GLOB.sacrificed) <= revives_used) + to_chat(user, "You have sacrificed too few people to revive a cultist!") fail_invoke() rune_in_use = FALSE return @@ -554,25 +559,9 @@ structure_check() searches for nearby cultist structures required for the invoca else invocation = initial(invocation) ..() - if(mob_to_revive.stat == DEAD) - if(LAZYLEN(GLOB.sacrificed) <= revives_used) - to_chat(user, "Your cult must carry out another sacrifice before it can revive a cultist!") - fail_invoke() - rune_in_use = FALSE - return - revives_used++ - mob_to_revive.revive(1, 1) //This does remove disabilities and such, but the rune might actually see some use because of it! - mob_to_revive.grab_ghost() - else if(!mob_to_revive.client || mob_to_revive.client.is_afk()) - set waitfor = FALSE - var/list/mob/dead/observer/candidates = pollCandidatesForMob("Do you want to play as a [mob_to_revive.name], an inactive blood cultist?", "[name]", null, "Blood Cultist", 50, mob_to_revive) - var/mob/dead/observer/theghost = null - if(candidates.len) - theghost = pick(candidates) - to_chat(mob_to_revive.mind, "Your physical form has been taken over by another soul due to your inactivity! Ahelp if you wish to regain your form.") - message_admins("[key_name_admin(theghost)] has taken control of ([key_name_admin(mob_to_revive)]) to replace an AFK player.") - mob_to_revive.ghostize(0) - mob_to_revive.key = theghost.key + revives_used++ + mob_to_revive.revive(1, 1) //This does remove disabilities and such, but the rune might actually see some use because of it! + mob_to_revive.grab_ghost() to_chat(mob_to_revive, "\"PASNAR SAVRAE YAM'TOTH. Arise.\"") mob_to_revive.visible_message("[mob_to_revive] draws in a huge breath, red light shining from [mob_to_revive.p_their()] eyes.", \ "You awaken suddenly from the void. You're alive!") diff --git a/code/game/gamemodes/game_mode.dm b/code/game/gamemodes/game_mode.dm index 344eb53507..a0e5a9f147 100644 --- a/code/game/gamemodes/game_mode.dm +++ b/code/game/gamemodes/game_mode.dm @@ -465,4 +465,4 @@ if(EMERGENCY_ESCAPED_OR_ENDGAMED) SSticker.news_report = STATION_EVACUATED if(SSshuttle.emergency.is_hijacked()) - SSticker.news_report = SHUTTLE_HIJACK + SSticker.news_report = SHUTTLE_HIJACK \ No newline at end of file diff --git a/code/game/gamemodes/miniantags/abduction/abduction.dm b/code/game/gamemodes/miniantags/abduction/abduction.dm index 050cac443d..f9e8f8d752 100644 --- a/code/game/gamemodes/miniantags/abduction/abduction.dm +++ b/code/game/gamemodes/miniantags/abduction/abduction.dm @@ -10,7 +10,7 @@ required_players = 15 maximum_players = 50 var/max_teams = 4 - var/list/datum/objective_team/abductor_team/abductor_teams = list() + var/list/datum/team/abductor_team/abductor_teams = list() var/finished = FALSE var/static/team_count = 0 @@ -37,7 +37,7 @@ if(team_number > max_teams) return //or should it try to stuff them in anway ? - var/datum/objective_team/abductor_team/team = new + var/datum/team/abductor_team/team = new team.team_number = team_number team.name = "Mothership [pick(GLOB.possible_changeling_IDs)]" //TODO Ensure unique and actual alieny names team.add_objective(new/datum/objective/experiment) @@ -50,6 +50,7 @@ antag_candidates -= scientist team.members |= scientist scientist.assigned_role = "Abductor Scientist" + scientist.special_role = "Abductor Scientist" log_game("[scientist.key] (ckey) has been selected as [team.name] abductor scientist.") if(!agent) @@ -57,18 +58,19 @@ antag_candidates -= agent team.members |= agent agent.assigned_role = "Abductor Agent" + agent.special_role = "Abductor Agent" log_game("[agent.key] (ckey) has been selected as [team.name] abductor agent.") abductor_teams += team return team /datum/game_mode/abduction/post_setup() - for(var/datum/objective_team/abductor_team/team in abductor_teams) + for(var/datum/team/abductor_team/team in abductor_teams) post_setup_team(team) return ..() //Used for create antag buttons -/datum/game_mode/abduction/proc/post_setup_team(datum/objective_team/abductor_team/team) +/datum/game_mode/abduction/proc/post_setup_team(datum/team/abductor_team/team) for(var/datum/mind/M in team.members) if(M.assigned_role == "Abductor Scientist") M.add_antag_datum(ANTAG_DATUM_ABDUCTOR_SCIENTIST, team) @@ -77,7 +79,7 @@ /datum/game_mode/abduction/check_finished() if(!finished) - for(var/datum/objective_team/abductor_team/team in abductor_teams) + for(var/datum/team/abductor_team/team in abductor_teams) for(var/datum/objective/O in team.objectives) if(O.check_completion()) SSshuttle.emergency.request(null, set_coefficient = 0.5) @@ -101,9 +103,9 @@ /datum/objective/experiment/check_completion() for(var/obj/machinery/abductor/experiment/E in GLOB.machines) - if(!istype(team, /datum/objective_team/abductor_team)) + if(!istype(team, /datum/team/abductor_team)) return FALSE - var/datum/objective_team/abductor_team/T = team + var/datum/team/abductor_team/T = team if(E.team_number == T.team_number) return E.points >= target_amount return FALSE diff --git a/code/game/gamemodes/nuclear/nuclear.dm b/code/game/gamemodes/nuclear/nuclear.dm index 4fcde56a72..890a3bb456 100644 --- a/code/game/gamemodes/nuclear/nuclear.dm +++ b/code/game/gamemodes/nuclear/nuclear.dm @@ -17,7 +17,7 @@ var/nukes_left = 1 // Call 3714-PRAY right now and order more nukes! Limited offer! var/list/pre_nukeops = list() - var/datum/objective_team/nuclear/nuke_team + var/datum/team/nuclear/nuke_team /datum/game_mode/nuclear/pre_setup() var/n_agents = min(round(num_players() / 10), antag_candidates.len, agents_possible) @@ -69,7 +69,8 @@ return FALSE //its a static var btw ..() -/datum/game_mode/nuclear/declare_completion() +/datum/game_mode/nuclear/set_round_result() + ..() var result = nuke_team.get_result() switch(result) if(NUKE_RESULT_FLUKE) @@ -102,22 +103,12 @@ else SSticker.mode_result = "halfwin - interrupted" SSticker.news_report = OPERATIVE_SKIRMISH - return ..() /datum/game_mode/nuclear/generate_report() return "One of Central Command's trading routes was recently disrupted by a raid carried out by the Gorlex Marauders. They seemed to only be after one ship - a highly-sensitive \ transport containing a nuclear fission explosive, although it is useless without the proper code and authorization disk. While the code was likely found in minutes, the only disk that \ can activate this explosive is on your station. Ensure that it is protected at all times, and remain alert for possible intruders." -/datum/game_mode/proc/auto_declare_completion_nuclear() - var/list/nuke_teams = list() - for(var/datum/antagonist/nukeop/N in GLOB.antagonists) //collect all nuke teams - nuke_teams |= N.nuke_team - for(var/datum/objective_team/nuclear/nuke_team in nuke_teams) - nuke_team.roundend_display() - return TRUE - - /proc/is_nuclear_operative(mob/M) return M && istype(M) && M.mind && M.mind.has_antag_datum(/datum/antagonist/nukeop) @@ -132,7 +123,8 @@ l_pocket = /obj/item/pinpointer/nuke/syndicate id = /obj/item/card/id/syndicate belt = /obj/item/gun/ballistic/automatic/pistol - backpack_contents = list(/obj/item/storage/box/syndie=1) + backpack_contents = list(/obj/item/storage/box/syndie=1,\ + /obj/item/kitchen/knife/combat/survival) var/tc = 25 var/command_radio = FALSE @@ -177,4 +169,5 @@ r_hand = /obj/item/gun/ballistic/automatic/shotgun/bulldog backpack_contents = list(/obj/item/storage/box/syndie=1,\ /obj/item/tank/jetpack/oxygen/harness=1,\ - /obj/item/gun/ballistic/automatic/pistol=1) + /obj/item/gun/ballistic/automatic/pistol=1,\ + /obj/item/kitchen/knife/combat/survival) diff --git a/code/game/gamemodes/revolution/revolution.dm b/code/game/gamemodes/revolution/revolution.dm index cbfdb98c69..f20e16b36b 100644 --- a/code/game/gamemodes/revolution/revolution.dm +++ b/code/game/gamemodes/revolution/revolution.dm @@ -26,7 +26,7 @@ var/finished = 0 var/check_counter = 0 var/max_headrevs = 3 - var/datum/objective_team/revolution/revolution + var/datum/team/revolution/revolution var/list/datum/mind/headrev_candidates = list() /////////////////////////// diff --git a/code/game/gamemodes/wizard/soulstone.dm b/code/game/gamemodes/wizard/soulstone.dm index 92c01bc241..8b80b9ab69 100644 --- a/code/game/gamemodes/wizard/soulstone.dm +++ b/code/game/gamemodes/wizard/soulstone.dm @@ -64,7 +64,6 @@ to_chat(user, "\"Come now, do not capture your bretheren's soul.\"") return add_logs(user, M, "captured [M.name]'s soul", src) - transfer_soul("VICTIM", M, user) ///////////////////Options for using captured souls/////////////////////////////////////// diff --git a/code/modules/admin/player_panel.dm b/code/modules/admin/player_panel.dm index b5d908d669..2a3812be3b 100644 --- a/code/modules/admin/player_panel.dm +++ b/code/modules/admin/player_panel.dm @@ -524,7 +524,7 @@ if(SSticker.mode.brother_teams.len > 0) dat += "
" - for(var/datum/objective_team/brother_team/team in SSticker.mode.brother_teams) + for(var/datum/team/brother_team/team in SSticker.mode.brother_teams) for(var/datum/mind/brother in team.members) var/mob/M = brother.current if(M) diff --git a/code/modules/admin/verbs/one_click_antag.dm b/code/modules/admin/verbs/one_click_antag.dm index 1d60f4f28d..ece3775872 100644 --- a/code/modules/admin/verbs/one_click_antag.dm +++ b/code/modules/admin/verbs/one_click_antag.dm @@ -240,14 +240,13 @@ //Let's find the spawn locations var/leader_chosen = FALSE - - var/datum/objective_team/nuclear/nuke_team + var/datum/team/nuclear/nuke_team for(var/mob/c in chosen) var/mob/living/carbon/human/new_character=makeBody(c) if(!leader_chosen) leader_chosen = TRUE var/datum/antagonist/nukeop/N = new_character.mind.add_antag_datum(/datum/antagonist/nukeop/leader) - nuke_team = N.nuke_team + nuke_team = N.nuke_team else new_character.mind.add_antag_datum(/datum/antagonist/nukeop,nuke_team) return 1 @@ -309,13 +308,13 @@ //Assign antag status and the mission SSticker.mode.traitors += Commando.mind Commando.mind.special_role = "deathsquad" - + var/datum/objective/missionobj = new missionobj.owner = Commando.mind missionobj.explanation_text = mission missionobj.completed = 1 Commando.mind.objectives += missionobj - + Commando.mind.add_antag_datum(/datum/antagonist/auto_custom) //Greet the commando @@ -364,13 +363,13 @@ //Assign antag status and the mission SSticker.mode.traitors += newmob.mind newmob.mind.special_role = "official" - + var/datum/objective/missionobj = new missionobj.owner = newmob.mind missionobj.explanation_text = mission missionobj.completed = 1 newmob.mind.objectives += missionobj - + newmob.mind.add_antag_datum(/datum/antagonist/auto_custom) if(CONFIG_GET(flag/enforce_human_authority)) @@ -472,7 +471,7 @@ //Assign antag status and the mission SSticker.mode.traitors += ERTOperative.mind ERTOperative.mind.special_role = "ERT" - + var/datum/objective/missionobj = new missionobj.owner = ERTOperative.mind missionobj.explanation_text = mission diff --git a/code/modules/power/singularity/narsie.dm b/code/modules/power/singularity/narsie.dm index 9801e98614..15b76d2641 100644 --- a/code/modules/power/singularity/narsie.dm +++ b/code/modules/power/singularity/narsie.dm @@ -50,7 +50,7 @@ var/list/all_cults = list() for(var/datum/antagonist/cult/C in GLOB.antagonists) all_cults |= C.cult_team - for(var/datum/objective_team/cult/T in all_cults) + for(var/datum/team/cult/T in all_cults) deltimer(T.blood_target_reset_timer) T.blood_target = src var/datum/objective/eldergod/summon_objective = locate() in T.objectives diff --git a/tgstation.dme b/tgstation.dme index 98b6a4dcab..64e5b2c686 100755 --- a/tgstation.dme +++ b/tgstation.dme @@ -490,6 +490,7 @@ #include "code\game\gamemodes\antag_hud.dm" #include "code\game\gamemodes\antag_spawner.dm" #include "code\game\gamemodes\antag_spawner_cit.dm" +#include "code\game\gamemodes\antag_team.dm" #include "code\game\gamemodes\cit_objectives.dm" #include "code\game\gamemodes\events.dm" #include "code\game\gamemodes\game_mode.dm" @@ -1305,8 +1306,8 @@ #include "code\modules\client\client_colour.dm" #include "code\modules\client\client_defines.dm" #include "code\modules\client\client_procs.dm" -#include "code\modules\client\player_details.dm" #include "code\modules\client\message.dm" +#include "code\modules\client\player_details.dm" #include "code\modules\client\preferences.dm" #include "code\modules\client\preferences_savefile.dm" #include "code\modules\client\preferences_toggles.dm"
Brothers