From a1b1cf62c808415a7c9f9714c8f7089f4b80db8c Mon Sep 17 00:00:00 2001 From: Anewbe Date: Mon, 17 Oct 2016 21:57:03 -0500 Subject: [PATCH] Disarm spam is less effective --- code/modules/mob/living/carbon/human/human.dm | 1 + .../living/carbon/human/human_attackhand.dm | 5 +++ html/changelogs/Anewbe - Disarm.yml | 36 +++++++++++++++++++ 3 files changed, 42 insertions(+) create mode 100644 html/changelogs/Anewbe - Disarm.yml diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm index f459052a43..2c2cdbafca 100644 --- a/code/modules/mob/living/carbon/human/human.dm +++ b/code/modules/mob/living/carbon/human/human.dm @@ -8,6 +8,7 @@ var/list/hud_list[10] var/embedded_flag //To check if we've need to roll for damage on movement while an item is imbedded in us. var/obj/item/weapon/rig/wearing_rig // This is very not good, but it's much much better than calling get_rig() every update_canmove() call. + var/last_push_time //For human_attackhand.dm, keeps track of the last use of disarm /mob/living/carbon/human/New(var/new_loc, var/new_species = null) diff --git a/code/modules/mob/living/carbon/human/human_attackhand.dm b/code/modules/mob/living/carbon/human/human_attackhand.dm index 6eb6b35a95..bede87c500 100644 --- a/code/modules/mob/living/carbon/human/human_attackhand.dm +++ b/code/modules/mob/living/carbon/human/human_attackhand.dm @@ -260,7 +260,12 @@ visible_message("[src]'s [W] goes off during the struggle!") return W.afterattack(target,src) + if(last_push_time + 30 > world.time) + visible_message("[M] has weakly pushed [src]!") + return + var/randn = rand(1, 100) + last_push_time = world.time if(!(species.flags & NO_SLIP) && randn <= 25) var/armor_check = run_armor_check(affecting, "melee") apply_effect(3, WEAKEN, armor_check) diff --git a/html/changelogs/Anewbe - Disarm.yml b/html/changelogs/Anewbe - Disarm.yml new file mode 100644 index 0000000000..f611b4dfe9 --- /dev/null +++ b/html/changelogs/Anewbe - Disarm.yml @@ -0,0 +1,36 @@ +################################ +# Example Changelog File +# +# Note: This file, and files beginning with ".", and files that don't end in ".yml" will not be read. If you change this file, you will look really dumb. +# +# Your changelog will be merged with a master changelog. (New stuff added only, and only on the date entry for the day it was merged.) +# When it is, any changes listed below will disappear. +# +# Valid Prefixes: +# bugfix +# wip (For works in progress) +# tweak +# soundadd +# sounddel +# rscadd (general adding of nice things) +# rscdel (general deleting of nice things) +# imageadd +# imagedel +# maptweak +# spellcheck (typo fixes) +# experiment +################################# + +# Your name. +author: Anewbe + +# Optional: Remove this file after generating master changelog. Useful for PR changelogs that won't get used again. +delete-after: True + +# Any changes you've made. See valid prefix list above. +# INDENT WITH TWO SPACES. NOT TABS. SPACES. +# SCREW THIS UP AND IT WON'T WORK. +# Also, all entries are changed into a single [] after a master changelog generation. Just remove the brackets when you add new entries. +# Please surround your changes in double quotes ("), as certain characters otherwise screws up compiling. The quotes will not show up in the changelog. +changes: + - tweak: "The effects from empty-handed disarming now have a cooldown." \ No newline at end of file