From f45054f282ddcc6fb3350e5cf7a19665f60f00e4 Mon Sep 17 00:00:00 2001 From: FalloutFalcon Date: Sun, 3 May 2026 23:30:22 -0500 Subject: [PATCH 1/4] melee rolls --- code/_onclick/item_attack.dm | 17 +++++++++++++++-- .../master_files/code/game/objects/items.dm | 6 ++++++ .../powers/code/discipline/protean/claws.dm | 7 +------ 3 files changed, 22 insertions(+), 8 deletions(-) diff --git a/code/_onclick/item_attack.dm b/code/_onclick/item_attack.dm index 618868072488..39358377e07e 100644 --- a/code/_onclick/item_attack.dm +++ b/code/_onclick/item_attack.dm @@ -348,8 +348,21 @@ if(mob_biotypes & (MOB_ROBOTIC|MOB_MINERAL|MOB_SKELETAL)) // this should probably check hit bodypart for humanoids final_force *= attacking_item.get_demolition_modifier(src) - // DARKPACK EDIT ADD START - (Makes Melee do Something) - final_force += final_force * (user.st_get_stat(STAT_MELEE) * 0.1) + // DARKPACK EDIT ADD START - STORYTELLER_ROLLS/STORYTELLER_STATS + var/datum/storyteller_roll/attack/attack_roll = new() + attack_roll.applicable_stats = list(attacking_item.st_attack_ability, attacking_item.st_attack_attribute) + attack_roll.difficulty = attacking_item.attack_difficulty + var/attack_roll_result = attack_roll.st_roll(user, src, bonus_dice) + + if(attack_roll_result == ROLL_SUCCESS) + // This is pretty evil, but we are gonna convert all the tg force into the +# that melee weapons have listed. + // This means we can do stuff like set force of a baseball bat to 2 TTRPG_DAM and it just works. + var/bonus_dice = round(final_force / (1 TTRPG_DAMAGE)) + var/datum/storyteller_roll/damage/damage_roll = new() + damage_roll.applicable_stats = list(attacking_item.st_damage_stat) + var/damage_roll_result = damage_roll.st_roll(user, src, bonus_dice) + + final_force = damage_roll_result TTRPG_DAMAGE // DARKPACK EDIT ADD END var/wounding = attacking_item.wound_bonus diff --git a/modular_darkpack/master_files/code/game/objects/items.dm b/modular_darkpack/master_files/code/game/objects/items.dm index 0ba0a0b0bbaa..381615140712 100644 --- a/modular_darkpack/master_files/code/game/objects/items.dm +++ b/modular_darkpack/master_files/code/game/objects/items.dm @@ -2,3 +2,9 @@ var/onflooricon var/onflooricon_state var/masquerade_violating + + // STORYTELLR_STATS + var/datum/st_stat/st_attack_ability = STAT_DEXTERITY + var/datum/st_stat/st_attack_attribute = STAT_MELEE + var/attack_difficulty = 6 + var/datum/st_stat/st_damage_stat = STAT_STRENGTH diff --git a/modular_darkpack/modules/powers/code/discipline/protean/claws.dm b/modular_darkpack/modules/powers/code/discipline/protean/claws.dm index fb4799c83acf..9a828d11a842 100644 --- a/modular_darkpack/modules/powers/code/discipline/protean/claws.dm +++ b/modular_darkpack/modules/powers/code/discipline/protean/claws.dm @@ -12,14 +12,9 @@ item_flags = DROPDEL masquerade_violating = TRUE obj_flags = NONE + st_attack_attribute = STAT_BRAWL /obj/item/gangrel_claws/Initialize(mapload) . = ..() ADD_TRAIT(src, TRAIT_NODROP, INNATE_TRAIT) -/obj/item/gangrel_claws/pre_attack(atom/target, mob/living/user, list/modifiers, list/attack_modifiers) - . = ..() - // Based on V20 - if(isliving(user)) - var/mob/living/living_user = user - force = (living_user.st_get_stat(STAT_STRENGTH) + 1) TTRPG_DAMAGE From 98e73140f6b092c45113fccd62082d4d5ec13396 Mon Sep 17 00:00:00 2001 From: FalloutFalcon Date: Mon, 4 May 2026 00:20:22 -0500 Subject: [PATCH 2/4] yeagh --- code/_onclick/item_attack.dm | 22 ++++++++++++------- .../modules/weapons/code/melee.dm | 8 ++++++- 2 files changed, 21 insertions(+), 9 deletions(-) diff --git a/code/_onclick/item_attack.dm b/code/_onclick/item_attack.dm index 39358377e07e..29c47f35548c 100644 --- a/code/_onclick/item_attack.dm +++ b/code/_onclick/item_attack.dm @@ -302,12 +302,15 @@ return ATTACK_FAILED var/final_force = CALCULATE_FORCE(attacking_item, attack_modifiers) -// DARKPACK EDIT ADD START - if(isliving(user)) - var/mob/living/living_user = user - var/stat_multiplier = living_user.st_get_stat(STAT_MELEE) * 0.4 - final_force *= stat_multiplier -// DARKPACK EDIT ADD END + // DARKPACK EDIT ADD START - STORYTELLER_ROLLS/STORYTELLER_STATS + // This is pretty evil, but we are gonna convert all the tg force into the +# that melee weapons have listed. + // This means we can do stuff like set force of a baseball bat to 2 TTRPG_DAM and it just works. + var/bonus_dice = round(final_force / (1 TTRPG_DAMAGE)) + var/datum/storyteller_roll/damage/damage_roll = new() + damage_roll.applicable_stats = list(attacking_item.st_damage_stat) + var/damage_roll_result = damage_roll.st_roll(user, src, bonus_dice) + final_force = damage_roll_result + // DARKPACK EDIT ADD END if(final_force <= 0) return 0 @@ -352,8 +355,9 @@ var/datum/storyteller_roll/attack/attack_roll = new() attack_roll.applicable_stats = list(attacking_item.st_attack_ability, attacking_item.st_attack_attribute) attack_roll.difficulty = attacking_item.attack_difficulty - var/attack_roll_result = attack_roll.st_roll(user, src, bonus_dice) + var/attack_roll_result = attack_roll.st_roll(user, src) + // What i want to do is acctually have it return if not success. But that creates bad visual feedback as all the FX still play. just give them them SOME damage.. if(attack_roll_result == ROLL_SUCCESS) // This is pretty evil, but we are gonna convert all the tg force into the +# that melee weapons have listed. // This means we can do stuff like set force of a baseball bat to 2 TTRPG_DAM and it just works. @@ -362,7 +366,9 @@ damage_roll.applicable_stats = list(attacking_item.st_damage_stat) var/damage_roll_result = damage_roll.st_roll(user, src, bonus_dice) - final_force = damage_roll_result TTRPG_DAMAGE + final_force = max(damage_roll_result TTRPG_DAMAGE, 1 TTRPG_DAMAGE) + else + final_force = 1 TTRPG_DAMAGE // "SOME damage" in question // DARKPACK EDIT ADD END var/wounding = attacking_item.wound_bonus diff --git a/modular_darkpack/modules/weapons/code/melee.dm b/modular_darkpack/modules/weapons/code/melee.dm index 0e21ffffadc3..a97e40664321 100644 --- a/modular_darkpack/modules/weapons/code/melee.dm +++ b/modular_darkpack/modules/weapons/code/melee.dm @@ -23,6 +23,8 @@ slot_flags = ITEM_SLOT_BACK | ITEM_SLOT_BELT // Should really be suit storage pixel_w = -8 custom_price = 1800 + force = 3 LETHAL_TTRPG_DAMAGE + attack_difficulty = 7 /obj/item/katana/vamp name = "katana" @@ -34,6 +36,7 @@ ONFLOOR_ICON_HELPER('modular_darkpack/modules/weapons/icons/weapons_onfloor.dmi') pixel_w = -8 custom_price = 1300 + force = 2 LETHAL_TTRPG_DAMAGE /obj/item/katana/vamp/Initialize(mapload) . = ..() @@ -89,7 +92,7 @@ worn_icon = 'modular_darkpack/modules/weapons/icons/worn_melee.dmi' ONFLOOR_ICON_HELPER('modular_darkpack/modules/weapons/icons/weapons_onfloor.dmi') icon_state = "rapier" - + force = 2 LETHAL_TTRPG_DAMAGE /obj/item/melee/sabre/rapier/Initialize(mapload) . = ..() @@ -144,6 +147,7 @@ ONFLOOR_ICON_HELPER('modular_darkpack/modules/weapons/icons/weapons_onfloor.dmi') icon_state = "longsword" inhand_icon_state = "longsword" + force = 2 LETHAL_TTRPG_DAMAGE /obj/item/claymore/longsword/Initialize(mapload) @@ -181,6 +185,8 @@ inhand_icon_state = "baseball" slot_flags = ITEM_SLOT_BACK | ITEM_SLOT_BELT // Should really be suit storage custom_price = 50 + force = 2 TTRPG_DAMAGE + attack_difficulty = 5 /obj/item/melee/baseball_bat/vamp/Initialize(mapload) . = ..() From 786a290280be0a96a0aa1b5a605332d280e43f6e Mon Sep 17 00:00:00 2001 From: FalloutFalcon Date: Mon, 18 May 2026 10:11:09 -0500 Subject: [PATCH 3/4] gonna seperate into a diff pr i think --- modular_darkpack/modules/weapons/code/melee.dm | 7 ------- 1 file changed, 7 deletions(-) diff --git a/modular_darkpack/modules/weapons/code/melee.dm b/modular_darkpack/modules/weapons/code/melee.dm index a97e40664321..54bc7c392904 100644 --- a/modular_darkpack/modules/weapons/code/melee.dm +++ b/modular_darkpack/modules/weapons/code/melee.dm @@ -23,8 +23,6 @@ slot_flags = ITEM_SLOT_BACK | ITEM_SLOT_BELT // Should really be suit storage pixel_w = -8 custom_price = 1800 - force = 3 LETHAL_TTRPG_DAMAGE - attack_difficulty = 7 /obj/item/katana/vamp name = "katana" @@ -36,7 +34,6 @@ ONFLOOR_ICON_HELPER('modular_darkpack/modules/weapons/icons/weapons_onfloor.dmi') pixel_w = -8 custom_price = 1300 - force = 2 LETHAL_TTRPG_DAMAGE /obj/item/katana/vamp/Initialize(mapload) . = ..() @@ -92,7 +89,6 @@ worn_icon = 'modular_darkpack/modules/weapons/icons/worn_melee.dmi' ONFLOOR_ICON_HELPER('modular_darkpack/modules/weapons/icons/weapons_onfloor.dmi') icon_state = "rapier" - force = 2 LETHAL_TTRPG_DAMAGE /obj/item/melee/sabre/rapier/Initialize(mapload) . = ..() @@ -147,7 +143,6 @@ ONFLOOR_ICON_HELPER('modular_darkpack/modules/weapons/icons/weapons_onfloor.dmi') icon_state = "longsword" inhand_icon_state = "longsword" - force = 2 LETHAL_TTRPG_DAMAGE /obj/item/claymore/longsword/Initialize(mapload) @@ -185,8 +180,6 @@ inhand_icon_state = "baseball" slot_flags = ITEM_SLOT_BACK | ITEM_SLOT_BELT // Should really be suit storage custom_price = 50 - force = 2 TTRPG_DAMAGE - attack_difficulty = 5 /obj/item/melee/baseball_bat/vamp/Initialize(mapload) . = ..() From c256d477f597d825ad705b957ced0be19a3c549b Mon Sep 17 00:00:00 2001 From: FalloutFalcon Date: Thu, 21 May 2026 06:08:39 -0500 Subject: [PATCH 4/4] fix --- code/_onclick/item_attack.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/_onclick/item_attack.dm b/code/_onclick/item_attack.dm index 29c47f35548c..3062e78b2caf 100644 --- a/code/_onclick/item_attack.dm +++ b/code/_onclick/item_attack.dm @@ -309,7 +309,7 @@ var/datum/storyteller_roll/damage/damage_roll = new() damage_roll.applicable_stats = list(attacking_item.st_damage_stat) var/damage_roll_result = damage_roll.st_roll(user, src, bonus_dice) - final_force = damage_roll_result + final_force = damage_roll_result TTRPG_DAMAGE // DARKPACK EDIT ADD END if(final_force <= 0) return 0