From e74d3c5331ef60c1fc6de0cfc31364f033d4d315 Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Mon, 28 Aug 2023 07:54:16 +0200 Subject: [PATCH] [MIRROR] roundstart scryers now come with the nt frequency [MDB IGNORE] (#23376) * roundstart scryers now come with the nt frequency (#77957) ## About The Pull Request fixes #77934 ## Why It's Good For The Game blegh ## Changelog :cl: fix: roundstart modlink scryers now come with the nt frequency /:cl: * roundstart scryers now come with the nt frequency --------- Co-authored-by: Fikou <23585223+Fikou@users.noreply.github.com> --- .../game/objects/structures/crates_lockers/crates.dm | 2 +- code/modules/mod/mod_link.dm | 12 ++++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/code/game/objects/structures/crates_lockers/crates.dm b/code/game/objects/structures/crates_lockers/crates.dm index 277c9dda7ac..4059839641c 100644 --- a/code/game/objects/structures/crates_lockers/crates.dm +++ b/code/game/objects/structures/crates_lockers/crates.dm @@ -308,7 +308,7 @@ for(var/i in 1 to 3) new /obj/item/mod/core/standard(src) for(var/i in 1 to 2) - new /obj/item/clothing/neck/link_scryer(src) + new /obj/item/clothing/neck/link_scryer/loaded(src) /obj/structure/closet/crate/solarpanel_small name = "budget solar panel crate" diff --git a/code/modules/mod/mod_link.dm b/code/modules/mod/mod_link.dm index 451e540d0f9..8a3340fad3e 100644 --- a/code/modules/mod/mod_link.dm +++ b/code/modules/mod/mod_link.dm @@ -87,8 +87,10 @@ if(istype(tool.buffer, /datum/mod_link)) var/datum/mod_link/buffer_link = tool.buffer tool_frequency = buffer_link.frequency + balloon_alert(user, "frequency set") if(!tool_frequency && mod_link.frequency) tool.set_buffer(mod_link) + balloon_alert(user, "frequency copied") else if(tool_frequency && !mod_link.frequency) mod_link.frequency = tool_frequency else if(tool_frequency && mod_link.frequency) @@ -98,8 +100,10 @@ switch(response) if("Copy") tool.set_buffer(mod_link) + balloon_alert(user, "frequency copied") if("Imprint") mod_link.frequency = tool_frequency + balloon_alert(user, "frequency set") /obj/item/mod/control/proc/can_call() return get_charge() && wearer && wearer.stat < DEAD @@ -231,17 +235,23 @@ if(istype(tool.buffer, /datum/mod_link)) var/datum/mod_link/buffer_link = tool.buffer tool_frequency = buffer_link.frequency + balloon_alert(user, "frequency set") if(!tool_frequency && mod_link.frequency) tool.set_buffer(mod_link) + balloon_alert(user, "frequency copied") else if(tool_frequency && !mod_link.frequency) mod_link.frequency = tool_frequency else if(tool_frequency && mod_link.frequency) var/response = tgui_alert(user, "Would you like to copy or imprint the frequency?", "MODlink Frequency", list("Copy", "Imprint")) + if(!user.is_holding(tool)) + return switch(response) if("Copy") tool.set_buffer(mod_link) + balloon_alert(user, "frequency copied") if("Imprint") mod_link.frequency = tool_frequency + balloon_alert(user, "frequency set") /obj/item/clothing/neck/link_scryer/worn_overlays(mutable_appearance/standing, isinhands) . = ..() @@ -310,6 +320,8 @@ /// A MODlink datum, used to handle unique functions that will be used in the MODlink call. /datum/mod_link + /// Generic name for multitool buffers. + var/name = "MODlink" /// The frequency of the MODlink. You can only call other MODlinks on the same frequency. var/frequency /// The unique ID of the MODlink.