From f48b5d9e46c3d5806ebab4929c0e7668193a9039 Mon Sep 17 00:00:00 2001 From: NovaBot <154629622+NovaBot13@users.noreply.github.com> Date: Mon, 29 Apr 2024 00:58:39 -0400 Subject: [PATCH] [MIRROR] Unarmed Attacks Support Multiple Verbs (#2228) * Unarmed Attacks Support Multiple Verbs (#82876) ## About The Pull Request Unarmed attacks, aka punching people, now is a list and supports having multiple verbs ## Why It's Good For The Game More flavor, RP, realism Lizard claws used to only "slash", now they can "slash" "scratch" "claw" Ethereals have "singe" in addition to "burn" Podmen can "lash" in addition to "slash" Heads can "chomp" in addition to "bite" ## Changelog :cl: code: Unarmed attacks (punches, etc.) now support multiple attack verbs instead of only one /:cl: * Unarmed Attacks Support Multiple Verbs * var rename --------- Co-authored-by: 13spacemen <46101244+13spacemen@users.noreply.github.com> Co-authored-by: SomeRandomOwl <2568378+SomeRandomOwl@users.noreply.github.com> --- .../items/stacks/golem_food/golem_status_effects.dm | 4 ++-- code/modules/mob/living/carbon/human/_species.dm | 2 +- code/modules/surgery/bodyparts/_bodyparts.dm | 4 ++-- code/modules/surgery/bodyparts/head.dm | 2 +- code/modules/surgery/bodyparts/parts.dm | 4 ++-- .../surgery/bodyparts/species_parts/ethereal_bodyparts.dm | 4 ++-- .../surgery/bodyparts/species_parts/lizard_bodyparts.dm | 4 ++-- .../surgery/bodyparts/species_parts/misc_bodyparts.dm | 8 ++++---- .../surgery/bodyparts/species_parts/moth_bodyparts.dm | 4 ++-- modular_nova/master_files/code/datums/traits/good.dm | 8 ++++---- modular_nova/modules/bodyparts/code/_mutant_bodyparts.dm | 4 ++-- modular_nova/modules/bodyparts/code/ghoul_bodyparts.dm | 6 +++--- 12 files changed, 27 insertions(+), 27 deletions(-) diff --git a/code/game/objects/items/stacks/golem_food/golem_status_effects.dm b/code/game/objects/items/stacks/golem_food/golem_status_effects.dm index bf2c628ab97..48fae041de4 100644 --- a/code/game/objects/items/stacks/golem_food/golem_status_effects.dm +++ b/code/game/objects/items/stacks/golem_food/golem_status_effects.dm @@ -294,7 +294,7 @@ /// Make our arm do slashing effects /datum/status_effect/golem/diamond/proc/set_arm_fluff(obj/item/bodypart/arm/arm) - arm.unarmed_attack_verb = "slash" + arm.unarmed_attack_verbs = list("slash") arm.grappled_attack_verb = "lacerate" arm.unarmed_attack_effect = ATTACK_EFFECT_CLAW arm.unarmed_attack_sound = 'sound/weapons/slash.ogg' @@ -315,7 +315,7 @@ /datum/status_effect/golem/diamond/proc/reset_arm_fluff(obj/item/bodypart/arm/arm) if (!arm) return - arm.unarmed_attack_verb = initial(arm.unarmed_attack_verb) + arm.unarmed_attack_verbs = initial(arm.unarmed_attack_verbs) arm.unarmed_attack_effect = initial(arm.unarmed_attack_effect) arm.unarmed_attack_sound = initial(arm.unarmed_attack_sound) arm.unarmed_miss_sound = initial(arm.unarmed_miss_sound) diff --git a/code/modules/mob/living/carbon/human/_species.dm b/code/modules/mob/living/carbon/human/_species.dm index c56f7f489ef..045a0c004da 100644 --- a/code/modules/mob/living/carbon/human/_species.dm +++ b/code/modules/mob/living/carbon/human/_species.dm @@ -1120,7 +1120,7 @@ GLOBAL_LIST_EMPTY(features_by_species) attacking_bodypart = brain.get_attacking_limb(target) if(!attacking_bodypart) attacking_bodypart = user.get_active_hand() - var/atk_verb = attacking_bodypart.unarmed_attack_verb + var/atk_verb = pick(attacking_bodypart.unarmed_attack_verbs) var/atk_effect = attacking_bodypart.unarmed_attack_effect if(atk_effect == ATTACK_EFFECT_BITE) diff --git a/code/modules/surgery/bodyparts/_bodyparts.dm b/code/modules/surgery/bodyparts/_bodyparts.dm index 01be142b15b..ea39b4d67c3 100644 --- a/code/modules/surgery/bodyparts/_bodyparts.dm +++ b/code/modules/surgery/bodyparts/_bodyparts.dm @@ -165,8 +165,8 @@ /// Type of an attack from this limb does. Arms will do punches, Legs for kicks, and head for bites. (TO ADD: tactical chestbumps) var/attack_type = BRUTE - /// the verb used for an unarmed attack when using this limb, such as arm.unarmed_attack_verb = punch - var/unarmed_attack_verb = "bump" + /// the verbs used for an unarmed attack when using this limb, such as arm.unarmed_attack_verbs = list("punch") + var/list/unarmed_attack_verbs = list("bump") /// if we have a special attack verb for hitting someone who is grappled by us, it goes here. var/grappled_attack_verb /// what visual effect is used when this limb is used to strike someone. diff --git a/code/modules/surgery/bodyparts/head.dm b/code/modules/surgery/bodyparts/head.dm index d5855c5433e..bfb5d6e27fb 100644 --- a/code/modules/surgery/bodyparts/head.dm +++ b/code/modules/surgery/bodyparts/head.dm @@ -17,7 +17,7 @@ scars_covered_by_clothes = FALSE grind_results = null is_dimorphic = TRUE - unarmed_attack_verb = "bite" + unarmed_attack_verbs = list("bite", "chomp") unarmed_attack_effect = ATTACK_EFFECT_BITE unarmed_attack_sound = 'sound/weapons/bite.ogg' unarmed_miss_sound = 'sound/weapons/bite.ogg' diff --git a/code/modules/surgery/bodyparts/parts.dm b/code/modules/surgery/bodyparts/parts.dm index 22450ca793d..a5f605ed151 100644 --- a/code/modules/surgery/bodyparts/parts.dm +++ b/code/modules/surgery/bodyparts/parts.dm @@ -130,7 +130,7 @@ aux_layer = BODYPARTS_HIGH_LAYER body_damage_coeff = LIMB_BODY_DAMAGE_COEFFICIENT_DEFAULT can_be_disabled = TRUE - unarmed_attack_verb = "punch" /// The classic punch, wonderfully classic and completely random + unarmed_attack_verbs = list("punch") /// The classic punch, wonderfully classic and completely random grappled_attack_verb = "pummel" unarmed_damage_low = 5 unarmed_damage_high = 10 @@ -391,7 +391,7 @@ can_be_disabled = TRUE unarmed_attack_effect = ATTACK_EFFECT_KICK body_zone = BODY_ZONE_L_LEG - unarmed_attack_verb = "kick" // The lovely kick, typically only accessable by attacking a grouded foe. 1.5 times better than the punch. + unarmed_attack_verbs = list("kick") // The lovely kick, typically only accessable by attacking a grouded foe. 1.5 times better than the punch. unarmed_damage_low = 7 unarmed_damage_high = 15 unarmed_effectiveness = 15 diff --git a/code/modules/surgery/bodyparts/species_parts/ethereal_bodyparts.dm b/code/modules/surgery/bodyparts/species_parts/ethereal_bodyparts.dm index 3eeafa6f4e1..6607dbc5933 100644 --- a/code/modules/surgery/bodyparts/species_parts/ethereal_bodyparts.dm +++ b/code/modules/surgery/bodyparts/species_parts/ethereal_bodyparts.dm @@ -36,7 +36,7 @@ limb_id = SPECIES_ETHEREAL dmg_overlay_type = null attack_type = BURN //burn bish - unarmed_attack_verb = "burn" + unarmed_attack_verbs = list("burn", "singe") grappled_attack_verb = "scorch" unarmed_attack_sound = 'sound/weapons/etherealhit.ogg' unarmed_miss_sound = 'sound/weapons/etherealmiss.ogg' @@ -54,7 +54,7 @@ limb_id = SPECIES_ETHEREAL dmg_overlay_type = null attack_type = BURN // bish buzz - unarmed_attack_verb = "burn" + unarmed_attack_verbs = list("burn") grappled_attack_verb = "scorch" unarmed_attack_sound = 'sound/weapons/etherealhit.ogg' unarmed_miss_sound = 'sound/weapons/etherealmiss.ogg' diff --git a/code/modules/surgery/bodyparts/species_parts/lizard_bodyparts.dm b/code/modules/surgery/bodyparts/species_parts/lizard_bodyparts.dm index 16a4ac6ea2a..2389b98c20a 100644 --- a/code/modules/surgery/bodyparts/species_parts/lizard_bodyparts.dm +++ b/code/modules/surgery/bodyparts/species_parts/lizard_bodyparts.dm @@ -16,7 +16,7 @@ /obj/item/bodypart/arm/left/lizard icon_greyscale = 'icons/mob/human/species/lizard/bodyparts.dmi' limb_id = SPECIES_LIZARD - unarmed_attack_verb = "slash" + unarmed_attack_verbs = list("slash", "scratch", "claw") grappled_attack_verb = "lacerate" unarmed_attack_effect = ATTACK_EFFECT_CLAW unarmed_attack_sound = 'sound/weapons/slash.ogg' @@ -25,7 +25,7 @@ /obj/item/bodypart/arm/right/lizard icon_greyscale = 'icons/mob/human/species/lizard/bodyparts.dmi' limb_id = SPECIES_LIZARD - unarmed_attack_verb = "slash" + unarmed_attack_verbs = list("slash", "scratch", "claw") grappled_attack_verb = "lacerate" unarmed_attack_effect = ATTACK_EFFECT_CLAW unarmed_attack_sound = 'sound/weapons/slash.ogg' diff --git a/code/modules/surgery/bodyparts/species_parts/misc_bodyparts.dm b/code/modules/surgery/bodyparts/species_parts/misc_bodyparts.dm index 3a0b74ced34..74f1e4dda77 100644 --- a/code/modules/surgery/bodyparts/species_parts/misc_bodyparts.dm +++ b/code/modules/surgery/bodyparts/species_parts/misc_bodyparts.dm @@ -15,7 +15,7 @@ /obj/item/bodypart/arm/left/snail limb_id = SPECIES_SNAIL - unarmed_attack_verb = "slap" + unarmed_attack_verbs = list("slap") unarmed_attack_effect = ATTACK_EFFECT_DISARM unarmed_damage_low = 1 unarmed_damage_high = 2 //snails are soft and squishy @@ -24,7 +24,7 @@ /obj/item/bodypart/arm/right/snail limb_id = SPECIES_SNAIL - unarmed_attack_verb = "slap" + unarmed_attack_verbs = list("slap") unarmed_attack_effect = ATTACK_EFFECT_DISARM unarmed_damage_low = 1 unarmed_damage_high = 2 //snails are soft and squishy @@ -222,7 +222,7 @@ /obj/item/bodypart/arm/left/pod limb_id = SPECIES_PODPERSON - unarmed_attack_verb = "slash" + unarmed_attack_verbs = list("slash", "lash") grappled_attack_verb = "lacerate" unarmed_attack_effect = ATTACK_EFFECT_CLAW unarmed_attack_sound = 'sound/weapons/slice.ogg' @@ -231,7 +231,7 @@ /obj/item/bodypart/arm/right/pod limb_id = SPECIES_PODPERSON - unarmed_attack_verb = "slash" + unarmed_attack_verbs = list("slash", "lash") grappled_attack_verb = "lacerate" unarmed_attack_effect = ATTACK_EFFECT_CLAW unarmed_attack_sound = 'sound/weapons/slice.ogg' diff --git a/code/modules/surgery/bodyparts/species_parts/moth_bodyparts.dm b/code/modules/surgery/bodyparts/species_parts/moth_bodyparts.dm index 6acf6d399bc..66d7193e726 100644 --- a/code/modules/surgery/bodyparts/species_parts/moth_bodyparts.dm +++ b/code/modules/surgery/bodyparts/species_parts/moth_bodyparts.dm @@ -26,7 +26,7 @@ icon_static = 'icons/mob/human/species/moth/bodyparts.dmi' limb_id = SPECIES_MOTH should_draw_greyscale = FALSE - unarmed_attack_verb = "slash" + unarmed_attack_verbs = list("slash") grappled_attack_verb = "lacerate" unarmed_attack_effect = ATTACK_EFFECT_CLAW unarmed_attack_sound = 'sound/weapons/slash.ogg' @@ -38,7 +38,7 @@ icon_static = 'icons/mob/human/species/moth/bodyparts.dmi' limb_id = SPECIES_MOTH should_draw_greyscale = FALSE - unarmed_attack_verb = "slash" + unarmed_attack_verbs = list("slash") grappled_attack_verb = "lacerate" unarmed_attack_effect = ATTACK_EFFECT_CLAW unarmed_attack_sound = 'sound/weapons/slash.ogg' diff --git a/modular_nova/master_files/code/datums/traits/good.dm b/modular_nova/master_files/code/datums/traits/good.dm index 16a50b46888..d9cb17124ea 100644 --- a/modular_nova/master_files/code/datums/traits/good.dm +++ b/modular_nova/master_files/code/datums/traits/good.dm @@ -36,7 +36,7 @@ var/obj/item/bodypart/arm/left/left_arm = human_holder.get_bodypart(BODY_ZONE_L_ARM) if(left_arm) - left_arm.unarmed_attack_verb = "slash" + left_arm.unarmed_attack_verbs = list("slash") left_arm.unarmed_attack_effect = ATTACK_EFFECT_CLAW left_arm.unarmed_attack_sound = 'sound/weapons/slash.ogg' left_arm.unarmed_miss_sound = 'sound/weapons/slashmiss.ogg' @@ -44,7 +44,7 @@ var/obj/item/bodypart/arm/right/right_arm = human_holder.get_bodypart(BODY_ZONE_R_ARM) if(right_arm) - right_arm.unarmed_attack_verb = "slash" + right_arm.unarmed_attack_verbs = list("slash") right_arm.unarmed_attack_effect = ATTACK_EFFECT_CLAW right_arm.unarmed_attack_sound = 'sound/weapons/slash.ogg' right_arm.unarmed_miss_sound = 'sound/weapons/slashmiss.ogg' @@ -54,7 +54,7 @@ var/mob/living/carbon/human/human_holder = quirk_holder var/obj/item/bodypart/arm/left/left_arm = human_holder.get_bodypart(BODY_ZONE_L_ARM) if(left_arm) - left_arm.unarmed_attack_verb = initial(left_arm.unarmed_attack_verb) + left_arm.unarmed_attack_verbs = initial(left_arm.unarmed_attack_verbs) left_arm.unarmed_attack_effect = initial(left_arm.unarmed_attack_effect) left_arm.unarmed_attack_sound = initial(left_arm.unarmed_attack_sound) left_arm.unarmed_miss_sound = initial(left_arm.unarmed_miss_sound) @@ -62,7 +62,7 @@ var/obj/item/bodypart/arm/right/right_arm = human_holder.get_bodypart(BODY_ZONE_R_ARM) if(right_arm) - right_arm.unarmed_attack_verb = initial(right_arm.unarmed_attack_verb) + right_arm.unarmed_attack_verbs = initial(right_arm.unarmed_attack_verbs) right_arm.unarmed_attack_effect = initial(right_arm.unarmed_attack_effect) right_arm.unarmed_attack_sound = initial(right_arm.unarmed_attack_sound) right_arm.unarmed_miss_sound = initial(right_arm.unarmed_miss_sound) diff --git a/modular_nova/modules/bodyparts/code/_mutant_bodyparts.dm b/modular_nova/modules/bodyparts/code/_mutant_bodyparts.dm index 02a3248ef37..72af12346a5 100644 --- a/modular_nova/modules/bodyparts/code/_mutant_bodyparts.dm +++ b/modular_nova/modules/bodyparts/code/_mutant_bodyparts.dm @@ -34,7 +34,7 @@ /obj/item/bodypart/arm/left/mutant icon_greyscale = BODYPART_ICON_MAMMAL limb_id = SPECIES_MAMMAL - unarmed_attack_verb = "slash" + unarmed_attack_verbs = list("slash") unarmed_attack_effect = ATTACK_EFFECT_CLAW unarmed_attack_sound = 'sound/weapons/slash.ogg' unarmed_miss_sound = 'sound/weapons/slashmiss.ogg' @@ -43,7 +43,7 @@ /obj/item/bodypart/arm/right/mutant icon_greyscale = BODYPART_ICON_MAMMAL limb_id = SPECIES_MAMMAL - unarmed_attack_verb = "slash" + unarmed_attack_verbs = list("slash") unarmed_attack_effect = ATTACK_EFFECT_CLAW unarmed_attack_sound = 'sound/weapons/slash.ogg' unarmed_miss_sound = 'sound/weapons/slashmiss.ogg' diff --git a/modular_nova/modules/bodyparts/code/ghoul_bodyparts.dm b/modular_nova/modules/bodyparts/code/ghoul_bodyparts.dm index d58e6cd0c83..6e3e3957174 100644 --- a/modular_nova/modules/bodyparts/code/ghoul_bodyparts.dm +++ b/modular_nova/modules/bodyparts/code/ghoul_bodyparts.dm @@ -59,12 +59,12 @@ limb_id = SPECIES_GHOUL unarmed_damage_low = 1 //lowest possible punch damage. if this is set to 0, punches will always miss unarmed_damage_high = 5 //highest possible punch damage - unarmed_attack_verb = "punch" + unarmed_attack_verbs = list("punch") unarmed_attack_effect = ATTACK_EFFECT_PUNCH unarmed_attack_sound = 'sound/weapons/punch1.ogg' unarmed_miss_sound = 'sound/weapons/punchmiss.ogg' brute_modifier = GHOUL_BRUTE_MODIFIER - burn_modifier = GHOUL_BURN_MODIFIER + // burn_modifier = GHOUL_BURN_MODIFIER /obj/item/bodypart/arm/right/mutant/ghoul @@ -72,7 +72,7 @@ limb_id = SPECIES_GHOUL unarmed_damage_low = 1 //lowest possible punch damage. if this is set to 0, punches will always miss unarmed_damage_high = 5 //highest possible punch damage - unarmed_attack_verb = "punch" + unarmed_attack_verbs = list("punch") unarmed_attack_effect = ATTACK_EFFECT_PUNCH unarmed_attack_sound = 'sound/weapons/punch1.ogg' unarmed_miss_sound = 'sound/weapons/punchmiss.ogg'