diff --git a/code/game/machinery/computer/message_monitor.dm b/code/game/machinery/computer/message_monitor.dm index 6b09cbebcb2..8e1dbc43a61 100644 --- a/code/game/machinery/computer/message_monitor.dm +++ b/code/game/machinery/computer/message_monitor.dm @@ -400,7 +400,8 @@ //Select Your Name if("Sender") - customsender = clean_input("Please enter the sender's name.") + customsender = input("Please enter the sender's name.") + customsender = trim_strip_html_properly(customsender) //Select Receiver if("Recepient") @@ -419,12 +420,13 @@ //Enter custom job if("RecJob") - customjob = clean_input("Please enter the sender's job.") + customjob = input("Please enter the sender's job.") + customjob = trim_strip_html_properly(customjob) //Enter message if("Message") - custommessage = clean_input("Please enter your message.") - custommessage = sanitize(copytext(custommessage, 1, MAX_MESSAGE_LEN)) + custommessage = input("Please enter your message.") + custommessage = trim_strip_html_properly(custommessage) //Send message if("Send") @@ -454,11 +456,13 @@ if(P.owner == customsender) PDARec = P break + + var/sender_identity //Sender isn't faking as someone who exists if(isnull(PDARec)) src.linkedServer.send_pda_message("[customrecepient.owner]", "[customsender]","[custommessage]") recipient_messenger.notify("Message from [customsender] ([customjob]), \"[custommessage]\" (Reply)") - log_pda("(PDA: [customsender]) sent \"[custommessage]\" to [customrecepient.owner]", usr) + sender_identity = customsender //Sender is faking as someone who exists else src.linkedServer.send_pda_message("[customrecepient.owner]", "[PDARec.owner]","[custommessage]") @@ -468,7 +472,12 @@ recipient_messenger.conversations.Add("\ref[PDARec]") recipient_messenger.notify("Message from [PDARec.owner] ([customjob]), \"[custommessage]\" (Reply)") - log_pda("(PDA: [PDARec.owner]) sent \"[custommessage]\" to [customrecepient.owner]", usr) + sender_identity = PDARec.owner + + // Logging + log_pda("(PDA: [sender_identity]) sent \"[custommessage]\" to [customrecepient.owner]", usr) + investigate_log("PDA Message - Custom Name: \"[sender_identity]\", Custom Job: \"[customjob]\", Real Sender: \"[key_name(usr)]\" ([ADMIN_PP(usr,"PP")]) -> [customrecepient.owner] ([ADMIN_VV(customrecepient, "VV")]), Message: \"[custommessage]\"", "pda") + var/log_message = "sent PDA message \"[custommessage]\" using [src] as [customsender] ([customjob])" var/receiver if(ishuman(customrecepient.loc)) diff --git a/code/modules/pda/messenger.dm b/code/modules/pda/messenger.dm index 84e47b21cd3..a82f38fa06d 100644 --- a/code/modules/pda/messenger.dm +++ b/code/modules/pda/messenger.dm @@ -185,7 +185,7 @@ useMS.send_pda_message("[P.owner]","[pda.owner]","[t]") tnote.Add(list(list("sent" = 1, "owner" = "[P.owner]", "job" = "[P.ownjob]", "message" = "[html_decode(t)]", "target" = "[P.UID()]"))) PM.tnote.Add(list(list("sent" = 0, "owner" = "[pda.owner]", "job" = "[pda.ownjob]", "message" = "[html_decode(t)]", "target" = "[pda.UID()]"))) - pda.investigate_log("PDA Message - [U.key] - [pda.owner] -> [P.owner]: [t]", "pda") + pda.investigate_log("PDA Message - [pda.owner] ([U.key] [ADMIN_PP(U, "PP")]) -> [P.owner] ([ADMIN_VV(P, "VV")]), Message: \"[t]\"", "pda") // Show it to ghosts for(var/mob/M in GLOB.dead_mob_list)