From 26dfff87fcb99162207b252df274fe2e1e282deb Mon Sep 17 00:00:00 2001 From: keronshb Date: Fri, 29 Jan 2021 13:17:46 -0500 Subject: [PATCH] Slight stat buffs, adds parries and comments Should be pretty close to 20tc worthy. --- .../projectiles/guns/magic/motivation.dm | 38 ++++++++++++++++++- .../projectile/special/judgement_cut.dm | 2 - 2 files changed, 36 insertions(+), 4 deletions(-) diff --git a/code/modules/projectiles/guns/magic/motivation.dm b/code/modules/projectiles/guns/magic/motivation.dm index 5c59667c6c..2e5994dec7 100644 --- a/code/modules/projectiles/guns/magic/motivation.dm +++ b/code/modules/projectiles/guns/magic/motivation.dm @@ -8,7 +8,7 @@ righthand_file = 'icons/mob/inhands/weapons/swords_righthand.dmi' fire_sound = 'sound/weapons/judgementhit.ogg' ammo_type = /obj/item/ammo_casing/magic/judgement_cut - force = 20 + force = 20 //so it's worth that 20 tc armour_penetration = 50 w_class = WEIGHT_CLASS_NORMAL slot_flags = ITEM_SLOT_BELT @@ -20,31 +20,37 @@ max_charges = 3 recharge_rate = 5 var/datum/action/judgement_cut/judgementcut = new/datum/action/judgement_cut() + block_parry_data = /datum/block_parry_data/motivation - +//to get this to toggle correctly /obj/item/gun/magic/staff/motivation/Initialize() . = ..() judgementcut = new(src) +//lets the user know that their judgment cuts are recharging /obj/item/gun/magic/staff/motivation/shoot_with_empty_chamber(mob/living/user as mob|obj) to_chat(user, "Judgment Cut is recharging.") +//action button to toggle judgement cuts on/off /datum/action/judgement_cut name = "Judgement Cut - Allows Motivation to slash at a longer distance." icon_icon = 'icons/obj/projectiles.dmi' button_icon_state = "judgement_fire" var/judgement_toggled = TRUE +//lets the user know that you toggled them on/off /datum/action/judgement_cut/Trigger() judgement_toggled = !judgement_toggled to_chat(owner, "You [judgement_toggled ? "enable" : "disable"] Judgement Cuts with Motivation.") +//Prevents "firing" the judgement cuts if toggled off and lets the user know /obj/item/gun/magic/staff/motivation/can_trigger_gun(mob/living/user) . = ..() if(!judgementcut.judgement_toggled) to_chat(user, " Judgment Cut is disabled.") return FALSE +//adds/removes judgement cut and judgement cut end upon pickup/drop /obj/item/gun/magic/staff/motivation/pickup(mob/living/user) . = ..() judgementcut.Grant(user, src) @@ -55,3 +61,31 @@ . = ..() judgementcut.Remove(user) user.update_icons() + +//A parry tight enough to stagger, but not to counter attack +/datum/block_parry_data/motivation + parry_time_windup = 0.5 + parry_time_active = 5 + parry_time_spindown = 0 + parry_attack_types = ALL + parry_time_active_visual_override = 3 + parry_time_spindown_visual_override = 2 + parry_flags = PARRY_DEFAULT_HANDLE_FEEDBACK | PARRY_LOCK_ATTACKING + parry_time_perfect = 0 + parry_time_perfect_leeway = 3 + parry_time_perfect_leeway_override = list( + TEXT_ATTACK_TYPE_PROJECTILE = 1 + ) + parry_imperfect_falloff_percent_override = list( + TEXT_ATTACK_TYPE_PROJECTILE = 50 // useless after 3rd decisecond + ) + parry_imperfect_falloff_percent = 30 + parry_efficiency_to_counterattack = 100 + parry_efficiency_considered_successful = 1 + parry_efficiency_perfect = 100 + parry_data = list( + PARRY_STAGGER_ATTACKER = 10 + ) + parry_failed_stagger_duration = 2 SECONDS + parry_failed_clickcd_duration = CLICK_CD_RANGE + parry_cooldown = 0 \ No newline at end of file diff --git a/code/modules/projectiles/projectile/special/judgement_cut.dm b/code/modules/projectiles/projectile/special/judgement_cut.dm index 421bb71255..0ccc67402f 100644 --- a/code/modules/projectiles/projectile/special/judgement_cut.dm +++ b/code/modules/projectiles/projectile/special/judgement_cut.dm @@ -9,9 +9,7 @@ sharpness = SHARP_EDGED impact_effect_type = /obj/effect/temp_visual/impact_effect/judgement_cut - /obj/item/projectile/judgement_cut/on_hit(atom/target, blocked = FALSE) . = ..() if(ishuman(target)) - var/mob/living/carbon/human/H = target new /obj/effect/temp_visual/impact_effect/judgement_cut(src) \ No newline at end of file