From d17472b8f27657389f2e168327995f5af2ec5e62 Mon Sep 17 00:00:00 2001 From: kevinz000 <2003111+kevinz000@users.noreply.github.com> Date: Sun, 26 Jan 2020 22:00:19 -0700 Subject: [PATCH 1/3] Update species.dm --- .../mob/living/carbon/human/species.dm | 44 +++++++++---------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/code/modules/mob/living/carbon/human/species.dm b/code/modules/mob/living/carbon/human/species.dm index 3357cc9ffe..64ff1fe333 100644 --- a/code/modules/mob/living/carbon/human/species.dm +++ b/code/modules/mob/living/carbon/human/species.dm @@ -1884,6 +1884,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) if(get_turf(target) == target_oldturf) shove_blocked = TRUE + var/append_message = "" if(shove_blocked && !target.buckled) var/directional_blocked = !target.Adjacent(target_shove_turf) var/targetatrest = target.resting @@ -1897,33 +1898,32 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) target_collateral_human.Knockdown(SHOVE_KNOCKDOWN_COLLATERAL) user.visible_message("[user.name] shoves [target.name] into [target_collateral_human.name]!", "You shove [target.name] into [target_collateral_human.name]!", null, COMBAT_MESSAGE_RANGE) - log_combat(user, target, "shoved", "into [target_collateral_human.name]") + append_message += ", into [target_collateral_human.name]" else user.visible_message("[user.name] shoves [target.name]!", "You shove [target.name]!", null, COMBAT_MESSAGE_RANGE) - var/target_held_item = target.get_active_held_item() - var/knocked_item = FALSE - if(!is_type_in_typecache(target_held_item, GLOB.shove_disarming_types)) - target_held_item = null - if(!target.has_movespeed_modifier(MOVESPEED_ID_SHOVE)) - target.add_movespeed_modifier(MOVESPEED_ID_SHOVE, multiplicative_slowdown = SHOVE_SLOWDOWN_STRENGTH) - if(target_held_item) - target.visible_message("[target.name]'s grip on \the [target_held_item] loosens!", - "Your grip on \the [target_held_item] loosens!", null, COMBAT_MESSAGE_RANGE) - addtimer(CALLBACK(target, /mob/living/carbon/human/proc/clear_shove_slowdown), SHOVE_SLOWDOWN_LENGTH) - else if(target_held_item) - target.dropItemToGround(target_held_item) - knocked_item = TRUE - target.visible_message("[target.name] drops \the [target_held_item]!!", - "You drop \the [target_held_item]!!", null, COMBAT_MESSAGE_RANGE) - var/append_message = "" + var/target_held_item = target.get_active_held_item() + var/knocked_item = FALSE + if(!is_type_in_typecache(target_held_item, GLOB.shove_disarming_types)) + target_held_item = null + if(!target.has_movespeed_modifier(MOVESPEED_ID_SHOVE)) + target.add_movespeed_modifier(MOVESPEED_ID_SHOVE, multiplicative_slowdown = SHOVE_SLOWDOWN_STRENGTH) if(target_held_item) - if(knocked_item) - append_message = "causing them to drop [target_held_item]" - else - append_message = "loosening their grip on [target_held_item]" - log_combat(user, target, "shoved", append_message) + target.visible_message("[target.name]'s grip on \the [target_held_item] loosens!", + "Your grip on \the [target_held_item] loosens!", null, COMBAT_MESSAGE_RANGE) + addtimer(CALLBACK(target, /mob/living/carbon/human/proc/clear_shove_slowdown), SHOVE_SLOWDOWN_LENGTH) + else if(target_held_item) + target.dropItemToGround(target_held_item) + knocked_item = TRUE + target.visible_message("[target.name] drops \the [target_held_item]!!", + "You drop \the [target_held_item]!!", null, COMBAT_MESSAGE_RANGE) + if(target_held_item) + if(knocked_item) + append_message += ", causing them to drop [target_held_item]" + else + append_message += ", loosening their grip on [target_held_item]" + log_combat(user, target, "shoved", append_message) /datum/species/proc/apply_damage(damage, damagetype = BRUTE, def_zone = null, blocked, mob/living/carbon/human/H, forced = FALSE) var/hit_percent = (100-(blocked+armor))/100 From aa129b9539fde8955aec08dc12fbf8e3cccf726d Mon Sep 17 00:00:00 2001 From: kevinz000 <2003111+kevinz000@users.noreply.github.com> Date: Tue, 4 Feb 2020 03:46:13 -0700 Subject: [PATCH 2/3] Update species.dm --- .../mob/living/carbon/human/species.dm | 20 +++++++++---------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/code/modules/mob/living/carbon/human/species.dm b/code/modules/mob/living/carbon/human/species.dm index 64ff1fe333..e6272ff433 100644 --- a/code/modules/mob/living/carbon/human/species.dm +++ b/code/modules/mob/living/carbon/human/species.dm @@ -1904,25 +1904,23 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) user.visible_message("[user.name] shoves [target.name]!", "You shove [target.name]!", null, COMBAT_MESSAGE_RANGE) var/target_held_item = target.get_active_held_item() - var/knocked_item = FALSE if(!is_type_in_typecache(target_held_item, GLOB.shove_disarming_types)) target_held_item = null if(!target.has_movespeed_modifier(MOVESPEED_ID_SHOVE)) target.add_movespeed_modifier(MOVESPEED_ID_SHOVE, multiplicative_slowdown = SHOVE_SLOWDOWN_STRENGTH) if(target_held_item) - target.visible_message("[target.name]'s grip on \the [target_held_item] loosens!", - "Your grip on \the [target_held_item] loosens!", null, COMBAT_MESSAGE_RANGE) + if(!HAS_TRAIT(target_held_item, TRAIT_NODROP)) + target.visible_message("[target.name]'s grip on \the [target_held_item] loosens!", + "Your grip on \the [target_held_item] loosens!", null, COMBAT_MESSAGE_RANGE) + append_message += ", loosening their grip on [target_held_item]" + else + append_message += ", but couldn't loose their grip on [target_held_item]" addtimer(CALLBACK(target, /mob/living/carbon/human/proc/clear_shove_slowdown), SHOVE_SLOWDOWN_LENGTH) else if(target_held_item) - target.dropItemToGround(target_held_item) - knocked_item = TRUE - target.visible_message("[target.name] drops \the [target_held_item]!!", - "You drop \the [target_held_item]!!", null, COMBAT_MESSAGE_RANGE) - if(target_held_item) - if(knocked_item) + if(target.dropItemToGround(target_held_item)) + target.visible_message("[target.name] drops \the [target_held_item]!!", + "You drop \the [target_held_item]!!", null, COMBAT_MESSAGE_RANGE) append_message += ", causing them to drop [target_held_item]" - else - append_message += ", loosening their grip on [target_held_item]" log_combat(user, target, "shoved", append_message) /datum/species/proc/apply_damage(damage, damagetype = BRUTE, def_zone = null, blocked, mob/living/carbon/human/H, forced = FALSE) From 68cbc3487af3f61e9dee75f271a37b9a7d72270a Mon Sep 17 00:00:00 2001 From: Ghom <42542238+Ghommie@users.noreply.github.com> Date: Wed, 5 Feb 2020 07:09:55 +0100 Subject: [PATCH 3/3] Update species.dm --- 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 e6272ff433..1b6fd406a1 100644 --- a/code/modules/mob/living/carbon/human/species.dm +++ b/code/modules/mob/living/carbon/human/species.dm @@ -1903,7 +1903,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names) else user.visible_message("[user.name] shoves [target.name]!", "You shove [target.name]!", null, COMBAT_MESSAGE_RANGE) - var/target_held_item = target.get_active_held_item() + var/obj/item/target_held_item = target.get_active_held_item() if(!is_type_in_typecache(target_held_item, GLOB.shove_disarming_types)) target_held_item = null if(!target.has_movespeed_modifier(MOVESPEED_ID_SHOVE))