From 1f381eec66c9afa2e7d040b4bde4f7d4dc3f6909 Mon Sep 17 00:00:00 2001 From: deathride58 Date: Thu, 18 Oct 2018 12:40:08 -0400 Subject: [PATCH] Tweaks disarms and disarm pushes (#7624) The chance for a successful left-click disarm has increased to 45% on targets you're pulling Disarm pushing has been slightly reworked. The random chance for disarm push rolls is now determined by how much staminaloss the target has. Pushing someone who is out of combat mode while you're in combat mode is a guaranteed knockdown. Pushing now deals light stamina loss to the target so long as both you and your target are standing, not enough to robust someone without tiring yourself out in the process, but enough for a tide to get someone knocked down. Disarm push attempts are now logged --- .../modules/mob/living/carbon/human/species.dm | 4 +++- .../modules/mob/living/carbon/human/species.dm | 18 ++++++++---------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/code/modules/mob/living/carbon/human/species.dm b/code/modules/mob/living/carbon/human/species.dm index b2f66e6e7d..bf76b119e9 100644 --- a/code/modules/mob/living/carbon/human/species.dm +++ b/code/modules/mob/living/carbon/human/species.dm @@ -1432,9 +1432,11 @@ GLOBAL_LIST_EMPTY(roundstart_races) if(!target.combatmode) // CITADEL CHANGE randn += -10 //CITADEL CHANGE - being out of combat mode makes it easier for you to get disarmed if(user.resting) //CITADEL CHANGE - randn += 60 //CITADEL CHANGE - No kosher disarming if you're resting + randn += 100 //CITADEL CHANGE - No kosher disarming if you're resting if(!user.combatmode) //CITADEL CHANGE randn += 25 //CITADEL CHANGE - Makes it harder to disarm outside of combat mode + if(user.pulling == target) + randn += -20 //If you have the time to get someone in a grab, you should have a greater chance at snatching the thing in their hand. Will be made completely obsolete by the grab rework but i've got a poor track record for releasing big projects on time so w/e i guess if(randn <= 35)//CIT CHANGE - changes this back to a 35% chance to accomodate for the above being commented out in favor of right-click pushing var/obj/item/I = null diff --git a/modular_citadel/code/modules/mob/living/carbon/human/species.dm b/modular_citadel/code/modules/mob/living/carbon/human/species.dm index 0211975526..9ed84c1401 100644 --- a/modular_citadel/code/modules/mob/living/carbon/human/species.dm +++ b/modular_citadel/code/modules/mob/living/carbon/human/species.dm @@ -37,24 +37,22 @@ var/randomized_zone = ran_zone(user.zone_selected) SEND_SIGNAL(target, COMSIG_HUMAN_DISARM_HIT, user, user.zone_selected) var/obj/item/bodypart/affecting = target.get_bodypart(randomized_zone) - var/randn = rand(1, 100) - if(user.resting) - randn += 20 //Makes it plausible, but unlikely, to push someone over while resting - if(!user.combatmode) - randn += 25 //Makes it impossible to push actually push someone outside of combat mode - if(randn <= 25) + if(!target.combatmode && user.combatmode || prob(target.getStaminaLoss()*(user.resting ? 0.25 : 1)*(user.combatmode ? 1 : 0.05))) //probability depends on staminaloss. it's plausible, but unlikely that you'll be able to push someone over while resting, and pretty rare to successfully push someone outside of combat mode. The few people that even know how to right-click outside of combat mode are a rarity but let's take that into account regardless. playsound(target, 'sound/weapons/thudswoosh.ogg', 50, 1, -1) - target.visible_message("[user] has pushed [target]!", + target.visible_message("[user] [user.combatmode ? "has" : "gently"] pushed [target]!", "[user] has pushed [target]!", null, COMBAT_MESSAGE_RANGE) target.apply_effect(40, EFFECT_KNOCKDOWN, target.run_armor_check(affecting, "melee", "Your armor prevents your fall!", "Your armor softens your fall!")) target.forcesay(GLOB.hit_appends) log_combat(user, target, "disarmed", " pushing them to the ground") return - playsound(target, 'sound/weapons/punchmiss.ogg', 25, 1, -1) - target.visible_message("[user] attempted to push [target]!", \ - "[user] attemped to push [target]!", null, COMBAT_MESSAGE_RANGE) + playsound(target, 'sound/weapons/thudswoosh.ogg', 25, 1, -1) + target.visible_message("[user] [user.combatmode ? "attempted to push" : "tries to gently push"] [target] over!", \ + "[user] [user.combatmode ? "attempted to push" : "tries to gently push"] [target] over!", null, COMBAT_MESSAGE_RANGE) + if(!target.resting && !user.resting && user.combatmode) + target.adjustStaminaLoss(rand(1,5)) //This is the absolute most inefficient way to get someone into soft stamcrit, but if you've got a crowd trying to shove you over, you've no option but to get knocked down and accept fate + log_combat(user, target, "attempted to disarm push") //////////////////// /////BODYPARTS/////