From 584d6a3e908568689a73ce4e8d3e645c8f9553a5 Mon Sep 17 00:00:00 2001 From: Drsmail Date: Wed, 18 Dec 2024 21:26:24 +0300 Subject: [PATCH 01/19] Adds mindflayer to antag mix --- config/example/config.toml | 47 ++++++++++++++++++ .../antag_mix/scenarios/minor_scenarios.dm | 49 +++++++++++++++++++ 2 files changed, 96 insertions(+) diff --git a/config/example/config.toml b/config/example/config.toml index 0f3cdf9abd87..9a06e1741da4 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1149,6 +1149,53 @@ tag = "blood_brothers" "Solar Federation General", ] +[[antag_mix_gamemode_configuration.antag_scenarios_configuration]] +tag = "mindflayer" + +[antag_mix_gamemode_configuration.antag_scenarios_configuration.params] +"required_players" = 1 +"cost" = 1 +"weight" = 1 +"antag_cap" = 1 +"candidates_required" = 1 +"restricted_roles" = ["Cyborg", "AI", "Chaplain"] +"protected_roles" = [ + "Security Cadet", + "Security Officer", + "Warden", + "Detective", + "Head of Security", + "Captain", + "Blueshield", + "Nanotrasen Representative", + "Magistrate", + "Internal Affairs Agent", + "Nanotrasen Navy Officer", + "Special Operations Officer", + "Solar Federation General", +] +"restricted_species" = [ + "Abductor", + "Diona", + "Drask", + "Golem", + "Grey", + "Human", + "Kidan", + "Machine", + "Monkey", + "Moth", + "Plasmaman", + "Shadow", + "Skeleton_species", + "Skrell", + "Slimepeople", + "Tajaran", + "Unathi", + "Vox", + "Vulpkanin" +] + [[antag_mix_gamemode_configuration.antag_scenarios_configuration]] tag = "vox_raiders" diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index f0f2c7ae1aad..e82e82b3b334 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -87,6 +87,55 @@ "Solar Federation General") restricted_species = list("Machine") +/datum/antag_scenario/Mindflayer + name = "Mindflayer" + config_tag = "mindflayer" + abstract = FALSE + antag_role = ROLE_MIND_FLAYER + antag_special_role = SPECIAL_ROLE_MIND_FLAYER + antag_datum = /datum/antagonist/mindflayer + required_players = 10 + cost = 10 + weight = 1 + antag_cap = 1 + candidates_required = 1 + restricted_roles = list("Cyborg", "AI", "Chaplain") + protected_roles = list( + "Security Cadet", + "Security Officer", + "Warden", + "Detective", + "Head of Security", + "Captain", + "Blueshield", + "Nanotrasen Representative", + "Magistrate", + "Internal Affairs Agent", + "Nanotrasen Navy Officer", + "Special Operations Officer", + "Syndicate Officer", + "Solar Federation General") + restricted_species = list( + "Abductor", + "Diona", + "Drask", + "Golem", + "Grey", + "Human", + "Kidan", + "Machine", + "Monkey", + "Moth", + "Plasmaman", + "Shadow", + "Skeleton_species", + "Skrell", + "Slimepeople", + "Tajaran", + "Unathi", + "Vox", + "Vulpkanin") + /datum/antag_scenario/team/blood_brothers name = "Blood Brothers" config_tag = "blood_brothers" From 33c94811bb2fdee7dea8c9bb4246d15aaec34a44 Mon Sep 17 00:00:00 2001 From: Drsmail Date: Wed, 18 Dec 2024 21:35:24 +0300 Subject: [PATCH 02/19] snake_case_fix --- .../antagonists/code/antag_mix/scenarios/minor_scenarios.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index e82e82b3b334..5997270e2d2e 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -87,7 +87,7 @@ "Solar Federation General") restricted_species = list("Machine") -/datum/antag_scenario/Mindflayer +/datum/antag_scenario/mindflayer name = "Mindflayer" config_tag = "mindflayer" abstract = FALSE From 637e9e59b3a65dbef1e7cb95499c340e2f7d8bd5 Mon Sep 17 00:00:00 2001 From: Drsmail Date: Wed, 18 Dec 2024 23:44:50 +0300 Subject: [PATCH 03/19] proper config settings --- config/example/config.toml | 1 + .../antagonists/code/antag_mix/scenarios/minor_scenarios.dm | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/config/example/config.toml b/config/example/config.toml index 9a06e1741da4..5752dcf436f6 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1174,6 +1174,7 @@ tag = "mindflayer" "Special Operations Officer", "Solar Federation General", ] +possible_species = ["Machine"] "restricted_species" = [ "Abductor", "Diona", diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index 5997270e2d2e..fc831b670b20 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -94,7 +94,7 @@ antag_role = ROLE_MIND_FLAYER antag_special_role = SPECIAL_ROLE_MIND_FLAYER antag_datum = /datum/antagonist/mindflayer - required_players = 10 + required_players = 1 cost = 10 weight = 1 antag_cap = 1 @@ -115,6 +115,7 @@ "Special Operations Officer", "Syndicate Officer", "Solar Federation General") + possible_species = list("Machine") restricted_species = list( "Abductor", "Diona", From 4949f479ddf937342c12c632744324b1f3c209b1 Mon Sep 17 00:00:00 2001 From: Drsmail Date: Thu, 19 Dec 2024 00:49:14 +0300 Subject: [PATCH 04/19] Updated proper config --- config/example/config.toml | 21 ------------------- .../antag_mix/scenarios/minor_scenarios.dm | 21 +------------------ 2 files changed, 1 insertion(+), 41 deletions(-) diff --git a/config/example/config.toml b/config/example/config.toml index 5752dcf436f6..d344a885a330 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1175,27 +1175,6 @@ tag = "mindflayer" "Solar Federation General", ] possible_species = ["Machine"] -"restricted_species" = [ - "Abductor", - "Diona", - "Drask", - "Golem", - "Grey", - "Human", - "Kidan", - "Machine", - "Monkey", - "Moth", - "Plasmaman", - "Shadow", - "Skeleton_species", - "Skrell", - "Slimepeople", - "Tajaran", - "Unathi", - "Vox", - "Vulpkanin" -] [[antag_mix_gamemode_configuration.antag_scenarios_configuration]] tag = "vox_raiders" diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index fc831b670b20..43b7930567bd 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -116,26 +116,7 @@ "Syndicate Officer", "Solar Federation General") possible_species = list("Machine") - restricted_species = list( - "Abductor", - "Diona", - "Drask", - "Golem", - "Grey", - "Human", - "Kidan", - "Machine", - "Monkey", - "Moth", - "Plasmaman", - "Shadow", - "Skeleton_species", - "Skrell", - "Slimepeople", - "Tajaran", - "Unathi", - "Vox", - "Vulpkanin") + /datum/antag_scenario/team/blood_brothers name = "Blood Brothers" From ebda1985040b8696793f271a0903e030030b5079 Mon Sep 17 00:00:00 2001 From: Drsmail Date: Thu, 19 Dec 2024 03:55:15 +0300 Subject: [PATCH 05/19] =?UTF-8?q?=D0=A3=D0=B1=D1=80=D0=B0=D0=BB=20=D1=81?= =?UTF-8?q?=D0=B2=D0=B5=D1=82=D0=BE=D1=88=D1=83=20=D0=B8=D0=B7=20=D1=87?= =?UTF-8?q?=D1=91=D1=80=D0=BD=D0=BE=D0=B3=D0=BE=20=D1=81=D0=BF=D0=B8=D1=81?= =?UTF-8?q?=D0=BA=D0=B0=20=D1=80=D0=BE=D0=BB=D0=B5=D0=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config/example/config.toml | 2 +- .../antagonists/code/antag_mix/scenarios/minor_scenarios.dm | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/config/example/config.toml b/config/example/config.toml index d344a885a330..23f693da64a4 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1158,7 +1158,7 @@ tag = "mindflayer" "weight" = 1 "antag_cap" = 1 "candidates_required" = 1 -"restricted_roles" = ["Cyborg", "AI", "Chaplain"] +"restricted_roles" = ["Cyborg", "AI"] "protected_roles" = [ "Security Cadet", "Security Officer", diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index 43b7930567bd..408c3f390a1a 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -99,7 +99,7 @@ weight = 1 antag_cap = 1 candidates_required = 1 - restricted_roles = list("Cyborg", "AI", "Chaplain") + restricted_roles = list("Cyborg", "AI") protected_roles = list( "Security Cadet", "Security Officer", @@ -117,7 +117,6 @@ "Solar Federation General") possible_species = list("Machine") - /datum/antag_scenario/team/blood_brothers name = "Blood Brothers" config_tag = "blood_brothers" From 8d5db07e66caa303c46b42dd713babedf4c6633a Mon Sep 17 00:00:00 2001 From: Drsmail Date: Thu, 19 Dec 2024 22:27:59 +0300 Subject: [PATCH 06/19] No more human mind Flayers --- config/example/config.toml | 24 ++++++++++++++++++- .../antag_mix/scenarios/minor_scenarios.dm | 21 ++++++++++++++++ 2 files changed, 44 insertions(+), 1 deletion(-) diff --git a/config/example/config.toml b/config/example/config.toml index 23f693da64a4..7ee11bfad8d2 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1174,7 +1174,29 @@ tag = "mindflayer" "Special Operations Officer", "Solar Federation General", ] -possible_species = ["Machine"] +"possible_species" = ["Machine"] + +"restricted_species" = [ + "Abductor", + "Ancient Skeleton", + "Diona", + "Drask", + "Golem", + "Grey", + "Human", + "Kidan", + "Monkey, + "Nian", + "Plasmaman, + "Shadow", + "Skrell", + "Slime People", + "Tajaran", + "Unathi", + "Vox", + "Vulpkanin", + "Nucleation", +] [[antag_mix_gamemode_configuration.antag_scenarios_configuration]] tag = "vox_raiders" diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index 408c3f390a1a..e56c56c2f0dd 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -117,6 +117,27 @@ "Solar Federation General") possible_species = list("Machine") + restricted_species = list( + "Abductor", + "Ancient Skeleton", + "Diona", + "Drask", + "Golem", + "Grey", + "Human", + "Kidan", + "Monkey", + "Nian", + "Plasmaman", + "Shadow", + "Skrell", + "Slime People", + "Tajaran", + "Unathi", + "Vox", + "Vulpkanin", + "Nucleation") + /datum/antag_scenario/team/blood_brothers name = "Blood Brothers" config_tag = "blood_brothers" From f8b7db7e0e0a1b7254a373f470c448b8b22ac805 Mon Sep 17 00:00:00 2001 From: Drsmail Date: Thu, 19 Dec 2024 22:49:58 +0300 Subject: [PATCH 07/19] Fix Moth --- config/example/config.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/config/example/config.toml b/config/example/config.toml index 7ee11bfad8d2..28d008d88b8e 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1185,9 +1185,9 @@ tag = "mindflayer" "Grey", "Human", "Kidan", - "Monkey, - "Nian", - "Plasmaman, + "Monkey", + "Moth", + "Plasmaman", "Shadow", "Skrell", "Slime People", From 875825501c4be2dcfd777f392645b4129ed05add Mon Sep 17 00:00:00 2001 From: Drsmail Date: Tue, 24 Dec 2024 01:15:52 +0300 Subject: [PATCH 08/19] Added blacklist for antag mix --- config/example/config.toml | 24 +------------------ .../antag_mix/scenarios/antag_scenario.dm | 9 ++++++- .../antag_mix/scenarios/minor_scenarios.dm | 22 +---------------- 3 files changed, 10 insertions(+), 45 deletions(-) diff --git a/config/example/config.toml b/config/example/config.toml index 28d008d88b8e..838bc4243adc 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1174,29 +1174,7 @@ tag = "mindflayer" "Special Operations Officer", "Solar Federation General", ] -"possible_species" = ["Machine"] - -"restricted_species" = [ - "Abductor", - "Ancient Skeleton", - "Diona", - "Drask", - "Golem", - "Grey", - "Human", - "Kidan", - "Monkey", - "Moth", - "Plasmaman", - "Shadow", - "Skrell", - "Slime People", - "Tajaran", - "Unathi", - "Vox", - "Vulpkanin", - "Nucleation", -] +"allowed_species" = ["Machine"] [[antag_mix_gamemode_configuration.antag_scenarios_configuration]] tag = "vox_raiders" diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm index 211792b72c83..ed9b4271da6d 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm @@ -37,6 +37,8 @@ var/list/protected_roles = list() /// Species that can't be chosen for the scenario var/list/restricted_species = list() + /// Only species that can be chosen for the scenario + var/list/allowed_species = list("All") /// List of available candidates for this scenario var/list/mob/new_player/candidates = list() /// List of players that were drafted to be antagonists of this scenario @@ -176,6 +178,7 @@ for(var/mob/new_player/candidate as anything in candidates) var/client/candidate_client = candidate.client var/datum/mind/candidate_mind = candidate.mind + var/my_specie = candidate_client.prefs.active_character.species if(!candidate_client || !candidate_mind || !candidate.ready) candidates.Remove(candidate) continue @@ -196,7 +199,11 @@ candidates.Remove(candidate) continue - if(!(antag_role in candidate.client.prefs.be_special) || (candidate.client.prefs.active_character.species in restricted_species)) + if(!(antag_role in candidate_client.prefs.be_special) || (my_specie in restricted_species)) + candidates.Remove(candidate) + continue + + if(!(("All" in allowed_species) || (my_specie in allowed_species))) candidates.Remove(candidate) continue diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index e56c56c2f0dd..ebffa5ec040c 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -115,28 +115,8 @@ "Special Operations Officer", "Syndicate Officer", "Solar Federation General") - possible_species = list("Machine") - restricted_species = list( - "Abductor", - "Ancient Skeleton", - "Diona", - "Drask", - "Golem", - "Grey", - "Human", - "Kidan", - "Monkey", - "Nian", - "Plasmaman", - "Shadow", - "Skrell", - "Slime People", - "Tajaran", - "Unathi", - "Vox", - "Vulpkanin", - "Nucleation") + allowed_species = list("Machine") /datum/antag_scenario/team/blood_brothers name = "Blood Brothers" From 17851af8055015409e795484b57bad95cbbebdf7 Mon Sep 17 00:00:00 2001 From: Drsmail Date: Wed, 18 Dec 2024 21:26:24 +0300 Subject: [PATCH 09/19] Adds mindflayer to antag mix --- config/example/config.toml | 24 +++++++++++++++-- .../antag_mix/scenarios/minor_scenarios.dm | 27 ++++++++++++++++--- 2 files changed, 45 insertions(+), 6 deletions(-) diff --git a/config/example/config.toml b/config/example/config.toml index 23f693da64a4..9a06e1741da4 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1158,7 +1158,7 @@ tag = "mindflayer" "weight" = 1 "antag_cap" = 1 "candidates_required" = 1 -"restricted_roles" = ["Cyborg", "AI"] +"restricted_roles" = ["Cyborg", "AI", "Chaplain"] "protected_roles" = [ "Security Cadet", "Security Officer", @@ -1174,7 +1174,27 @@ tag = "mindflayer" "Special Operations Officer", "Solar Federation General", ] -possible_species = ["Machine"] +"restricted_species" = [ + "Abductor", + "Diona", + "Drask", + "Golem", + "Grey", + "Human", + "Kidan", + "Machine", + "Monkey", + "Moth", + "Plasmaman", + "Shadow", + "Skeleton_species", + "Skrell", + "Slimepeople", + "Tajaran", + "Unathi", + "Vox", + "Vulpkanin" +] [[antag_mix_gamemode_configuration.antag_scenarios_configuration]] tag = "vox_raiders" diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index 408c3f390a1a..e82e82b3b334 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -87,19 +87,19 @@ "Solar Federation General") restricted_species = list("Machine") -/datum/antag_scenario/mindflayer +/datum/antag_scenario/Mindflayer name = "Mindflayer" config_tag = "mindflayer" abstract = FALSE antag_role = ROLE_MIND_FLAYER antag_special_role = SPECIAL_ROLE_MIND_FLAYER antag_datum = /datum/antagonist/mindflayer - required_players = 1 + required_players = 10 cost = 10 weight = 1 antag_cap = 1 candidates_required = 1 - restricted_roles = list("Cyborg", "AI") + restricted_roles = list("Cyborg", "AI", "Chaplain") protected_roles = list( "Security Cadet", "Security Officer", @@ -115,7 +115,26 @@ "Special Operations Officer", "Syndicate Officer", "Solar Federation General") - possible_species = list("Machine") + restricted_species = list( + "Abductor", + "Diona", + "Drask", + "Golem", + "Grey", + "Human", + "Kidan", + "Machine", + "Monkey", + "Moth", + "Plasmaman", + "Shadow", + "Skeleton_species", + "Skrell", + "Slimepeople", + "Tajaran", + "Unathi", + "Vox", + "Vulpkanin") /datum/antag_scenario/team/blood_brothers name = "Blood Brothers" From 6f9277c06a75cffdd218a3769d0584f315e102dc Mon Sep 17 00:00:00 2001 From: Drsmail Date: Wed, 18 Dec 2024 21:35:24 +0300 Subject: [PATCH 10/19] snake_case_fix --- .../antagonists/code/antag_mix/scenarios/minor_scenarios.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index e82e82b3b334..5997270e2d2e 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -87,7 +87,7 @@ "Solar Federation General") restricted_species = list("Machine") -/datum/antag_scenario/Mindflayer +/datum/antag_scenario/mindflayer name = "Mindflayer" config_tag = "mindflayer" abstract = FALSE From 2c2916fd864a9dc9098e1fbdc29cf9de5b44b42b Mon Sep 17 00:00:00 2001 From: Drsmail Date: Wed, 18 Dec 2024 23:44:50 +0300 Subject: [PATCH 11/19] proper config settings --- config/example/config.toml | 1 + .../antagonists/code/antag_mix/scenarios/minor_scenarios.dm | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/config/example/config.toml b/config/example/config.toml index 9a06e1741da4..5752dcf436f6 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1174,6 +1174,7 @@ tag = "mindflayer" "Special Operations Officer", "Solar Federation General", ] +possible_species = ["Machine"] "restricted_species" = [ "Abductor", "Diona", diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index 5997270e2d2e..fc831b670b20 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -94,7 +94,7 @@ antag_role = ROLE_MIND_FLAYER antag_special_role = SPECIAL_ROLE_MIND_FLAYER antag_datum = /datum/antagonist/mindflayer - required_players = 10 + required_players = 1 cost = 10 weight = 1 antag_cap = 1 @@ -115,6 +115,7 @@ "Special Operations Officer", "Syndicate Officer", "Solar Federation General") + possible_species = list("Machine") restricted_species = list( "Abductor", "Diona", From 5d5531a92113359d5ebac5ff8814c0feb4ea1ca8 Mon Sep 17 00:00:00 2001 From: Drsmail Date: Thu, 19 Dec 2024 00:49:14 +0300 Subject: [PATCH 12/19] Updated proper config --- config/example/config.toml | 21 ------------------- .../antag_mix/scenarios/minor_scenarios.dm | 21 +------------------ 2 files changed, 1 insertion(+), 41 deletions(-) diff --git a/config/example/config.toml b/config/example/config.toml index 5752dcf436f6..d344a885a330 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1175,27 +1175,6 @@ tag = "mindflayer" "Solar Federation General", ] possible_species = ["Machine"] -"restricted_species" = [ - "Abductor", - "Diona", - "Drask", - "Golem", - "Grey", - "Human", - "Kidan", - "Machine", - "Monkey", - "Moth", - "Plasmaman", - "Shadow", - "Skeleton_species", - "Skrell", - "Slimepeople", - "Tajaran", - "Unathi", - "Vox", - "Vulpkanin" -] [[antag_mix_gamemode_configuration.antag_scenarios_configuration]] tag = "vox_raiders" diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index fc831b670b20..43b7930567bd 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -116,26 +116,7 @@ "Syndicate Officer", "Solar Federation General") possible_species = list("Machine") - restricted_species = list( - "Abductor", - "Diona", - "Drask", - "Golem", - "Grey", - "Human", - "Kidan", - "Machine", - "Monkey", - "Moth", - "Plasmaman", - "Shadow", - "Skeleton_species", - "Skrell", - "Slimepeople", - "Tajaran", - "Unathi", - "Vox", - "Vulpkanin") + /datum/antag_scenario/team/blood_brothers name = "Blood Brothers" From 2c94248a6b67c37e47e21477feb6631315a110cf Mon Sep 17 00:00:00 2001 From: Drsmail Date: Thu, 19 Dec 2024 03:55:15 +0300 Subject: [PATCH 13/19] =?UTF-8?q?=D0=A3=D0=B1=D1=80=D0=B0=D0=BB=20=D1=81?= =?UTF-8?q?=D0=B2=D0=B5=D1=82=D0=BE=D1=88=D1=83=20=D0=B8=D0=B7=20=D1=87?= =?UTF-8?q?=D1=91=D1=80=D0=BD=D0=BE=D0=B3=D0=BE=20=D1=81=D0=BF=D0=B8=D1=81?= =?UTF-8?q?=D0=BA=D0=B0=20=D1=80=D0=BE=D0=BB=D0=B5=D0=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config/example/config.toml | 2 +- .../antagonists/code/antag_mix/scenarios/minor_scenarios.dm | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/config/example/config.toml b/config/example/config.toml index d344a885a330..23f693da64a4 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1158,7 +1158,7 @@ tag = "mindflayer" "weight" = 1 "antag_cap" = 1 "candidates_required" = 1 -"restricted_roles" = ["Cyborg", "AI", "Chaplain"] +"restricted_roles" = ["Cyborg", "AI"] "protected_roles" = [ "Security Cadet", "Security Officer", diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index 43b7930567bd..408c3f390a1a 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -99,7 +99,7 @@ weight = 1 antag_cap = 1 candidates_required = 1 - restricted_roles = list("Cyborg", "AI", "Chaplain") + restricted_roles = list("Cyborg", "AI") protected_roles = list( "Security Cadet", "Security Officer", @@ -117,7 +117,6 @@ "Solar Federation General") possible_species = list("Machine") - /datum/antag_scenario/team/blood_brothers name = "Blood Brothers" config_tag = "blood_brothers" From 0c0e06a15278a7ae6811f65ed0a41326c5ab0371 Mon Sep 17 00:00:00 2001 From: Drsmail Date: Thu, 19 Dec 2024 22:27:59 +0300 Subject: [PATCH 14/19] No more human mind Flayers --- config/example/config.toml | 24 ++++++++++++++++++- .../antag_mix/scenarios/minor_scenarios.dm | 21 ++++++++++++++++ 2 files changed, 44 insertions(+), 1 deletion(-) diff --git a/config/example/config.toml b/config/example/config.toml index 23f693da64a4..7ee11bfad8d2 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1174,7 +1174,29 @@ tag = "mindflayer" "Special Operations Officer", "Solar Federation General", ] -possible_species = ["Machine"] +"possible_species" = ["Machine"] + +"restricted_species" = [ + "Abductor", + "Ancient Skeleton", + "Diona", + "Drask", + "Golem", + "Grey", + "Human", + "Kidan", + "Monkey, + "Nian", + "Plasmaman, + "Shadow", + "Skrell", + "Slime People", + "Tajaran", + "Unathi", + "Vox", + "Vulpkanin", + "Nucleation", +] [[antag_mix_gamemode_configuration.antag_scenarios_configuration]] tag = "vox_raiders" diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index 408c3f390a1a..e56c56c2f0dd 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -117,6 +117,27 @@ "Solar Federation General") possible_species = list("Machine") + restricted_species = list( + "Abductor", + "Ancient Skeleton", + "Diona", + "Drask", + "Golem", + "Grey", + "Human", + "Kidan", + "Monkey", + "Nian", + "Plasmaman", + "Shadow", + "Skrell", + "Slime People", + "Tajaran", + "Unathi", + "Vox", + "Vulpkanin", + "Nucleation") + /datum/antag_scenario/team/blood_brothers name = "Blood Brothers" config_tag = "blood_brothers" From 187239ac41706ad4ff505414f373d4f9ce638c5b Mon Sep 17 00:00:00 2001 From: Drsmail Date: Thu, 19 Dec 2024 22:49:58 +0300 Subject: [PATCH 15/19] Fix Moth --- config/example/config.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/config/example/config.toml b/config/example/config.toml index 7ee11bfad8d2..28d008d88b8e 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1185,9 +1185,9 @@ tag = "mindflayer" "Grey", "Human", "Kidan", - "Monkey, - "Nian", - "Plasmaman, + "Monkey", + "Moth", + "Plasmaman", "Shadow", "Skrell", "Slime People", From 129347e856ad625620b30ec227f09b252f32d31e Mon Sep 17 00:00:00 2001 From: Drsmail Date: Tue, 24 Dec 2024 01:15:52 +0300 Subject: [PATCH 16/19] Added blacklist for antag mix --- config/example/config.toml | 24 +------------------ .../antag_mix/scenarios/antag_scenario.dm | 9 ++++++- .../antag_mix/scenarios/minor_scenarios.dm | 22 +---------------- 3 files changed, 10 insertions(+), 45 deletions(-) diff --git a/config/example/config.toml b/config/example/config.toml index 28d008d88b8e..838bc4243adc 100644 --- a/config/example/config.toml +++ b/config/example/config.toml @@ -1174,29 +1174,7 @@ tag = "mindflayer" "Special Operations Officer", "Solar Federation General", ] -"possible_species" = ["Machine"] - -"restricted_species" = [ - "Abductor", - "Ancient Skeleton", - "Diona", - "Drask", - "Golem", - "Grey", - "Human", - "Kidan", - "Monkey", - "Moth", - "Plasmaman", - "Shadow", - "Skrell", - "Slime People", - "Tajaran", - "Unathi", - "Vox", - "Vulpkanin", - "Nucleation", -] +"allowed_species" = ["Machine"] [[antag_mix_gamemode_configuration.antag_scenarios_configuration]] tag = "vox_raiders" diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm index 211792b72c83..ed9b4271da6d 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm @@ -37,6 +37,8 @@ var/list/protected_roles = list() /// Species that can't be chosen for the scenario var/list/restricted_species = list() + /// Only species that can be chosen for the scenario + var/list/allowed_species = list("All") /// List of available candidates for this scenario var/list/mob/new_player/candidates = list() /// List of players that were drafted to be antagonists of this scenario @@ -176,6 +178,7 @@ for(var/mob/new_player/candidate as anything in candidates) var/client/candidate_client = candidate.client var/datum/mind/candidate_mind = candidate.mind + var/my_specie = candidate_client.prefs.active_character.species if(!candidate_client || !candidate_mind || !candidate.ready) candidates.Remove(candidate) continue @@ -196,7 +199,11 @@ candidates.Remove(candidate) continue - if(!(antag_role in candidate.client.prefs.be_special) || (candidate.client.prefs.active_character.species in restricted_species)) + if(!(antag_role in candidate_client.prefs.be_special) || (my_specie in restricted_species)) + candidates.Remove(candidate) + continue + + if(!(("All" in allowed_species) || (my_specie in allowed_species))) candidates.Remove(candidate) continue diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index e56c56c2f0dd..ebffa5ec040c 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -115,28 +115,8 @@ "Special Operations Officer", "Syndicate Officer", "Solar Federation General") - possible_species = list("Machine") - restricted_species = list( - "Abductor", - "Ancient Skeleton", - "Diona", - "Drask", - "Golem", - "Grey", - "Human", - "Kidan", - "Monkey", - "Nian", - "Plasmaman", - "Shadow", - "Skrell", - "Slime People", - "Tajaran", - "Unathi", - "Vox", - "Vulpkanin", - "Nucleation") + allowed_species = list("Machine") /datum/antag_scenario/team/blood_brothers name = "Blood Brothers" From bc9a2643d9cb3ee46454aac96d3478bc9cf2dbb3 Mon Sep 17 00:00:00 2001 From: Drsmail Date: Tue, 24 Dec 2024 02:22:07 +0300 Subject: [PATCH 17/19] =?UTF-8?q?=D0=9F=D0=B5=D1=80=D0=B5=D0=B8=D0=BC?= =?UTF-8?q?=D0=B5=D0=BD=D0=BE=D0=B2=D1=8B=D0=B2=D0=B0=D0=BD=D0=B8=D0=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modular_ss220/antagonists/code/antag_datum.dm | 6 ++--- .../antag_mix/scenarios/antag_scenario.dm | 25 ++++++++----------- .../antag_mix/scenarios/major_scenarios.dm | 5 ++-- .../code/vox_raider/vox_raider_datum.dm | 2 +- 4 files changed, 17 insertions(+), 21 deletions(-) diff --git a/modular_ss220/antagonists/code/antag_datum.dm b/modular_ss220/antagonists/code/antag_datum.dm index 30da48284bec..53c970ac02df 100644 --- a/modular_ss220/antagonists/code/antag_datum.dm +++ b/modular_ss220/antagonists/code/antag_datum.dm @@ -1,4 +1,4 @@ -/datum/antagonist/proc/make_body(loc_spawn, datum/mind/mind, try_use_preference = FALSE, species_name = null, list/possible_species) +/datum/antagonist/proc/make_body(loc_spawn, datum/mind/mind, try_use_preference = FALSE, species_name = null, list/species_pool) var/datum/character_save/character var/mob/living/carbon/human/H = mind.current if(!H) @@ -10,8 +10,8 @@ if(try_use_preference && client && client.prefs && length(client.prefs.character_saves)) var/temp_species_name = species_name if(!temp_species_name) - if(length(possible_species)) - temp_species_name = pick(possible_species) + if(length(species_pool)) + temp_species_name = pick(species_pool) else temp_species_name = "Human" for(var/datum/character_save/temp_character in client.prefs.character_saves) diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm index ed9b4271da6d..241b65c38249 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm @@ -37,8 +37,8 @@ var/list/protected_roles = list() /// Species that can't be chosen for the scenario var/list/restricted_species = list() - /// Only species that can be chosen for the scenario - var/list/allowed_species = list("All") + /// Only species that can be chosen for the scenario, null - for all + var/list/allowed_species = null /// List of available candidates for this scenario var/list/mob/new_player/candidates = list() /// List of players that were drafted to be antagonists of this scenario @@ -48,12 +48,12 @@ var/is_crew_antag = TRUE /// Spawn antagonist at landmark name var/obj/effect/landmark/spawner/landmark_type = /obj/effect/landmark/spawner/xeno - /// What species can be used for the antagonist - var/list/possible_species = list("Human") - /// Recommended species at prefs to increase the chance of getting a role for RP-experienced players + /// What species can be used to create antagonist + var/list/species_pool = null + // Recommended species at prefs to increase the chance of getting a role for RP-experienced players + // For example list("Vox" = 8) modifier that increases the chance of landing by 8 times var/list/recommended_species_active_pref - /// Multiplication modifier that increases the chance of landing by N times - var/recommended_species_mod = 0 + /datum/antag_scenario/New() if(abstract) @@ -203,7 +203,7 @@ candidates.Remove(candidate) continue - if(!(("All" in allowed_species) || (my_specie in allowed_species))) + if(!((isnull(allowed_species)) || (my_specie in allowed_species))) candidates.Remove(candidate) continue @@ -248,9 +248,9 @@ * Сreate characters if the antagonist is not from the crew. */ /datum/antag_scenario/proc/make_character(datum/mind/mind, turf/loc_spawn) - var/picked_species = pick(possible_species) + var/picked_species = pick(species_pool) var/datum/antagonist/temp_antag_datum = locate(antag_datum) in mind.antag_datums - temp_antag_datum.make_body(loc_spawn, mind, TRUE, picked_species, possible_species) + temp_antag_datum.make_body(loc_spawn, mind, TRUE, picked_species, species_pool) /datum/antag_scenario/proc/equip_character(datum/mind/mind) return TRUE @@ -261,9 +261,6 @@ if(!length(candidates)) return - if(!recommended_species_mod) - return - if(!length(recommended_species_active_pref)) return @@ -271,6 +268,6 @@ var/list/datum/character_save/characters = candidate.client.prefs.character_saves for(var/datum/character_save/character in characters) if(character.species in recommended_species_active_pref) - candidates[candidate] = recommended_species_mod + candidates[candidate] = recommended_species_active_pref[character.species] else candidates[candidate] = 1 diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/major_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/major_scenarios.dm index 44efb1b899a4..d46c22f8319a 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/major_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/major_scenarios.dm @@ -17,9 +17,8 @@ is_crew_antag = FALSE landmark_type = /obj/effect/landmark/spawner/vox_raider - possible_species = list("Vox") - recommended_species_active_pref = list("Vox") - recommended_species_mod = 8 + species_pool = list("Vox") + recommended_species_active_pref = list("Vox" = 8) /datum/antag_scenario/team/vox_raiders/equip_character(datum/mind/mind) diff --git a/modular_ss220/antagonists/code/vox_raider/vox_raider_datum.dm b/modular_ss220/antagonists/code/vox_raider/vox_raider_datum.dm index b906b61023b7..fc5dfd27d679 100644 --- a/modular_ss220/antagonists/code/vox_raider/vox_raider_datum.dm +++ b/modular_ss220/antagonists/code/vox_raider/vox_raider_datum.dm @@ -147,6 +147,6 @@ if(mind.current) H.equipOutfit(/datum/outfit/vox, visualsOnly) -/datum/antagonist/vox_raider/make_body(spawn_loc, datum/mind/mind, try_use_preference = FALSE, species_name = null, list/possible_species) +/datum/antagonist/vox_raider/make_body(spawn_loc, datum/mind/mind, try_use_preference = FALSE, species_name = null, list/species_pool) . = ..() mind.store_memory(" Я Вокс-Рейдер, основа моя: беречь стаю, тащить ценности. .") From bf1ec1063cff3322a21c4dc1debd5532fc7e5022 Mon Sep 17 00:00:00 2001 From: Drsmail Date: Tue, 24 Dec 2024 16:10:07 +0300 Subject: [PATCH 18/19] =?UTF-8?q?=D0=92=D0=BE=D0=BA=D1=81=D1=8B=20=D0=B8?= =?UTF-8?q?=D1=81=D0=BF=D0=BE=D0=BB=D1=8C=D0=B7=D1=83=D1=8E=D1=82=20=D0=B8?= =?UTF-8?q?=D0=BC=D0=B5=D0=BD=D0=B0=20=D0=B8=D0=B3=D1=80=D0=BE=D0=BA=D0=BE?= =?UTF-8?q?=D0=B2,=20=D0=B0=20=D0=BA=D0=BE=D0=B4=20=D0=BF=D0=BE=D0=B4?= =?UTF-8?q?=D1=82=D0=B4=D0=B5=D1=80=D0=B6=D0=B8=D0=B2=D0=B0=D0=B5=D1=82=20?= =?UTF-8?q?=D0=BD=D0=B5=D1=81=D0=BA=D0=BE=D0=BB=D1=8C=D0=BA=D0=BE=20=D1=80?= =?UTF-8?q?=D0=B0=D1=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modular_ss220/antagonists/code/antag_datum.dm | 24 ++++++++++--------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/modular_ss220/antagonists/code/antag_datum.dm b/modular_ss220/antagonists/code/antag_datum.dm index 53c970ac02df..312890178106 100644 --- a/modular_ss220/antagonists/code/antag_datum.dm +++ b/modular_ss220/antagonists/code/antag_datum.dm @@ -8,18 +8,20 @@ var/client/client = mind.current.client if(try_use_preference && client && client.prefs && length(client.prefs.character_saves)) - var/temp_species_name = species_name - if(!temp_species_name) - if(length(species_pool)) - temp_species_name = pick(species_pool) - else - temp_species_name = "Human" + var/list/species_pool_to_use + if(species_name) + species_pool_to_use.Add(species_name) + else + species_pool_to_use = species_pool + + var/list/eligible_characters for(var/datum/character_save/temp_character in client.prefs.character_saves) - if(temp_character.species == temp_species_name) - character = temp_character - species_name = temp_species_name - new_name = random_name(character.gender, character.species) - break + for(var/temp_species_name in species_pool_to_use) + if(temp_character.species == temp_species_name) + eligible_characters.Add(temp_character) + + if(eligible_characters.len > 0) + character = pick(eligible_characters) if(!character) // Randomize appearance From 2bdb32066548ed06f662c131ac0970e402732d00 Mon Sep 17 00:00:00 2001 From: Drsmail <60036448+Drsmail@users.noreply.github.com> Date: Thu, 26 Dec 2024 17:07:40 +0300 Subject: [PATCH 19/19] Apply suggestions from code review Co-authored-by: Mikhail Dzianishchyts --- .../code/antag_mix/scenarios/antag_scenario.dm | 15 +++++++-------- .../code/antag_mix/scenarios/minor_scenarios.dm | 1 - 2 files changed, 7 insertions(+), 9 deletions(-) diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm index 241b65c38249..ed2813bd6791 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/antag_scenario.dm @@ -37,8 +37,8 @@ var/list/protected_roles = list() /// Species that can't be chosen for the scenario var/list/restricted_species = list() - /// Only species that can be chosen for the scenario, null - for all - var/list/allowed_species = null + /// Only species that can be chosen for the scenario. Consider empty list as no restriction. + var/list/allowed_species = list() /// List of available candidates for this scenario var/list/mob/new_player/candidates = list() /// List of players that were drafted to be antagonists of this scenario @@ -49,11 +49,10 @@ /// Spawn antagonist at landmark name var/obj/effect/landmark/spawner/landmark_type = /obj/effect/landmark/spawner/xeno /// What species can be used to create antagonist - var/list/species_pool = null + var/list/species_pool = list() // Recommended species at prefs to increase the chance of getting a role for RP-experienced players // For example list("Vox" = 8) modifier that increases the chance of landing by 8 times - var/list/recommended_species_active_pref - + var/list/recommended_species_active_pref = list() /datum/antag_scenario/New() if(abstract) @@ -178,7 +177,7 @@ for(var/mob/new_player/candidate as anything in candidates) var/client/candidate_client = candidate.client var/datum/mind/candidate_mind = candidate.mind - var/my_specie = candidate_client.prefs.active_character.species + var/candidate_species = candidate_client.prefs.active_character.species if(!candidate_client || !candidate_mind || !candidate.ready) candidates.Remove(candidate) continue @@ -199,11 +198,11 @@ candidates.Remove(candidate) continue - if(!(antag_role in candidate_client.prefs.be_special) || (my_specie in restricted_species)) + if(!(antag_role in candidate_client.prefs.be_special) || (candidate_species in restricted_species)) candidates.Remove(candidate) continue - if(!((isnull(allowed_species)) || (my_specie in allowed_species))) + if(allowed_species && !(candidate_species in allowed_species)) candidates.Remove(candidate) continue diff --git a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm index ebffa5ec040c..ac3e7c7979c2 100644 --- a/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm +++ b/modular_ss220/antagonists/code/antag_mix/scenarios/minor_scenarios.dm @@ -115,7 +115,6 @@ "Special Operations Officer", "Syndicate Officer", "Solar Federation General") - allowed_species = list("Machine") /datum/antag_scenario/team/blood_brothers