From 157ef93c0b429ffe3e03b10dc557252b913c0fd8 Mon Sep 17 00:00:00 2001 From: necromanceranne Date: Wed, 1 Apr 2020 15:12:59 +1100 Subject: [PATCH 1/5] I think everyone should be landing punches now. --- code/modules/mob/living/carbon/human/species.dm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/code/modules/mob/living/carbon/human/species.dm b/code/modules/mob/living/carbon/human/species.dm index f0bf2fc23e..199f9de4a1 100644 --- a/code/modules/mob/living/carbon/human/species.dm +++ b/code/modules/mob/living/carbon/human/species.dm @@ -1477,6 +1477,8 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) user.adjustStaminaLossBuffered(5) //CITADEL CHANGE - makes punching cause staminaloss var/damage = rand(user.dna.species.punchdamagelow, user.dna.species.punchdamagehigh) + var/puncherstam = user.getStaminaLoss() + var/puncherbrute = user.getBruteLoss() //CITADEL CHANGES - makes resting and disabled combat mode reduce punch damage, makes being out of combat mode result in you taking more damage if(!(target.combat_flags & COMBAT_FLAG_COMBAT_ACTIVE) && damage < user.dna.species.punchstunthreshold) @@ -1494,7 +1496,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) if(atk_verb == ATTACK_EFFECT_KICK) //kicks never miss (provided your species deals more than 0 damage) miss_chance = 0 else - miss_chance = min((user.dna.species.punchdamagehigh/user.dna.species.punchdamagelow) + user.getStaminaLoss() + (user.getBruteLoss()*0.5), 100) //old base chance for a miss + various damage. capped at 100 to prevent weirdness in prob() + miss_chance = min(puncherstam + (puncherbrute*0.5), 100) //probability of miss based on stamina + half of brute. capped at 100 to prevent weirdness in prob() if(!damage || !affecting || prob(miss_chance))//future-proofing for species that have 0 damage/weird cases where no zone is targeted playsound(target.loc, user.dna.species.miss_sound, 25, TRUE, -1) From 13c474f2af08623e48344481d3d9348f87dbe356 Mon Sep 17 00:00:00 2001 From: necromanceranne Date: Wed, 1 Apr 2020 22:05:22 +1100 Subject: [PATCH 2/5] brawling just got mathematical? --- code/modules/mob/living/carbon/human/species.dm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/code/modules/mob/living/carbon/human/species.dm b/code/modules/mob/living/carbon/human/species.dm index 199f9de4a1..3f7b7d5914 100644 --- a/code/modules/mob/living/carbon/human/species.dm +++ b/code/modules/mob/living/carbon/human/species.dm @@ -1479,6 +1479,8 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) var/damage = rand(user.dna.species.punchdamagelow, user.dna.species.punchdamagehigh) var/puncherstam = user.getStaminaLoss() var/puncherbrute = user.getBruteLoss() + var/punchedstam = target.getStaminaLoss() + var/punchedbrute = target.getBruteLoss() //CITADEL CHANGES - makes resting and disabled combat mode reduce punch damage, makes being out of combat mode result in you taking more damage if(!(target.combat_flags & COMBAT_FLAG_COMBAT_ACTIVE) && damage < user.dna.species.punchstunthreshold) @@ -1496,7 +1498,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) if(atk_verb == ATTACK_EFFECT_KICK) //kicks never miss (provided your species deals more than 0 damage) miss_chance = 0 else - miss_chance = min(puncherstam + (puncherbrute*0.5), 100) //probability of miss based on stamina + half of brute. capped at 100 to prevent weirdness in prob() + miss_chance = min(clamp(((puncherstam + puncherbrute)*0.5) - ((punchedstam + punchedbrute)*0.5), 0, 100)) //probability of miss based on half your stamina and brute total against half their stamina and brute total. Capped at max 100 and min 0 to prevent weirdness in prob() if(!damage || !affecting || prob(miss_chance))//future-proofing for species that have 0 damage/weird cases where no zone is targeted playsound(target.loc, user.dna.species.miss_sound, 25, TRUE, -1) From f26a9b948c2c8c65f128aeb52c6346357a36b8eb Mon Sep 17 00:00:00 2001 From: necromanceranne Date: Fri, 3 Apr 2020 10:50:26 +1100 Subject: [PATCH 3/5] pawnch harder get tired less this is a balance change now I guess --- code/modules/mob/living/carbon/human/species.dm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/code/modules/mob/living/carbon/human/species.dm b/code/modules/mob/living/carbon/human/species.dm index 3f7b7d5914..b2aeab4a5c 100644 --- a/code/modules/mob/living/carbon/human/species.dm +++ b/code/modules/mob/living/carbon/human/species.dm @@ -1474,7 +1474,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) else user.do_attack_animation(target, ATTACK_EFFECT_PUNCH) - user.adjustStaminaLossBuffered(5) //CITADEL CHANGE - makes punching cause staminaloss + user.adjustStaminaLossBuffered(3.5) //CITADEL CHANGE - makes punching cause staminaloss var/damage = rand(user.dna.species.punchdamagelow, user.dna.species.punchdamagehigh) var/puncherstam = user.getStaminaLoss() @@ -1483,8 +1483,8 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) var/punchedbrute = target.getBruteLoss() //CITADEL CHANGES - makes resting and disabled combat mode reduce punch damage, makes being out of combat mode result in you taking more damage - if(!(target.combat_flags & COMBAT_FLAG_COMBAT_ACTIVE) && damage < user.dna.species.punchstunthreshold) - damage = user.dna.species.punchstunthreshold - 1 + if(!(target.combat_flags & COMBAT_FLAG_COMBAT_ACTIVE)) + damage *= 1.5 if(!CHECK_MOBILITY(user, MOBILITY_STAND)) damage *= 0.5 if(!(user.combat_flags & COMBAT_FLAG_COMBAT_ACTIVE)) @@ -1498,7 +1498,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) if(atk_verb == ATTACK_EFFECT_KICK) //kicks never miss (provided your species deals more than 0 damage) miss_chance = 0 else - miss_chance = min(clamp(((puncherstam + puncherbrute)*0.5) - ((punchedstam + punchedbrute)*0.5), 0, 100)) //probability of miss based on half your stamina and brute total against half their stamina and brute total. Capped at max 100 and min 0 to prevent weirdness in prob() + miss_chance = min(10 + ((puncherstam + puncherbrute)*0.5), 100) //probability of miss has a base of 10, and modified based on half your stamina and brute total. Capped at max 100 and min 0 to prevent weirdness in prob() if(!damage || !affecting || prob(miss_chance))//future-proofing for species that have 0 damage/weird cases where no zone is targeted playsound(target.loc, user.dna.species.miss_sound, 25, TRUE, -1) @@ -1536,7 +1536,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) target.visible_message("[user] knocks [target] down!", \ "You're knocked down by [user]!", "You hear aggressive shuffling followed by a loud thud!", COMBAT_MESSAGE_RANGE, user) to_chat(user, "You knock [target] down!") - var/knockdown_duration = 40 + (target.getStaminaLoss() + (target.getBruteLoss()*0.5))*0.8 - armor_block + var/knockdown_duration = 40 + (punchedstam + (punchedbrute*0.5))*0.8 - armor_block target.DefaultCombatKnockdown(knockdown_duration) target.forcesay(GLOB.hit_appends) log_combat(user, target, "got a stun punch with their previous punch") From c481db2bfd2497a0c7ef0195d3f035cbb313ca13 Mon Sep 17 00:00:00 2001 From: necromanceranne Date: Fri, 3 Apr 2020 11:25:29 +1100 Subject: [PATCH 4/5] nearly added instastun king hits, now stun punches are more rng --- code/modules/mob/living/carbon/human/species.dm | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/code/modules/mob/living/carbon/human/species.dm b/code/modules/mob/living/carbon/human/species.dm index b2aeab4a5c..5245d4786a 100644 --- a/code/modules/mob/living/carbon/human/species.dm +++ b/code/modules/mob/living/carbon/human/species.dm @@ -1533,13 +1533,14 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) log_combat(user, target, "punched") if((target.stat != DEAD) && damage >= user.dna.species.punchstunthreshold) - target.visible_message("[user] knocks [target] down!", \ - "You're knocked down by [user]!", "You hear aggressive shuffling followed by a loud thud!", COMBAT_MESSAGE_RANGE, user) - to_chat(user, "You knock [target] down!") - var/knockdown_duration = 40 + (punchedstam + (punchedbrute*0.5))*0.8 - armor_block - target.DefaultCombatKnockdown(knockdown_duration) - target.forcesay(GLOB.hit_appends) - log_combat(user, target, "got a stun punch with their previous punch") + if((punchedstam > 50) && prob(punchedstam*0.5)) \\If our punch victim has been hit above the threshold, and they have more than 50 stamina damage, roll for stun, probability of 1% per 2 stamina damage + target.visible_message("[user] knocks [target] down!", \ + "You're knocked down by [user]!", "You hear aggressive shuffling followed by a loud thud!", COMBAT_MESSAGE_RANGE, user) + to_chat(user, "You knock [target] down!") + var/knockdown_duration = 40 + (punchedstam + (punchedbrute*0.5))*0.8 - armor_block + target.DefaultCombatKnockdown(knockdown_duration) + target.forcesay(GLOB.hit_appends) + log_combat(user, target, "got a stun punch with their previous punch") else if(!(target.mobility_flags & MOBILITY_STAND)) target.forcesay(GLOB.hit_appends) From e1a013bcb25636163c35700b56452aaad191b4d7 Mon Sep 17 00:00:00 2001 From: necromanceranne Date: Fri, 3 Apr 2020 11:30:00 +1100 Subject: [PATCH 5/5] I'm tired okay --- code/modules/mob/living/carbon/human/species.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/modules/mob/living/carbon/human/species.dm b/code/modules/mob/living/carbon/human/species.dm index 5245d4786a..34c65982dc 100644 --- a/code/modules/mob/living/carbon/human/species.dm +++ b/code/modules/mob/living/carbon/human/species.dm @@ -1533,7 +1533,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) log_combat(user, target, "punched") if((target.stat != DEAD) && damage >= user.dna.species.punchstunthreshold) - if((punchedstam > 50) && prob(punchedstam*0.5)) \\If our punch victim has been hit above the threshold, and they have more than 50 stamina damage, roll for stun, probability of 1% per 2 stamina damage + if((punchedstam > 50) && prob(punchedstam*0.5)) //If our punch victim has been hit above the threshold, and they have more than 50 stamina damage, roll for stun, probability of 1% per 2 stamina damage target.visible_message("[user] knocks [target] down!", \ "You're knocked down by [user]!", "You hear aggressive shuffling followed by a loud thud!", COMBAT_MESSAGE_RANGE, user) to_chat(user, "You knock [target] down!")