From 2fcc642c81e95cfbe13ab325bbe6505282ebcbe4 Mon Sep 17 00:00:00 2001 From: coiax Date: Sun, 10 Jan 2021 16:56:50 +0000 Subject: [PATCH] Tweak the RD's suplexing ability into a skillchip (#55870) Although this doesn't change the power level of the Research Director, it's important to rework "job title" checks into traits or something similar. Moving job title specific behaviour out of checks by job name and into traits means there's more flexibility to trigger behaviour. If an admin feels the station really needs the ability, they can var edit it in, or spawn the chip. --- code/__DEFINES/traits.dm | 6 +++ code/modules/events/immovable_rod.dm | 46 +++++++++++-------- .../jobs/job_types/research_director.dm | 2 + .../job_skillchips/research_director.dm | 9 ++++ tgstation.dme | 1 + 5 files changed, 45 insertions(+), 19 deletions(-) create mode 100644 code/modules/library/skill_learning/job_skillchips/research_director.dm diff --git a/code/__DEFINES/traits.dm b/code/__DEFINES/traits.dm index a673d2b8d41..17b1c1c6d03 100644 --- a/code/__DEFINES/traits.dm +++ b/code/__DEFINES/traits.dm @@ -248,6 +248,12 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai // and emit less heat. Present on /mob or /datum/mind #define TRAIT_SUPERMATTER_SOOTHER "supermatter_soother" +// If present on a mob or mobmind, allows them to "suplex" an immovable rod +// turning it into a glorified potted plant, and giving them an +// achievement. Can also be used on rod-form wizards. +// Normally only present in the mind of a Research Director. +#define TRAIT_ROD_SUPLEX "rod_suplex" + //SKILLS #define TRAIT_UNDERWATER_BASKETWEAVING_KNOWLEDGE "underwater_basketweaving" #define TRAIT_WINE_TASTER "wine_taster" diff --git a/code/modules/events/immovable_rod.dm b/code/modules/events/immovable_rod.dm index 44095de94d7..0599e9e01af 100644 --- a/code/modules/events/immovable_rod.dm +++ b/code/modules/events/immovable_rod.dm @@ -174,22 +174,30 @@ In my current plan for it, 'solid' will be defined as anything with density == 1 smeared_mob.ex_act(EXPLODE_HEAVY) /obj/effect/immovablerod/attack_hand(mob/living/user) - if(ishuman(user)) - var/mob/living/carbon/human/U = user - if(U.job in list("Research Director")) - playsound(src, 'sound/effects/meteorimpact.ogg', 100, TRUE) - for(var/mob/M in urange(8, src)) - if(!M.stat) - shake_camera(M, 2, 3) - if(wizard) - U.visible_message("[src] transforms into [wizard] as [U] suplexes them!", "As you grab [src], it suddenly turns into [wizard] as you suplex them!") - to_chat(wizard, "You're suddenly jolted out of rod-form as [U] somehow manages to grab you, slamming you into the ground!") - wizard.Stun(60) - wizard.apply_damage(25, BRUTE) - qdel(src) - else - U.client.give_award(/datum/award/achievement/misc/feat_of_strength, U) //rod-form wizards would probably make this a lot easier to get so keep it to regular rods only - U.visible_message("[U] suplexes [src] into the ground!", "You suplex [src] into the ground!") - new /obj/structure/festivus/anchored(drop_location()) - new /obj/effect/anomaly/flux(drop_location()) - qdel(src) + . = ..() + if(.) + return + + if(!(HAS_TRAIT(user, TRAIT_ROD_SUPLEX) || (user.mind && HAS_TRAIT(user.mind, TRAIT_ROD_SUPLEX)))) + return + + playsound(src, 'sound/effects/meteorimpact.ogg', 100, TRUE) + for(var/mob/M in urange(8, src)) + if(M.stat != CONSCIOUS) + continue + shake_camera(M, 2, 3) + + if(wizard) + user.visible_message("[src] transforms into [wizard] as [user] suplexes them!", "As you grab [src], it suddenly turns into [wizard] as you suplex them!") + to_chat(wizard, "You're suddenly jolted out of rod-form as [user] somehow manages to grab you, slamming you into the ground!") + wizard.Stun(60) + wizard.apply_damage(25, BRUTE) + qdel(src) + else + user.client.give_award(/datum/award/achievement/misc/feat_of_strength, user) //rod-form wizards would probably make this a lot easier to get so keep it to regular rods only + user.visible_message("[user] suplexes [src] into the ground!", "You suplex [src] into the ground!") + new /obj/structure/festivus/anchored(drop_location()) + new /obj/effect/anomaly/flux(drop_location()) + qdel(src) + + return TRUE diff --git a/code/modules/jobs/job_types/research_director.dm b/code/modules/jobs/job_types/research_director.dm index c00760c4e44..824effb5e65 100644 --- a/code/modules/jobs/job_types/research_director.dm +++ b/code/modules/jobs/job_types/research_director.dm @@ -51,6 +51,8 @@ backpack = /obj/item/storage/backpack/science satchel = /obj/item/storage/backpack/satchel/tox + skillchips = list(/obj/item/skillchip/job/research_director) + chameleon_extras = /obj/item/stamp/rd /datum/outfit/job/rd/rig diff --git a/code/modules/library/skill_learning/job_skillchips/research_director.dm b/code/modules/library/skill_learning/job_skillchips/research_director.dm new file mode 100644 index 00000000000..6d6b11142f7 --- /dev/null +++ b/code/modules/library/skill_learning/job_skillchips/research_director.dm @@ -0,0 +1,9 @@ +/obj/item/skillchip/job/research_director + name = "R.D.S.P.L.X. skillchip" + desc = "Knowledge of how to solve the ancient conumdrum; what happens when an unstoppable force meets an immovable object." + auto_traits = list(TRAIT_ROD_SUPLEX) + skill_name = "True Strength" + skill_description = "The knowledge and strength to resolve the most ancient conumdrum; what happens when an unstoppable force meets an immovable object." + skill_icon = "dumbbell" + activate_message = "You realise if you apply the correct force, at the correct angle, it is possible to make the immovable permamently movable." + deactivate_message = "You forget how to permamently anchor a paradoxical object." diff --git a/tgstation.dme b/tgstation.dme index ddb272dcec9..784cee67f0a 100644 --- a/tgstation.dme +++ b/tgstation.dme @@ -2195,6 +2195,7 @@ #include "code\modules\library\skill_learning\skill_station.dm" #include "code\modules\library\skill_learning\skillchip.dm" #include "code\modules\library\skill_learning\job_skillchips\_job.dm" +#include "code\modules\library\skill_learning\job_skillchips\research_director.dm" #include "code\modules\library\skill_learning\job_skillchips\roboticist.dm" #include "code\modules\library\skill_learning\job_skillchips\station_engineer.dm" #include "code\modules\library\skill_learning\job_skillchips\psychologist.dm"