diff --git a/code/WorkInProgress/Sigyn/Department Sec/jobs.dm b/code/WorkInProgress/Sigyn/Department Sec/jobs.dm index 66e14b040c..7f98a7b6ec 100644 --- a/code/WorkInProgress/Sigyn/Department Sec/jobs.dm +++ b/code/WorkInProgress/Sigyn/Department Sec/jobs.dm @@ -83,9 +83,9 @@ proc/assign_sec_to_department(var/mob/living/carbon/human/H) else H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack) H.equip_to_slot_or_del(new /obj/item/weapon/handcuffs(H), slot_in_backpack) - var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H) - L.imp_in = H - L.implanted = 1 + + implant_loyalty(H) + return 1 /obj/item/device/radio/headset/headset_sec/department/New() diff --git a/code/WorkInProgress/Sigyn/Softcurity/jobs.dm b/code/WorkInProgress/Sigyn/Softcurity/jobs.dm index a214626d1c..243dc47c75 100644 --- a/code/WorkInProgress/Sigyn/Softcurity/jobs.dm +++ b/code/WorkInProgress/Sigyn/Softcurity/jobs.dm @@ -23,9 +23,9 @@ H.equip_to_slot_or_del(new /obj/item/weapon/gun/energy/taser(H), slot_s_store) H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack) H.equip_to_slot_or_del(new /obj/item/weapon/handcuffs(H), slot_in_backpack) - var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H) - L.imp_in = H - L.implanted = 1 + + H.implant_loyalty(src) // Will not do so if config is set to disallow. + return 1 @@ -52,9 +52,9 @@ H.equip_to_slot_or_del(new /obj/item/device/flash(H), slot_l_store) H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack) H.equip_to_slot_or_del(new /obj/item/weapon/handcuffs(H), slot_in_backpack) - var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H) - L.imp_in = H - L.implanted = 1 + + H.implant_loyalty(src) // // Will not do so if config is set to disallow. + return 1 @@ -89,9 +89,7 @@ H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/evidence(H), slot_in_backpack) H.equip_to_slot_or_del(new /obj/item/device/detective_scanner(H), slot_in_backpack) - var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H) - L.imp_in = H - L.implanted = 1 + H.implant_loyalty(src) // Will not do so if config is set to disallow. return 1 @@ -118,9 +116,9 @@ H.equip_to_slot_or_del(new /obj/item/device/flash(H), slot_l_store) H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack) H.equip_to_slot_or_del(new /obj/item/weapon/handcuffs(H), slot_in_backpack) - var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H) - L.imp_in = H - L.implanted = 1 + + H.implant_loyalty(src) // Will not do so if config is set to disallow. + return 1 /datum/job/hop diff --git a/code/WorkInProgress/Sigyn/Softcurity/secure_closet.dm b/code/WorkInProgress/Sigyn/Softcurity/secure_closet.dm index 88f06f98e7..e74c6fce6c 100644 --- a/code/WorkInProgress/Sigyn/Softcurity/secure_closet.dm +++ b/code/WorkInProgress/Sigyn/Softcurity/secure_closet.dm @@ -70,7 +70,7 @@ new /obj/item/weapon/storage/backpack/satchel_sec(src) new /obj/item/weapon/cartridge/hos(src) new /obj/item/device/radio/headset/heads/hos(src) - new /obj/item/weapon/storage/lockbox/loyalty(src) + if (config.use_loyalty_implants) new /obj/item/weapon/storage/lockbox/loyalty(src) new /obj/item/weapon/storage/flashbang_kit(src) new /obj/item/weapon/storage/belt/security(src) new /obj/item/device/flash(src) diff --git a/code/WorkInProgress/kilakk/responseteam.dm b/code/WorkInProgress/kilakk/responseteam.dm index 6faafad342..8e0cdbc638 100644 --- a/code/WorkInProgress/kilakk/responseteam.dm +++ b/code/WorkInProgress/kilakk/responseteam.dm @@ -231,9 +231,7 @@ var/global/admin_emergency_team = 0 // Used for admin-spawned response teams // equip_to_slot_or_del(new /obj/item/weapon/storage/firstaid/regular(src), slot_in_backpack) // Regular medkit // Loyalty implants - var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(src) - L.imp_in = src - L.implanted = 1 + implant_loyalty(src) // ID cards var/obj/item/weapon/card/id/E = new(src) diff --git a/code/datums/mind.dm b/code/datums/mind.dm index 936eea26d1..cc24ed7fdb 100644 --- a/code/datums/mind.dm +++ b/code/datums/mind.dm @@ -510,37 +510,37 @@ datum/mind I.Del() break H << "\blue Your loyalty implant has been deactivated." - if("add") - var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H) - L.imp_in = H - L.implanted = 1 - var/datum/organ/external/affected = H.organs_by_name["head"] - affected.implants += L - L.part = affected - H << "\red You somehow have become the recepient of a loyalty transplant, and it just activated!" - if(src in ticker.mode.revolutionaries) - special_role = null - ticker.mode.revolutionaries -= src - src << "\red The nanobots in the loyalty implant remove all thoughts about being a revolutionary. Get back to work!" - if(src in ticker.mode.head_revolutionaries) - special_role = null - ticker.mode.head_revolutionaries -=src - src << "\red The nanobots in the loyalty implant remove all thoughts about being a revolutionary. Get back to work!" - if(src in ticker.mode.cult) - ticker.mode.cult -= src - ticker.mode.update_cult_icons_removed(src) - special_role = null - var/datum/game_mode/cult/cult = ticker.mode - if (istype(cult)) - cult.memorize_cult_objectives(src) - current << "\red The nanobots in the loyalty implant remove all thoughts about being in a cult. Have a productive day!" - memory = "" - if(src in ticker.mode.traitors) - ticker.mode.traitors -= src - special_role = null - current << "\red The nanobots in the loyalty implant remove all thoughts about being a traitor to Nanotrasen. Have a nice day!" - log_admin("[key_name_admin(usr)] has de-traitor'ed [current].") + if("add") + H.implant_loyalty(src) + + if(config.use_loyalty_implants) // The following won't occur if there are not loyalty implants. + H << "\red You somehow have become the recepient of a loyalty transplant, and it just activated!" + if(src in ticker.mode.revolutionaries) + special_role = null + ticker.mode.revolutionaries -= src + src << "\red The nanobots in the loyalty implant remove all thoughts about being a revolutionary. Get back to work!" + if(src in ticker.mode.head_revolutionaries) + special_role = null + ticker.mode.head_revolutionaries -=src + src << "\red The nanobots in the loyalty implant remove all thoughts about being a revolutionary. Get back to work!" + if(src in ticker.mode.cult) + ticker.mode.cult -= src + ticker.mode.update_cult_icons_removed(src) + special_role = null + var/datum/game_mode/cult/cult = ticker.mode + if (istype(cult)) + cult.memorize_cult_objectives(src) + current << "\red The nanobots in the loyalty implant remove all thoughts about being in a cult. Have a productive day!" + memory = "" + if(src in ticker.mode.traitors) + ticker.mode.traitors -= src + special_role = null + current << "\red The nanobots in the loyalty implant remove all thoughts about being a traitor to Nanotrasen. Have a nice day!" + log_admin("[key_name_admin(usr)] has de-traitor'ed [current].") + else + usr << "Loyalty implants are currently disabled for your server in the configuration files." + else if (href_list["revolution"]) current.hud_updateflag |= (1 << SPECIALROLE_HUD) diff --git a/code/datums/supplypacks.dm b/code/datums/supplypacks.dm index 7990329aa1..abca12f25e 100755 --- a/code/datums/supplypacks.dm +++ b/code/datums/supplypacks.dm @@ -681,14 +681,6 @@ var/list/all_supply_groups = list("Operations","Security","Hospitality","Enginee access = access_armory group = "Security" -/datum/supply_packs/loyalty - name = "Loyalty implant crate" - contains = list (/obj/item/weapon/storage/lockbox/loyalty) - cost = 60 - containertype = /obj/structure/closet/crate/secure - containername = "Loyalty implant crate" - access = access_armory - group = "Security" /datum/supply_packs/ballistic name = "Ballistic gear crate" @@ -725,6 +717,17 @@ var/list/all_supply_groups = list("Operations","Security","Hospitality","Enginee access = access_armory group = "Security" +/* +/datum/supply_packs/loyalty + name = "Loyalty implant crate" + contains = list (/obj/item/weapon/storage/lockbox/loyalty) + cost = 60 + containertype = /obj/structure/closet/crate/secure + containername = "Loyalty implant crate" + access = access_armory + group = "Security" +*/ + /datum/supply_packs/expenergy name = "Experimental energy gear crate" contains = list(/obj/item/clothing/suit/armor/laserproof, diff --git a/code/game/gamemodes/epidemic/epidemic.dm b/code/game/gamemodes/epidemic/epidemic.dm index d0db2d66b9..4a0712c712 100644 --- a/code/game/gamemodes/epidemic/epidemic.dm +++ b/code/game/gamemodes/epidemic/epidemic.dm @@ -71,7 +71,7 @@ world << sound('sound/AI/commandreport.ogg') // add an extra law to the AI to make sure it cooperates with the heads - var/extra_law = "Crew authorized to know of pathogen [virus_name]'s existence are: Heads of command, any crew member with loyalty implant. Do not allow unauthorized personnel to gain knowledge of [virus_name]. Aid authorized personnel in quarantining and neutrlizing the outbreak. This law overrides all other laws." + var/extra_law = "Crew authorized to know of pathogen [virus_name]'s existence are: Heads of command. Do not allow unauthorized personnel to gain knowledge of [virus_name]. Aid authorized personnel in quarantining and neutrlizing the outbreak. This law overrides all other laws." for(var/mob/living/silicon/ai/M in world) M.add_ion_law(extra_law) M << "\red " + extra_law diff --git a/code/game/jobs/job/captain.dm b/code/game/jobs/job/captain.dm index acc7c3e853..dfa159be37 100644 --- a/code/game/jobs/job/captain.dm +++ b/code/game/jobs/job/captain.dm @@ -32,13 +32,10 @@ H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/ids(H), slot_r_hand) else H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/ids(H.back), slot_in_backpack) - var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H) - L.imp_in = H - L.implanted = 1 world << "[H.real_name] is the captain!" - var/datum/organ/external/affected = H.organs_by_name["head"] - affected.implants += L - L.part = affected + + H.implant_loyalty(src) + return 1 get_access() diff --git a/code/game/jobs/job/civilian.dm b/code/game/jobs/job/civilian.dm index 0576e5b823..57350f087a 100644 --- a/code/game/jobs/job/civilian.dm +++ b/code/game/jobs/job/civilian.dm @@ -357,10 +357,8 @@ H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H), slot_r_hand) else H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack) - var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H) - L.imp_in = H - L.implanted = 1 - var/datum/organ/external/affected = H.organs_by_name["head"] - affected.implants += L - L.part = affected + + H.implant_loyalty(H) + + return 1 diff --git a/code/game/jobs/job/security.dm b/code/game/jobs/job/security.dm index 69e9babb0a..c83c0c0ea2 100644 --- a/code/game/jobs/job/security.dm +++ b/code/game/jobs/job/security.dm @@ -39,12 +39,7 @@ else H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack) H.equip_to_slot_or_del(new /obj/item/weapon/handcuffs(H), slot_in_backpack) - var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H) - L.imp_in = H - L.implanted = 1 - var/datum/organ/external/affected = H.organs_by_name["head"] - affected.implants += L - L.part = affected + H.implant_loyalty(H) return 1 @@ -165,4 +160,4 @@ else H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack) H.equip_to_slot_or_del(new /obj/item/weapon/handcuffs(H), slot_in_backpack) - return 1 + return 1 diff --git a/code/game/objects/items/weapons/implants/implant.dm b/code/game/objects/items/weapons/implants/implant.dm index f8c46134c1..b9f3ef4afd 100644 --- a/code/game/objects/items/weapons/implants/implant.dm +++ b/code/game/objects/items/weapons/implants/implant.dm @@ -1,5 +1,11 @@ #define MALFUNCTION_TEMPORARY 1 #define MALFUNCTION_PERMANENT 2 + + +/mob/living/carbon/human/ + + + /obj/item/weapon/implant name = "implant" icon = 'icons/obj/device.dmi' diff --git a/code/modules/admin/verbs/striketeam.dm b/code/modules/admin/verbs/striketeam.dm index cf5b94322d..e8a92edbe3 100644 --- a/code/modules/admin/verbs/striketeam.dm +++ b/code/modules/admin/verbs/striketeam.dm @@ -158,9 +158,7 @@ var/global/sent_strike_team = 0 equip_to_slot_or_del(new /obj/item/weapon/gun/energy/pulse_rifle(src), slot_r_hand) - var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(src)//Here you go Deuryn - L.imp_in = src - L.implanted = 1 + implant_loyalty(src) diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm index 56374bcd0f..a1b76fa081 100644 --- a/code/modules/mob/living/carbon/human/human.dm +++ b/code/modules/mob/living/carbon/human/human.dm @@ -317,6 +317,16 @@ if(armor >= 2) return +/mob/living/carbon/human/proc/implant_loyalty(mob/living/carbon/human/M) + if(!config.use_loyalty_implants) return + + var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(M) + L.imp_in = M + L.implanted = 1 + var/datum/organ/external/affected = M.organs_by_name["head"] + affected.implants += L + L.part = affected + /mob/living/carbon/human/proc/is_loyalty_implanted(mob/living/carbon/human/M) for(var/L in M.contents) if(istype(L, /obj/item/weapon/implant/loyalty)) diff --git a/code/modules/research/designs.dm b/code/modules/research/designs.dm index 002888e61e..38fb4994fa 100644 --- a/code/modules/research/designs.dm +++ b/code/modules/research/designs.dm @@ -1358,6 +1358,7 @@ datum/design/nanopaste materials = list("$metal" = 7000, "$glass" = 7000) build_path = "/obj/item/stack/nanopaste" +/* // Removal of loyalty implants. Can't think of a way to add this to the config option. datum/design/implant_loyal name = "loyalty implant" desc = "Makes you loyal or such." @@ -1366,6 +1367,7 @@ datum/design/implant_loyal build_type = PROTOLATHE materials = list("$metal" = 7000, "$glass" = 7000) build_path = "/obj/item/weapon/implant/loyalty" +*/ datum/design/implant_chem name = "chemical implant"