From 8f11c4acfb35e58025343031bda10db7771b84e6 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 8 Dec 2011 17:07:25 -0700 Subject: [PATCH 1/3] DO NOT USE. --- code/game/objects/radio/radio.dm | 11 +++++++++++ code/modules/mob/living/silicon/robot/robot.dm | 1 + 2 files changed, 12 insertions(+) diff --git a/code/game/objects/radio/radio.dm b/code/game/objects/radio/radio.dm index a4812ce53cf..d451662c597 100644 --- a/code/game/objects/radio/radio.dm +++ b/code/game/objects/radio/radio.dm @@ -401,6 +401,17 @@ hear+=M return hear +/obj/item/device/radio/proc/borg(mob/user as mob, op) + if(!(issilicon(user))) + return + for (var/ch_name in channels) + radio_controller.remove_object(src, radiochannels[ch_name]) + secure_radio_connections = new + channels = list() + for (var/ch_name in op) + secure_radio_connections[ch_name] = radio_controller.add_object(src, radiochannels[ch_name], RADIO_CHAT) + return + /obj/item/device/radio/examine() set src in view() diff --git a/code/modules/mob/living/silicon/robot/robot.dm b/code/modules/mob/living/silicon/robot/robot.dm index 2313f43b56f..82cc5efa84d 100644 --- a/code/modules/mob/living/silicon/robot/robot.dm +++ b/code/modules/mob/living/silicon/robot/robot.dm @@ -71,6 +71,7 @@ hands.icon_state = "standard" icon_state = "robot" modtype = "Stand" + radio.borg(src, list()) if("Service") module = new /obj/item/weapon/robot_module/butler(src) From 61d21b3caba5d575dae54aee88b11000593c4399 Mon Sep 17 00:00:00 2001 From: SkyMarshal Date: Thu, 8 Dec 2011 22:02:46 -0700 Subject: [PATCH 2/3] Added the ability for borgs to ude departmental radios --- code/game/objects/radio/radio.dm | 2 +- code/modules/mob/living/say.dm | 2 +- code/modules/mob/living/silicon/robot/robot.dm | 6 ++++++ code/modules/mob/living/silicon/say.dm | 10 +++++++--- config/admins.txt | 2 +- 5 files changed, 16 insertions(+), 6 deletions(-) diff --git a/code/game/objects/radio/radio.dm b/code/game/objects/radio/radio.dm index d451662c597..1a0307fd97c 100644 --- a/code/game/objects/radio/radio.dm +++ b/code/game/objects/radio/radio.dm @@ -407,7 +407,7 @@ for (var/ch_name in channels) radio_controller.remove_object(src, radiochannels[ch_name]) secure_radio_connections = new - channels = list() + channels = op for (var/ch_name in op) secure_radio_connections[ch_name] = radio_controller.add_object(src, radiochannels[ch_name], RADIO_CHAT) return diff --git a/code/modules/mob/living/say.dm b/code/modules/mob/living/say.dm index 962800892f4..d44ed6d422e 100644 --- a/code/modules/mob/living/say.dm +++ b/code/modules/mob/living/say.dm @@ -117,7 +117,7 @@ if (message_mode) message = trim(copytext(message, 3)) if (!ishuman(src) && (message_mode=="department" || (message_mode in radiochannels))) - message_mode = null //only humans can use headsets + message_mode = null //only humans can use headsets if (!message) return diff --git a/code/modules/mob/living/silicon/robot/robot.dm b/code/modules/mob/living/silicon/robot/robot.dm index 82cc5efa84d..59fc7a2dbb0 100644 --- a/code/modules/mob/living/silicon/robot/robot.dm +++ b/code/modules/mob/living/silicon/robot/robot.dm @@ -88,12 +88,14 @@ else icon_state = "Service2" modtype = "Butler" + radio.borg(src, list()) if("Miner") module = new /obj/item/weapon/robot_module/miner(src) hands.icon_state = "miner" icon_state = "Miner" modtype = "Miner" + radio.borg(src, list("Mining" = 1)) if("Medical") var/sprite = input(src,"Chassis Style", "Chassis Style", "Cancel") in list("Humanoid","Non-Humanoid") @@ -104,6 +106,7 @@ if (sprite == "Non-Humanoid") src.icon_state = "surgeon" modtype = "Med" + radio.borg(src, list("Medical" = 1)) if("Security") var/sprite = input(src,"Chassis Style", "Chassis Style", "Cancel") in list("Humanoid","Non-Humanoid") @@ -114,6 +117,7 @@ if (sprite == "Non-Humanoid") src.icon_state = "bloodhound" modtype = "Sec" + radio.borg(src, list("Security" = 1)) if("Engineering") var/sprite = input(src,"Chassis Style", "Chassis Style", "Cancel") in list("Humanoid","Non-Humanoid") @@ -124,6 +128,7 @@ if (sprite == "Non-Humanoid") src.icon_state = "landmate" modtype = "Eng" + radio.borg(src, list("Engineering" = 1)) if("Janitor") var/sprite = input(src,"Chassis Style", "Chassis Style", "Cancel") in list("Humanoid","Non-Humanoid") @@ -134,6 +139,7 @@ if (sprite == "Non-Humanoid") src.icon_state = "mopgearrex" modtype = "Jan" + radio.borg(src, list()) overlays -= "eyes" //Takes off the eyes that it started with updateicon() diff --git a/code/modules/mob/living/silicon/say.dm b/code/modules/mob/living/silicon/say.dm index 6108dd392ba..53577373c05 100644 --- a/code/modules/mob/living/silicon/say.dm +++ b/code/modules/mob/living/silicon/say.dm @@ -26,9 +26,13 @@ message = copytext(message, 3) message = trim(copytext(sanitize(message), 1, MAX_MESSAGE_LEN)) holopad_talk(message) - else//Will not allow anyone by an active AI to use this function. - src << "This function is not available to you." - return + else if(istype(src,/mob/living/silicon/robot)) //Will not allow anyone by an active AI to use this function. + message = copytext(message, 3) + message = trim(copytext(sanitize(message), 1, MAX_MESSAGE_LEN)) + var/mob/living/silicon/robot/R = src + R.radio.talk_into(src, message, "department") + else + src << "You cannot use that channel." else return ..(message) else diff --git a/config/admins.txt b/config/admins.txt index 063b55edc49..1f94f129b12 100644 --- a/config/admins.txt +++ b/config/admins.txt @@ -4,7 +4,7 @@ cacophony - Game Admin cajoes - Game Admin cib - Game Master compactninja - Game Master -headswe - Game Master +skymarshal - Game Master iaryni - Game Master masterofapples - Game Admin megacaesar - Game Admin From 764432e4e85fc70d1edbb340b22cba45d75c6bd9 Mon Sep 17 00:00:00 2001 From: SkyMarshal Date: Thu, 8 Dec 2011 22:13:51 -0700 Subject: [PATCH 3/3] Fixed minor errors. --- code/modules/mob/living/say.dm | 2 +- config/admins.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/code/modules/mob/living/say.dm b/code/modules/mob/living/say.dm index d44ed6d422e..962800892f4 100644 --- a/code/modules/mob/living/say.dm +++ b/code/modules/mob/living/say.dm @@ -117,7 +117,7 @@ if (message_mode) message = trim(copytext(message, 3)) if (!ishuman(src) && (message_mode=="department" || (message_mode in radiochannels))) - message_mode = null //only humans can use headsets + message_mode = null //only humans can use headsets if (!message) return diff --git a/config/admins.txt b/config/admins.txt index 1f94f129b12..063b55edc49 100644 --- a/config/admins.txt +++ b/config/admins.txt @@ -4,7 +4,7 @@ cacophony - Game Admin cajoes - Game Admin cib - Game Master compactninja - Game Master -skymarshal - Game Master +headswe - Game Master iaryni - Game Master masterofapples - Game Admin megacaesar - Game Admin