From 7e7aaecf245607ac9ca763f4790c7daaf1b780c3 Mon Sep 17 00:00:00 2001 From: Metis <100518708+sheepishgoat@users.noreply.github.com> Date: Sat, 24 Aug 2024 14:59:47 -0400 Subject: [PATCH] a --- .../game/objects/items/docility_implant.dm | 35 +++++++++++++++++++ code/__DEFINES/traits.dm | 1 + tgstation.dme | 1 + 3 files changed, 37 insertions(+) create mode 100644 GainStation13/code/game/objects/items/docility_implant.dm diff --git a/GainStation13/code/game/objects/items/docility_implant.dm b/GainStation13/code/game/objects/items/docility_implant.dm new file mode 100644 index 00000000..c2ceea8f --- /dev/null +++ b/GainStation13/code/game/objects/items/docility_implant.dm @@ -0,0 +1,35 @@ +/obj/item/implant/docile + name = "docility implant" + activated = FALSE + +/obj/item/implant/docile/implant(mob/living/target, mob/user, silent = FALSE) + . = ..() + if(!.) + return + + var/mob/living/carbon/human/target_human = target + if(!istype(target_human)) + return + + // If you have this implant, you aren't going to be doing any fighting. + ADD_TRAIT(target, TRAIT_WEIGHT_LOSS_IMMUNE, src) + ADD_TRAIT(target, TRAIT_PACIFISM, src) + ADD_TRAIT(target, TRAIT_CLUMSY, src) + ADD_TRAIT(target, TRAIT_FAT_GOOD, src) + ADD_TRAIT(target, TRAIT_HEAVY_SLEEPER, src) + + target_human.nutri_mult += 1 + +/obj/item/implant/docile/removed(mob/living/source, silent = FALSE, special = 0) + . = ..() + if(!.) + return + + REMOVE_TRAIT(target, TRAIT_WEIGHT_LOSS_IMMUNE, src) + REMOVE_TRAIT(target, TRAIT_PACIFISM, src) + REMOVE_TRAIT(target, TRAIT_CLUMSY, src) + REMOVE_TRAIT(target, TRAIT_FAT_GOOD, src) + REMOVE_TRAIT(target, TRAIT_HEAVY_SLEEPER, src) + + target_human.nutri_mult -= 1 + diff --git a/code/__DEFINES/traits.dm b/code/__DEFINES/traits.dm index 91e67196..0db2431f 100644 --- a/code/__DEFINES/traits.dm +++ b/code/__DEFINES/traits.dm @@ -227,6 +227,7 @@ #define TRAIT_NO_MISC "no_misc" #define TRAIT_NO_BACKPACK "no_backpack" #define TRAIT_NO_BUCKLE "no_buckle" +#define TRAIT_DOCILE "docile" // common trait sources #define TRAIT_GENERIC "generic" diff --git a/tgstation.dme b/tgstation.dme index d849af0c..dcc275ec 100644 --- a/tgstation.dme +++ b/tgstation.dme @@ -3086,6 +3086,7 @@ #include "GainStation13\code\game\sound.dm" #include "GainStation13\code\game\area\ruins.dm" #include "GainStation13\code\game\objects\effects\spawners\choco_slime_delivery.dm" +#include "GainStation13\code\game\objects\items\docility_implant.dm" #include "GainStation13\code\game\objects\items\RCD.dm" #include "GainStation13\code\game\objects\items\storage\bags.dm" #include "GainStation13\code\game\turfs\closed.dm"