Getting Medieval - Breach Cleaver (#26298)

* Securiblade, Sheaths

* Snakesfang and Cleaver

* Crates and Armory

* Origin Tech Fix

* Chargers can now accept securiblades

* Clan Cleaver is now Breach Cleaver

* Armor Checking

* Comment and description fixes

* State comment

* More Comments

* Contains list fix

Co-authored-by: 1080pCat <96908085+1080pCat@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>

* Breacher sword hates doors

* Tab indentation

* Breacher Armor Buff - Status Effect while wielding

* Breach Cleaver Sounds - courtesy of Stoniest

* Snakesfang Codersprites

* Define Fix

* Breach Cleaver - Icon Codersprites

* Breach Cleaver Codersprites

* Gave help-intent attack on cleaver an animation

* Reduced sound intensity of wielded harm

* Moved variables below inherits

* Buff spacing, guard clause

* Improved examine

* Guard clauses the secsword powercell

* Sword mode defines

* Added undefs

* Spacing

* Securiblade loreful examine_more

* Examine_More for all swords

* Grammar

Co-authored-by: Luc <89928798+lewcc@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>

* Moved defines, added auto-docs, grammar

* Fixed secsword recharging

* Secsword burn function fix

* Cleaver Armor Buff Fix

* Fix to buff

* Securiblade burn fix, stamina charge reduction fix

* Breach Cleaver - Wielding sprite consistency, fixed sheath orientation when unsheathed

* Fixes securiblade EMP oversight

* Snakesfang can parry now

* Spelling

* Removed define indents

* Early returns

* A whole lot of fixes. Qdels the cell on delete.

* stun_delay proc doc

* Update code/datums/uplink_items/uplink_general.dm

Signed-off-by: DGamerL <108773801+DGamerL@users.noreply.github.com>

* Merged IF statements, relocated inits

* Armor change

* Remove null in cell variable

* Ifs to Switch

* Revert "Armor change"

This reverts commit 6b61e33433.

* Better Ifs to Switch

* Removes roundstart armory blade, increases crate cost to 550

* Removed extraneous loc check, removed extraneous link cell proc

* Added null check to secsword/emp_act

* Added clear_cell proc to replace duplicate icon updates and cell nulls

* No vars in proc argument

* Properly nulls cell. Fixes cell sabotage for sword

* JustTheCleaver

* Forgot about the recharger

* Logic Change - Combined two Ifs

Co-authored-by: DGamerL <108773801+DGamerL@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>

* Removed  extraneous permit var

Co-authored-by: DGamerL <108773801+DGamerL@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>

* Early returns on object attacks

* Fixed missing cleaver sheath

* Fixed comment format

Co-authored-by: 1080pCat <96908085+1080pCat@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>

* Removed extraneous line

Co-authored-by: DGamerL <108773801+DGamerL@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>

* cleaving_armor_boost variable standardization

* Added intent and effects to attack logs

* Added notice to description span for antags

* Made the armor buff into a var

* Replaced get_dir(src, get_step away(H, src) with user.src

* Fixed stat check

* AP Changes

---------

Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>
Signed-off-by: DGamerL <108773801+DGamerL@users.noreply.github.com>
Co-authored-by: 1080pCat <96908085+1080pCat@users.noreply.github.com>
Co-authored-by: S34N <12197162+S34NW@users.noreply.github.com>
Co-authored-by: Luc <89928798+lewcc@users.noreply.github.com>
Co-authored-by: DGamerL <108773801+DGamerL@users.noreply.github.com>
This commit is contained in:
PollardTheDragon
2024-08-08 21:03:47 -04:00
committed by GitHub
parent 8ee325ecd7
commit 2d94ff16f4
13 changed files with 171 additions and 0 deletions
@@ -92,6 +92,127 @@
plastitanium edge that can cause untold harm to a soft target. In the right hands, it can be a terrifying weapon to behold, \
and its said that blood runs down the blade in just the right way, to drip artfully from the twin fangs at its apex."
// Unathi Sword
/obj/item/melee/breach_cleaver
name = "breach cleaver"
desc = "Massive, heavy, and utterly impractical. This sharpened chunk of steel is too big and too heavy to be called a sword."
lefthand_file = 'icons/mob/inhands/weapons_lefthand.dmi'
righthand_file = 'icons/mob/inhands/weapons_righthand.dmi'
base_icon_state = "breach_cleaver"
icon_state = "breach_cleaver0"
flags = CONDUCT
force = 5
throwforce = 5
armour_penetration_flat = 30
w_class = WEIGHT_CLASS_BULKY
sharp = TRUE
origin_tech = "combat=6;syndicate=5"
attack_verb = list("slashed", "cleaved", "chopped")
hitsound = 'sound/weapons/swordhitheavy.ogg'
materials = list(MAT_METAL = 2000)
/// How much damage the sword does when wielded
var/force_wield = 40
/obj/item/melee/breach_cleaver/Initialize(mapload)
. = ..()
AddComponent(/datum/component/two_handed, force_wielded = force_wield, force_unwielded = force, icon_wielded = "[base_icon_state]1", wield_callback = CALLBACK(src, PROC_REF(wield)), unwield_callback = CALLBACK(src, PROC_REF(unwield)))
AddComponent(/datum/component/parry, _stamina_constant = 2, _stamina_coefficient = 0.5, _parryable_attack_types = NON_PROJECTILE_ATTACKS)
/obj/item/melee/breach_cleaver/examine(mob/user)
. = ..()
if(isAntag(user))
. += "<span class='notice'>When wielded, this blade has different effects depending on your intent, similar to a martial art. \
Help intent will strike with the flat, dealing stamina, disarm intent forces them away, grab intent knocks down the target, \
and harm intent deals heavy damage.</span>"
/obj/item/melee/breach_cleaver/examine_more(mob/user)
. = ..()
. += "Massive, heavy, and utterly impractical. This sharpened chunk of steel is too big and too heavy to be called a sword."
. += ""
. += "The Unathi Breach Cleaver is a weapon the scaled, warlike race favours for its impressive weight and myriad combat applications. \
The pinnacle of Moghes' combat technology, it combines all of this knowledge into a massive, heavy slab of alloyed metal that most \
species find difficult to lift, let alone use in any sort of fight."
. += ""
. += "Actually a little lightweight for its size, a Breach Cleaver is unmatched in combat utility as a weapon, a tool for getting into\
places and as a slab of armour for the wielder. The leather of the Kar'oche beast, a predator native to Moghes, binds the hilt, \
allowing it to be gripped securely by its warrior. The wide blade is often etched with scenes depicting military victories or great hunts."
/obj/item/melee/breach_cleaver/update_icon_state()
icon_state = "[base_icon_state]0"
/obj/item/melee/breach_cleaver/proc/wield(obj/item/source, mob/living/carbon/human/user)
to_chat(user, "<span class='notice'>You heave [src] up in both hands.</span>")
user.apply_status_effect(STATUS_EFFECT_BREACH_AND_CLEAVE)
update_icon_state()
/obj/item/melee/breach_cleaver/proc/unwield(obj/item/source, mob/living/carbon/human/user)
user.remove_status_effect(STATUS_EFFECT_BREACH_AND_CLEAVE)
update_icon_state()
/obj/item/melee/breach_cleaver/attack_obj(obj/O, mob/living/user, params)
if(!HAS_TRAIT(src, TRAIT_WIELDED)) // Only works good when wielded
return ..()
if(!ismachinery(O) && !isstructure(O)) // This sword hates doors
return ..()
if(SEND_SIGNAL(src, COMSIG_ITEM_ATTACK_OBJ, O, user) & COMPONENT_NO_ATTACK_OBJ)
return
if(flags & (NOBLUDGEON))
return
var/mob/living/carbon/human/H = user
H.changeNext_move(CLICK_CD_MELEE)
H.do_attack_animation(O)
H.visible_message("<span class='danger'>[H] has hit [O] with [src]!</span>", "<span class='danger'>You hit [O] with [src]!</span>")
var/damage = force_wield
damage += H.physiology.melee_bonus
O.take_damage(damage * 3, BRUTE, MELEE, TRUE, get_dir(src, H), 30) // Multiplied to do big damage to doors, closets, windows, and machines, but normal damage to mobs.
/obj/item/melee/breach_cleaver/attack(mob/target, mob/living/user)
if(!HAS_TRAIT(src, TRAIT_WIELDED) || !ishuman(target))
return ..()
var/mob/living/carbon/human/H = target
var/obj/item/organ/external/targetlimb = H.get_organ(ran_zone(user.zone_selected))
switch(user.a_intent)
if(INTENT_HELP) // Stamina damage
H.visible_message("<span class='danger'>[user] slams [H] with the flat of the blade!</span>", \
"<span class='userdanger'>[user] slams you with the flat of the blade!</span>", \
"<span class='italics'>You hear a thud.</span>")
user.do_attack_animation(H, ATTACK_EFFECT_DISARM)
playsound(loc, 'sound/weapons/swordhit.ogg', 50, TRUE, -1)
H.AdjustConfused(4 SECONDS, 0, 4 SECONDS)
H.apply_damage(40, STAMINA, targetlimb, H.run_armor_check(targetlimb, MELEE))
add_attack_logs(user, H, "Slammed by a breach cleaver. (Help intent, Stamina)", ATKLOG_ALL)
if(INTENT_DISARM) // Slams away
if(H.stat != CONSCIOUS || IS_HORIZONTAL(H))
return ..()
H.visible_message("<span class='danger'>[user] smashes [H] with the blade's tip!</span>", \
"<span class='userdanger'>[user] smashes you with the blade's tip!</span>", \
"<span class='italics'>You hear crushing.</span>")
user.do_attack_animation(H, ATTACK_EFFECT_KICK)
playsound(get_turf(user), 'sound/weapons/sonic_jackhammer.ogg', 50, TRUE, -1)
H.apply_damage(25, BRUTE, targetlimb, H.run_armor_check(targetlimb, MELEE))
var/atom/throw_target = get_edge_target_turf(H, user.dir, TRUE)
H.throw_at(throw_target, 4, 1)
add_attack_logs(user, H, "Smashed away by a breach cleaver. (Disarm intent, Knockback)", ATKLOG_ALL)
if(INTENT_GRAB) // Knocks down
H.visible_message("<span class='danger'>[user] cleaves [H] with an overhead strike!</span>", \
"<span class='userdanger'>[user] cleaves you with an overhead strike!</span>", \
"<span class='italics'>You hear a chopping noise.</span>")
user.do_attack_animation(H, ATTACK_EFFECT_DISARM)
playsound(get_turf(user), 'sound/weapons/armblade.ogg', 50, TRUE, -1)
H.apply_damage(30, BRUTE, targetlimb, H.run_armor_check(targetlimb, MELEE), TRUE)
H.KnockDown(4 SECONDS)
add_attack_logs(user, H, "Cleaved overhead with a breach cleaver. (Grab intent, Knockdown)", ATKLOG_ALL)
if(INTENT_HARM)
return ..()
/obj/item/melee/icepick
name = "ice pick"
desc = "Used for chopping ice. Also excellent for mafia esque murders."
@@ -798,6 +798,17 @@
new /obj/item/melee/snakesfang(src)
update_appearance(UPDATE_ICON_STATE)
/obj/item/storage/belt/sheath/breach_cleaver
name = "breach cleaver scabbard"
desc = "Can hold massive cleavers."
icon_state = "breachcleaversheath"
item_state = "breachcleaversheath"
can_hold = list(/obj/item/melee/breach_cleaver)
/obj/item/storage/belt/sheath/breach_cleaver/populate_contents()
new /obj/item/melee/breach_cleaver(src)
update_icon()
// -------------------------------------
// Bluespace Belt
// -------------------------------------