diff --git a/code/__DEFINES/misc_defines.dm b/code/__DEFINES/misc_defines.dm index 92035487ad8..6dee5bb4c27 100644 --- a/code/__DEFINES/misc_defines.dm +++ b/code/__DEFINES/misc_defines.dm @@ -375,7 +375,7 @@ #define EXPLOSION_BLOCK_PROC -1 // Defines for investigate to prevent typos and for styling -#define INVESTIGATE_LABEL "labels" +#define INVESTIGATE_RENAME "renames" #define INVESTIGATE_BOMB "bombs" diff --git a/code/game/atoms.dm b/code/game/atoms.dm index bb329df6b24..50c6db6a583 100644 --- a/code/game/atoms.dm +++ b/code/game/atoms.dm @@ -1226,6 +1226,13 @@ GLOBAL_LIST_EMPTY(blood_splatter_icons) t = sanitize(copytext(t, 1, MAX_NAME_LEN)) + + // Logging + var/logged_name = initial(name) + if(t) + logged_name = "[use_prefix ? "[prefix][t]" : t]" + investigate_log("[key_name(user)] ([ADMIN_FLW(user,"FLW")]) renamed \"[src]\" ([ADMIN_VV(src, "VV")]) as \"[logged_name]\".", INVESTIGATE_RENAME) + if(actually_rename) if(t == "") name = "[initial(name)]" diff --git a/code/modules/paperwork/handlabeler.dm b/code/modules/paperwork/handlabeler.dm index ff317465b18..e85bc133506 100644 --- a/code/modules/paperwork/handlabeler.dm +++ b/code/modules/paperwork/handlabeler.dm @@ -29,7 +29,7 @@ user.visible_message("[user] labels [A] as [label].", \ "You label [A] as [label].") - investigate_log("[key_name(user)] labelled [A] as [label].", INVESTIGATE_LABEL) // Investigate goes BEFORE rename so the original name is preserved in the log + investigate_log("[key_name(user)] ([ADMIN_FLW(user,"FLW")]) labelled \"[A]\" ([ADMIN_VV(A, "VV")]) with \"[label]\" at [COORD(A.loc)] [ADMIN_JMP(A)].", INVESTIGATE_RENAME) // Investigate goes BEFORE rename so the original name is preserved in the log A.AddComponent(/datum/component/label, label) playsound(A, 'sound/items/handling/component_pickup.ogg', 20, TRUE) labels_left--