#define WRIST_WRENCH_COMBO "DD" #define BACK_KICK_COMBO "HG" #define STOMACH_KNEE_COMBO "GH" #define HEAD_KICK_COMBO "DHH" #define ELBOW_DROP_COMBO "HDHDH" /datum/martial_art/the_sleeping_carp name = "The Sleeping Carp" deflection_chance = 100 no_guns = TRUE allow_temp_override = FALSE help_verb = /mob/living/carbon/human/proc/sleeping_carp_help /datum/martial_art/the_sleeping_carp/proc/check_streak(mob/living/carbon/human/A, mob/living/carbon/human/D) if(findtext(streak,WRIST_WRENCH_COMBO)) streak = "" wristWrench(A,D) return 1 if(findtext(streak,BACK_KICK_COMBO)) streak = "" backKick(A,D) return 1 if(findtext(streak,STOMACH_KNEE_COMBO)) streak = "" kneeStomach(A,D) return 1 if(findtext(streak,HEAD_KICK_COMBO)) streak = "" headKick(A,D) return 1 if(findtext(streak,ELBOW_DROP_COMBO)) streak = "" elbowDrop(A,D) return 1 return 0 /datum/martial_art/the_sleeping_carp/proc/wristWrench(mob/living/carbon/human/A, mob/living/carbon/human/D) if(!D.stat && !D.stunned && !D.weakened) A.do_attack_animation(D, ATTACK_EFFECT_PUNCH) D.visible_message("[A] grabs [D]'s wrist and wrenches it sideways!", \ "[A] grabs your wrist and violently wrenches it to the side!") playsound(get_turf(A), 'sound/weapons/thudswoosh.ogg', 50, 1, -1) D.emote("scream") D.drop_item() D.apply_damage(5, BRUTE, pick("l_arm", "r_arm")) D.Stun(3) return 1 add_logs(A, D, "wrist wrenched (Sleeping Carp)") return basic_hit(A,D) /datum/martial_art/the_sleeping_carp/proc/backKick(mob/living/carbon/human/A, mob/living/carbon/human/D) if(A.dir == D.dir && !D.stat && !D.weakened) A.do_attack_animation(D, ATTACK_EFFECT_PUNCH) D.visible_message("[A] kicks [D] in the back!", \ "[A] kicks you in the back, making you stumble and fall!") step_to(D,get_step(D,D.dir),1) D.Weaken(4) playsound(get_turf(D), 'sound/weapons/punch1.ogg', 50, 1, -1) return 1 add_logs(A, D, "back-kicked (Sleeping Carp)") return basic_hit(A,D) /datum/martial_art/the_sleeping_carp/proc/kneeStomach(mob/living/carbon/human/A, mob/living/carbon/human/D) if(!D.stat && !D.weakened) A.do_attack_animation(D, ATTACK_EFFECT_KICK) D.visible_message("[A] knees [D] in the stomach!", \ "[A] winds you with a knee in the stomach!") D.audible_message("[D] gags!") D.losebreath += 3 D.Stun(2) playsound(get_turf(D), 'sound/weapons/punch1.ogg', 50, 1, -1) return 1 add_logs(A, D, "stomach kneed (Sleeping Carp)") return basic_hit(A,D) /datum/martial_art/the_sleeping_carp/proc/headKick(mob/living/carbon/human/A, mob/living/carbon/human/D) if(!D.stat && !D.weakened) A.do_attack_animation(D, ATTACK_EFFECT_KICK) D.visible_message("[A] kicks [D] in the head!", \ "[A] kicks you in the jaw!") D.apply_damage(20, BRUTE, "head") D.drop_item() playsound(get_turf(D), 'sound/weapons/punch1.ogg', 50, 1, -1) D.Stun(4) return 1 add_logs(A, D, "head kicked (Sleeping Carp)") return basic_hit(A,D) /datum/martial_art/the_sleeping_carp/proc/elbowDrop(mob/living/carbon/human/A, mob/living/carbon/human/D) if(D.weakened || D.resting || D.stat) A.do_attack_animation(D, ATTACK_EFFECT_PUNCH) D.visible_message("[A] elbow drops [D]!", \ "[A] piledrives you with their elbow!") if(D.stat) D.death() //FINISH HIM! D.apply_damage(50, BRUTE, "chest") playsound(get_turf(D), 'sound/weapons/punch1.ogg', 75, 1, -1) return 1 add_logs(A, D, "elbow dropped (Sleeping Carp)") return basic_hit(A,D) /datum/martial_art/the_sleeping_carp/grab_act(mob/living/carbon/human/A, mob/living/carbon/human/D) add_to_streak("G",D) if(check_streak(A,D)) return 1 if(A.grab_state >= GRAB_AGGRESSIVE) D.grabbedby(A, 1) else A.start_pulling(D, 1) if(A.pulling) D.drop_all_held_items() D.stop_pulling() if(A.a_intent == INTENT_GRAB) add_logs(A, D, "grabbed", addition="aggressively") A.grab_state = GRAB_AGGRESSIVE //Instant aggressive grab else add_logs(A, D, "grabbed", addition="passively") A.grab_state = GRAB_PASSIVE return 1 /datum/martial_art/the_sleeping_carp/harm_act(mob/living/carbon/human/A, mob/living/carbon/human/D) add_to_streak("H",D) if(check_streak(A,D)) return 1 A.do_attack_animation(D, ATTACK_EFFECT_PUNCH) var/atk_verb = pick("punches", "kicks", "chops", "hits", "slams") D.visible_message("[A] [atk_verb] [D]!", \ "[A] [atk_verb] you!") D.apply_damage(rand(10,15), BRUTE) playsound(get_turf(D), 'sound/weapons/punch1.ogg', 25, 1, -1) if(prob(D.getBruteLoss()) && !D.lying) D.visible_message("[D] stumbles and falls!", "The blow sends you to the ground!") D.Weaken(4) add_logs(A, D, "[atk_verb] (Sleeping Carp)") return 1 /datum/martial_art/the_sleeping_carp/disarm_act(mob/living/carbon/human/A, mob/living/carbon/human/D) add_to_streak("D",D) if(check_streak(A,D)) return 1 return ..() /mob/living/carbon/human/proc/sleeping_carp_help() set name = "Recall Teachings" set desc = "Remember the martial techniques of the Sleeping Carp clan." set category = "Sleeping Carp" to_chat(usr, "You retreat inward and recall the teachings of the Sleeping Carp...") to_chat(usr, "Wrist Wrench: Disarm Disarm. Forces opponent to drop item in hand.") to_chat(usr, "Back Kick: Harm Grab. Opponent must be facing away. Knocks down.") to_chat(usr, "Stomach Knee: Grab Harm. Knocks the wind out of opponent and stuns.") to_chat(usr, "Head Kick: Disarm Harm Harm. Decent damage, forces opponent to drop item in hand.") to_chat(usr, "Elbow Drop: Harm Disarm Harm Disarm Harm. Opponent must be on the ground. Deals huge damage, instantly kills anyone in critical condition.") /obj/item/weapon/sleeping_carp_scroll name = "mysterious scroll" desc = "A scroll filled with strange markings. It seems to be drawings of some sort of martial art." icon = 'icons/obj/wizard.dmi' icon_state = "scroll2" /obj/item/weapon/sleeping_carp_scroll/attack_self(mob/living/carbon/human/user) if(!istype(user) || !user) return var/message = "You have learned the ancient martial art of the Sleeping Carp! Your hand-to-hand combat has become much more effective, and you are now able to deflect any projectiles \ directed toward you. However, you are also unable to use any ranged weaponry. You can learn more about your newfound art by using the Recall Teachings verb in the Sleeping Carp tab." to_chat(user, message) var/datum/martial_art/the_sleeping_carp/theSleepingCarp = new(null) theSleepingCarp.teach(user) user.drop_item() visible_message("[src] lights up in fire and quickly burns to ash.") new /obj/effect/decal/cleanable/ash(get_turf(src)) qdel(src) /obj/item/weapon/twohanded/bostaff name = "bo staff" desc = "A long, tall staff made of polished wood. Traditionally used in ancient old-Earth martial arts. Can be wielded to both kill and incapacitate." force = 10 w_class = WEIGHT_CLASS_BULKY slot_flags = SLOT_BACK force_unwielded = 10 force_wielded = 24 throwforce = 20 throw_speed = 2 attack_verb = list("smashed", "slammed", "whacked", "thwacked") icon = 'icons/obj/weapons.dmi' icon_state = "bostaff0" block_chance = 50 /obj/item/weapon/twohanded/bostaff/update_icon() icon_state = "bostaff[wielded]" return /obj/item/weapon/twohanded/bostaff/attack(mob/target, mob/living/user) add_fingerprint(user) if((CLUMSY in user.disabilities) && prob(50)) to_chat(user, "You club yourself over the head with [src].") user.Weaken(3) if(ishuman(user)) var/mob/living/carbon/human/H = user H.apply_damage(2*force, BRUTE, "head") else user.take_bodypart_damage(2*force) return if(iscyborg(target)) return ..() if(!isliving(target)) return ..() var/mob/living/carbon/C = target if(C.stat) to_chat(user, "It would be dishonorable to attack a foe while they cannot retaliate.") return if(user.a_intent == INTENT_DISARM) if(!wielded) return ..() if(!ishuman(target)) return ..() var/mob/living/carbon/human/H = target var/list/fluffmessages = list("[user] clubs [H] with [src]!", \ "[user] smacks [H] with the butt of [src]!", \ "[user] broadsides [H] with [src]!", \ "[user] smashes [H]'s head with [src]!", \ "[user] beats [H] with front of [src]!", \ "[user] twirls and slams [H] with [src]!") H.visible_message("[pick(fluffmessages)]", \ "[pick(fluffmessages)]") playsound(get_turf(user), 'sound/effects/woodhit.ogg', 75, 1, -1) H.adjustStaminaLoss(rand(13,20)) if(prob(10)) H.visible_message("[H] collapses!", \ "Your legs give out!") H.Weaken(4) if(H.staminaloss && !H.sleeping) var/total_health = (H.health - H.staminaloss) if(total_health <= HEALTH_THRESHOLD_CRIT && !H.stat) H.visible_message("[user] delivers a heavy hit to [H]'s head, knocking them out cold!", \ "[user] knocks you unconscious!") H.SetSleeping(30) H.adjustBrainLoss(25) else return ..() /obj/item/weapon/twohanded/bostaff/hit_reaction(mob/living/carbon/human/owner, attack_text, final_block_chance) if(wielded) return ..() return 0