Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nothing like testing in prod! #3283

Merged
merged 1 commit into from
Oct 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 0 additions & 15 deletions code/datums/soullink.dm
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,6 @@
var/list/ownedSoullinks //soullinks we are the owner of
var/list/sharedSoullinks //soullinks we are a/the sharer of

/mob/living/Destroy()
for(var/s in ownedSoullinks)
var/datum/soullink/S = s
S.ownerDies(FALSE)
qdel(s) //If the owner is destroy()'d, the soullink is destroy()'d
ownedSoullinks = null
for(var/s in sharedSoullinks)
var/datum/soullink/S = s
S.sharerDies(FALSE)
S.removeSoulsharer(src) //If a sharer is destroy()'d, they are simply removed
sharedSoullinks = null
return ..()



//Keeps track of a Mob->Mob (potentially Player->Player) connection
//Can be used to trigger actions on one party when events happen to another
//Eg: shared deaths
Expand Down
10 changes: 10 additions & 0 deletions code/modules/mob/living/living.dm
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,16 @@
med_hud_set_status()

/mob/living/Destroy()
for(var/s in ownedSoullinks)
var/datum/soullink/S = s
S.ownerDies(FALSE)
qdel(s) //If the owner is destroy()'d, the soullink is destroy()'d
ownedSoullinks = null
for(var/s in sharedSoullinks)
var/datum/soullink/S = s
S.sharerDies(FALSE)
S.removeSoulsharer(src) //If a sharer is destroy()'d, they are simply removed
sharedSoullinks = null
if(mind)
mind.RemoveAllSpells()
end_parry_sequence()
Expand Down