diff --git a/code/datums/martial.dm b/code/datums/martial.dm index 2bc01e0bf6..ae8f92a342 100644 --- a/code/datums/martial.dm +++ b/code/datums/martial.dm @@ -5,6 +5,7 @@ var/current_target var/datum/martial_art/base // The permanent style. This will be null unless the martial art is temporary var/deflection_chance = 0 //Chance to deflect projectiles + var/reroute_deflection = FALSE //Delete the bullet, or actually deflect it in some direction? var/block_chance = 0 //Chance to block melee attacks using items while on throw mode. var/restraining = 0 //used in cqc's disarm_act to check if the disarmed is being restrained and so whether they should be put in a chokehold or not var/help_verb diff --git a/code/datums/martial/sleeping_carp.dm b/code/datums/martial/sleeping_carp.dm index 035e5ac833..5f19c37b99 100644 --- a/code/datums/martial/sleeping_carp.dm +++ b/code/datums/martial/sleeping_carp.dm @@ -7,6 +7,7 @@ /datum/martial_art/the_sleeping_carp name = "The Sleeping Carp" deflection_chance = 100 + reroute_deflection = TRUE no_guns = TRUE allow_temp_override = FALSE help_verb = /mob/living/carbon/human/proc/sleeping_carp_help diff --git a/code/modules/mob/living/carbon/human/human_defense.dm b/code/modules/mob/living/carbon/human/human_defense.dm index 2a75119841..429357d826 100644 --- a/code/modules/mob/living/carbon/human/human_defense.dm +++ b/code/modules/mob/living/carbon/human/human_defense.dm @@ -54,7 +54,12 @@ else visible_message("[src] deflects the projectile!", "You deflect the projectile!") playsound(src, pick('sound/weapons/bulletflyby.ogg', 'sound/weapons/bulletflyby2.ogg', 'sound/weapons/bulletflyby3.ogg'), 75, 1) - return 0 + if(!mind.martial_art.reroute_deflection) + return BULLET_ACT_BLOCK + else + P.firer = src + P.setAngle(rand(0, 360))//SHING + return BULLET_ACT_FORCE_PIERCE if(!(P.original == src && P.firer == src)) //can't block or reflect when shooting yourself if(P.is_reflectable)