From 5b257f55e35ddd746da3c04eae6a02825a8af39b Mon Sep 17 00:00:00 2001 From: Arokha Sieyes Date: Sun, 19 Feb 2017 17:47:40 -0500 Subject: [PATCH] Make OOC notes persistant Even when logged out, or body swapped, or new bodies are printed. --- code/modules/client/preference_setup/general/06_flavor.dm | 1 + code/modules/mob/living/carbon/human/examine.dm | 2 +- code/modules/mob/living/living.dm | 8 +++++--- code/modules/mob/living/living_defines_vr.dm | 2 ++ code/modules/resleeving/infocore.dm | 5 ++++- code/modules/resleeving/machines.dm | 6 +++++- vorestation.dme | 1 + 7 files changed, 19 insertions(+), 6 deletions(-) create mode 100644 code/modules/mob/living/living_defines_vr.dm diff --git a/code/modules/client/preference_setup/general/06_flavor.dm b/code/modules/client/preference_setup/general/06_flavor.dm index 94525ee06f..452752cee8 100644 --- a/code/modules/client/preference_setup/general/06_flavor.dm +++ b/code/modules/client/preference_setup/general/06_flavor.dm @@ -47,6 +47,7 @@ character.flavor_texts["hands"] = pref.flavor_texts["hands"] character.flavor_texts["legs"] = pref.flavor_texts["legs"] character.flavor_texts["feet"] = pref.flavor_texts["feet"] + character.ooc_notes = pref.metadata //VOREStation Add /datum/category_item/player_setup_item/general/flavor/content(var/mob/user) . += "Flavor:
" diff --git a/code/modules/mob/living/carbon/human/examine.dm b/code/modules/mob/living/carbon/human/examine.dm index e613397288..f68ad50751 100644 --- a/code/modules/mob/living/carbon/human/examine.dm +++ b/code/modules/mob/living/carbon/human/examine.dm @@ -438,7 +438,7 @@ if(print_flavor_text()) msg += "[print_flavor_text()]\n" // VOREStation Start - if(config.allow_Metadata && client) + if(ooc_notes) msg += "OOC Notes: \[View\]\n" // VOREStation End msg += "*---------*
" diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm index 17b9bd3466..e27042b9a1 100644 --- a/code/modules/mob/living/living.dm +++ b/code/modules/mob/living/living.dm @@ -485,15 +485,17 @@ default behaviour is: set name = "Examine Meta-Info (OOC)" set category = "OOC" set src in view() - + //VOREStation Edit Start - Making it so SSD people have prefs with fallback to original style. if(config.allow_Metadata) - if(client) + if(ooc_notes) + usr << "[src]'s Metainfo:
[ooc_notes]" + else if(client) usr << "[src]'s Metainfo:
[client.prefs.metadata]" else usr << "[src] does not have any stored infomation!" else usr << "OOC Metadata is not supported by this server!" - + //VOREStation Edit End - Making it so SSD people have prefs with fallback to original style. return /mob/living/Move(a, b, flag) diff --git a/code/modules/mob/living/living_defines_vr.dm b/code/modules/mob/living/living_defines_vr.dm new file mode 100644 index 0000000000..566c21dad8 --- /dev/null +++ b/code/modules/mob/living/living_defines_vr.dm @@ -0,0 +1,2 @@ +/mob/living + var/ooc_notes = null \ No newline at end of file diff --git a/code/modules/resleeving/infocore.dm b/code/modules/resleeving/infocore.dm index b18c0a1815..bd4cf72111 100644 --- a/code/modules/resleeving/infocore.dm +++ b/code/modules/resleeving/infocore.dm @@ -82,6 +82,7 @@ var/datum/transhuman/infocore/transcore = new/datum/transhuman/infocore var/cryo_at var/secretly_dead var/languages + var/mind_oocnotes /datum/transhuman/mind_record/New(var/mob/living/carbon/human/M,var/obj/item/weapon/implant/backup/imp,var/add_to_db = 1) ASSERT(M && imp) @@ -100,6 +101,7 @@ var/datum/transhuman/infocore/transcore = new/datum/transhuman/infocore ckey = M.ckey cryo_at = 0 languages = M.languages.Copy() + mind_oocnotes = M.ooc_notes //If these are gone then it's a problemmmm. client = M.client @@ -108,7 +110,6 @@ var/datum/transhuman/infocore/transcore = new/datum/transhuman/infocore if(add_to_db) transcore.add_backup(src) - /////// Body Record /////// /datum/transhuman/body_record var/datum/dna2/record/mydna @@ -121,6 +122,7 @@ var/datum/transhuman/infocore/transcore = new/datum/transhuman/infocore var/synthetic var/speciesname var/bodygender + var/body_oocnotes var/list/limb_data = list(BP_HEAD, BP_L_HAND, BP_R_HAND, BP_L_ARM, BP_R_ARM, BP_L_FOOT, BP_R_FOOT, BP_L_LEG, BP_R_LEG, BP_GROIN, BP_TORSO) var/list/organ_data = list(O_HEART, O_EYES, O_LUNGS, O_BRAIN) @@ -134,6 +136,7 @@ var/datum/transhuman/infocore/transcore = new/datum/transhuman/infocore synthetic = M.isSynthetic() speciesname = M.custom_species ? M.custom_species : M.dna.species bodygender = M.gender + body_oocnotes = M.ooc_notes //Probably should M.dna.check_integrity() diff --git a/code/modules/resleeving/machines.dm b/code/modules/resleeving/machines.dm index df6ba9d68e..8e1a25424a 100644 --- a/code/modules/resleeving/machines.dm +++ b/code/modules/resleeving/machines.dm @@ -86,7 +86,7 @@ H.set_cloned_appearance() update_icon() - + H.ooc_notes = current_project.body_oocnotes H.flavor_texts = R.flavor.Copy() H.suiciding = 0 attempting = 0 @@ -210,6 +210,9 @@ if(current_project.locked) H.resleeve_lock = current_project.ckey + H.ooc_notes = current_project.body_oocnotes + H.flavor_texts = current_project.mydna.flavor.Copy() + //First the external organs for(var/part in current_project.limb_data) @@ -397,6 +400,7 @@ occupant.client = MR.client occupant.mind = MR.mind occupant.ckey = MR.ckey + occupant.ooc_notes = MR.mind_oocnotes //Give them a backup implant var/obj/item/weapon/implant/backup/new_imp = new() diff --git a/vorestation.dme b/vorestation.dme index f13a0c0af9..38a27878fd 100644 --- a/vorestation.dme +++ b/vorestation.dme @@ -1594,6 +1594,7 @@ #include "code\modules\mob\living\living.dm" #include "code\modules\mob\living\living_defense.dm" #include "code\modules\mob\living\living_defines.dm" +#include "code\modules\mob\living\living_defines_vr.dm" #include "code\modules\mob\living\living_powers.dm" #include "code\modules\mob\living\login.dm" #include "code\modules\mob\living\logout.dm"