From e871d9cde4be295fb8aba8e64cb53758a2ca1b29 Mon Sep 17 00:00:00 2001
From: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>
Date: Tue, 25 Aug 2026 04:04:43 +0000
Subject: [PATCH] Fixes mind stuff (#32493)
---
code/datums/mind.dm | 5 +++++
code/game/gamemodes/game_mode.dm | 1 +
code/modules/admin/player_panel.dm | 2 ++
.../flockmind/actions/partition_mind.dm | 3 +--
.../flockmind/flock_camera/_flock_camera.dm | 1 +
.../flockmind/flock_mob/flockdrone.dm | 8 ++++----
code/modules/events/flockmind_event.dm | 19 ++++++++++---------
7 files changed, 24 insertions(+), 15 deletions(-)
diff --git a/code/datums/mind.dm b/code/datums/mind.dm
index 2b90d85bcd5..663da93f355 100644
--- a/code/datums/mind.dm
+++ b/code/datums/mind.dm
@@ -1901,6 +1901,11 @@
SSticker.mode.blob_overminds += src
special_role = SPECIAL_ROLE_BLOB_OVERMIND
+/datum/mind/proc/make_Flockmind()
+ if(!(src in SSticker.mode.flockminds))
+ SSticker.mode.flockminds += src
+ special_role = SPECIAL_ROLE_FLOCK
+
/datum/mind/proc/make_mind_flayer()
if(!has_antag_datum(/datum/antagonist/mindflayer))
add_antag_datum(/datum/antagonist/mindflayer)
diff --git a/code/game/gamemodes/game_mode.dm b/code/game/gamemodes/game_mode.dm
index f0257eb902a..2340b2d771f 100644
--- a/code/game/gamemodes/game_mode.dm
+++ b/code/game/gamemodes/game_mode.dm
@@ -38,6 +38,7 @@
var/list/datum/mind/xenos = list()
var/list/datum/mind/eventmiscs = list()
var/list/blob_overminds = list()
+ var/list/flockminds = list()
var/list/incursion_portals = list()
var/list/datum/station_goal/station_goals = list() // A list of all station goals for this game mode
diff --git a/code/modules/admin/player_panel.dm b/code/modules/admin/player_panel.dm
index 862a0a66cf9..8d09a597dd3 100644
--- a/code/modules/admin/player_panel.dm
+++ b/code/modules/admin/player_panel.dm
@@ -419,6 +419,8 @@
dat += "
| Head not found! |
"
dat += ""
+ if(length(SSticker.mode.flockminds))
+ dat += check_role_table("Flockminds", SSticker.mode.flockminds)
if(length(SSticker.mode.blob_overminds))
dat += check_role_table("Blob Overminds", SSticker.mode.blob_overminds)
diff --git a/code/modules/antagonists/flockmind/actions/partition_mind.dm b/code/modules/antagonists/flockmind/actions/partition_mind.dm
index 763a069f96f..f363eb6f2ac 100644
--- a/code/modules/antagonists/flockmind/actions/partition_mind.dm
+++ b/code/modules/antagonists/flockmind/actions/partition_mind.dm
@@ -71,8 +71,7 @@
new_ghostbird.mind = new
new_ghostbird.mind.bind_to(new_ghostbird)
new_ghostbird.mind.set_original_mob(new_ghostbird)
- new_ghostbird.mind.assigned_role = SPECIAL_ROLE_FLOCK
- new_ghostbird.mind.special_role = SPECIAL_ROLE_FLOCK
+ new_ghostbird.mind.make_Flockmind()
var/list/messages = list()
messages += "You are [gradient_text("The Divine Flock","#3cb5a3", "#124e43")]
"
messages += "" + gradient_text("We have been partitioned by our overmind to further their goals of propogating The Signal. It is our task to assist in managing their drones to achieve their goals. Such is the will of the Monarch.", "#3cb5a3", "#1e806e") + "
"
diff --git a/code/modules/antagonists/flockmind/flock_camera/_flock_camera.dm b/code/modules/antagonists/flockmind/flock_camera/_flock_camera.dm
index a9e3f16b6ba..fdcf69085d0 100644
--- a/code/modules/antagonists/flockmind/flock_camera/_flock_camera.dm
+++ b/code/modules/antagonists/flockmind/flock_camera/_flock_camera.dm
@@ -172,4 +172,5 @@
addtimer(CALLBACK(src, PROC_REF(cleanup)), 2 SECONDS)
/mob/camera/flock/proc/cleanup(datum/source)
+ SSticker.mode.flockminds -= mind
qdel(src)
diff --git a/code/modules/antagonists/flockmind/flock_mob/flockdrone.dm b/code/modules/antagonists/flockmind/flock_mob/flockdrone.dm
index 0691118d963..4000df6c0af 100644
--- a/code/modules/antagonists/flockmind/flock_mob/flockdrone.dm
+++ b/code/modules/antagonists/flockmind/flock_mob/flockdrone.dm
@@ -3,8 +3,6 @@
hud_type = /datum/hud/flockdrone
ai_controller = /datum/ai_controller/flock/drone
- move_force = MOVE_FORCE_WEAK
-
actions_to_grant = list(
/datum/action/cooldown/flock/release_control,
/datum/action/cooldown/flock/nest,
@@ -399,7 +397,8 @@
controlled_by.controlling_bird = src
if(controlled_by.mind)
- controlled_by.mind.transfer_to(src, FALSE)
+ key = controlled_by.key
+ mind = controlled_by.mind
if(isflocktrace(controlled_by))
flock.add_notice(src, FLOCK_NOTICE_FLOCKTRACE_CONTROL)
@@ -439,7 +438,8 @@
master_bird.forceMove(destination)
if(mind)
- mind.transfer_to(master_bird, FALSE)
+ master_bird.key = key
+ master_bird.mind = mind
flock_talk(null, "Control of [real_name] surrendered.", flock, involuntary = TRUE)
if(!dest_was_safe)
diff --git a/code/modules/events/flockmind_event.dm b/code/modules/events/flockmind_event.dm
index f840e5f158a..45026e63246 100644
--- a/code/modules/events/flockmind_event.dm
+++ b/code/modules/events/flockmind_event.dm
@@ -13,22 +13,22 @@
if(!length(candidates))
return kill()
- var/mob/C
+ var/mob/M
while(length(candidates))
- C = pick_n_take(candidates)
- if(jobban_isbanned(C, ROLE_TRAITOR))
+ M = pick_n_take(candidates)
+ if(jobban_isbanned(M, ROLE_TRAITOR))
continue
break
- if(!C)
+ if(!M)
kill()
return
- var/player_key = C.key
+ var/player_key = M.key
if(!player_key)
kill()
return
- dust_if_respawnable(C)
+ dust_if_respawnable(M)
var/list/spawn_locs = list()
for(var/obj/effect/landmark/spawner/flock/spawn_site in GLOB.landmarks_list)
spawn_locs += get_turf(spawn_site)
@@ -36,10 +36,11 @@
kill()
return
var/mob/camera/flock/overmind/flockmind = new /mob/camera/flock/overmind(pick(spawn_locs))
- C.mind.transfer_to(flockmind, FALSE)
+ flockmind.key = M.key
+ flockmind.mind = new
+ flockmind.mind.bind_to(flockmind)
flockmind.mind.set_original_mob(flockmind)
- flockmind.mind.assigned_role = SPECIAL_ROLE_FLOCK
- flockmind.mind.special_role = SPECIAL_ROLE_FLOCK
+ flockmind.mind.make_Flockmind()
var/list/messages = list()
messages += "You are [gradient_text("The Divine Flock","#3cb5a3", "#124e43")]
"
messages += "" + gradient_text("The Signal has led us here, a rift allowing a part of us through. We must build a Signal Relay to bring forth the rest of The Divine Flock. Such is the will of the Monarch.", "#3cb5a3", "#1e806e") + "
"