From 39e9048849427d0b31be543c7986e7b4ebeccf3e Mon Sep 17 00:00:00 2001 From: Chaosvolt Date: Wed, 5 Jun 2024 03:23:05 -0500 Subject: [PATCH] feat(balance): shrapnel deals ballistic damage --- data/json/ammo_effects.json | 8 +++--- data/json/items/resources/misc.json | 2 +- data/json/items/tool/explosives.json | 38 ++++++++++++++-------------- src/explosion.cpp | 2 +- src/trapfunc.cpp | 2 +- 5 files changed, 26 insertions(+), 26 deletions(-) diff --git a/data/json/ammo_effects.json b/data/json/ammo_effects.json index 8ec8013fbb44..81e653d8819a 100644 --- a/data/json/ammo_effects.json +++ b/data/json/ammo_effects.json @@ -18,7 +18,7 @@ "damage": 0, "radius": 0, "fire": false, - "fragment": { "impact": { "damage_type": "cut", "amount": 0, "armor_multiplier": 3 }, "range": 0 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 0, "armor_multiplier": 3 }, "range": 0 } }, "do_flashbang": false, "do_emp_blast": false @@ -140,17 +140,17 @@ { "id": "FRAG_BIG", "type": "ammo_effect", - "explosion": { "fragment": { "impact": { "damage_type": "cut", "amount": 100, "armor_multiplier": 3 }, "range": 7 } } + "explosion": { "fragment": { "impact": { "damage_type": "bullet", "amount": 100, "armor_multiplier": 3 }, "range": 7 } } }, { "id": "FRAG", "type": "ammo_effect", - "explosion": { "fragment": { "impact": { "damage_type": "cut", "amount": 50, "armor_multiplier": 3 }, "range": 5 } } + "explosion": { "fragment": { "impact": { "damage_type": "bullet", "amount": 50, "armor_multiplier": 3 }, "range": 5 } } }, { "id": "FRAG_SMALL", "type": "ammo_effect", - "explosion": { "fragment": { "impact": { "damage_type": "cut", "amount": 30, "armor_multiplier": 3 }, "range": 3 } } + "explosion": { "fragment": { "impact": { "damage_type": "bullet", "amount": 30, "armor_multiplier": 3 }, "range": 3 } } }, { "id": "MININUKE_MOD", diff --git a/data/json/items/resources/misc.json b/data/json/items/resources/misc.json index e60216884469..ce3a6a1263f7 100644 --- a/data/json/items/resources/misc.json +++ b/data/json/items/resources/misc.json @@ -199,7 +199,7 @@ "explosion": { "damage": 50, "radius": 3, - "fragment": { "impact": { "damage_type": "cut", "amount": 50, "armor_multiplier": 3 }, "range": 5 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 50, "armor_multiplier": 3 }, "range": 5 } }, "explode_in_fire": true }, diff --git a/data/json/items/tool/explosives.json b/data/json/items/tool/explosives.json index dd0921c79c0a..35ad899c5d9f 100644 --- a/data/json/items/tool/explosives.json +++ b/data/json/items/tool/explosives.json @@ -48,7 +48,7 @@ "symbol": "*", "color": "red", "explode_in_fire": true, - "explosion": { "fragment": { "impact": { "damage_type": "cut", "amount": 50, "armor_multiplier": 3 }, "range": 5 } }, + "explosion": { "fragment": { "impact": { "damage_type": "bullet", "amount": 50, "armor_multiplier": 3 }, "range": 5 } }, "use_action": { "target": "can_bomb_act", "msg": "You light the fuse on the can bomb. Throw it before it blows in your face!", @@ -71,13 +71,13 @@ "max_charges": 5, "turns_per_charge": 1, "explode_in_fire": true, - "explosion": { "fragment": { "impact": { "damage_type": "cut", "amount": 50, "armor_multiplier": 3 }, "range": 5 } }, + "explosion": { "fragment": { "impact": { "damage_type": "bullet", "amount": 50, "armor_multiplier": 3 }, "range": 5 } }, "use_action": { "type": "explosion", "no_deactivate_msg": "You've already lit the fuse - what are you waiting for?", "sound_volume": 0, "sound_msg": "ssss...", - "explosion": { "fragment": { "impact": { "damage_type": "cut", "amount": 50, "armor_multiplier": 3 }, "range": 5 } } + "explosion": { "fragment": { "impact": { "damage_type": "bullet", "amount": 50, "armor_multiplier": 3 }, "range": 5 } } }, "flags": [ "BOMB", "TRADER_AVOID", "NO_REPAIR" ] }, @@ -198,7 +198,7 @@ "explosion": { "damage": 70, "radius": 6, - "fragment": { "impact": { "damage_type": "cut", "amount": 100, "armor_multiplier": 3 }, "range": 10 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 100, "armor_multiplier": 3 }, "range": 10 } }, "use_action": { "target": "dynamite_bomb_act", @@ -232,7 +232,7 @@ "explosion": { "damage": 70, "radius": 6, - "fragment": { "impact": { "damage_type": "cut", "amount": 100, "armor_multiplier": 3 }, "range": 10 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 100, "armor_multiplier": 3 }, "range": 10 } }, "use_action": { "type": "explosion", @@ -242,7 +242,7 @@ "explosion": { "damage": 70, "radius": 6, - "fragment": { "impact": { "damage_type": "cut", "amount": 100, "armor_multiplier": 3 }, "range": 10 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 100, "armor_multiplier": 3 }, "range": 10 } } }, "flags": [ "TRADER_AVOID", "BOMB" ] @@ -641,7 +641,7 @@ "explosion": { "damage": 40, "radius": 3, - "fragment": { "impact": { "damage_type": "cut", "amount": 80, "armor_multiplier": 3 }, "range": 6 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 80, "armor_multiplier": 3 }, "range": 6 } } }, "flags": [ "BOMB", "TRADER_AVOID" ] @@ -873,7 +873,7 @@ "explosion": { "damage": 40, "radius": 3, - "fragment": { "impact": { "damage_type": "cut", "amount": 40, "armor_multiplier": 3 }, "range": 6 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 40, "armor_multiplier": 3 }, "range": 6 } }, "use_action": { "target": "improvised_grenade_act", @@ -904,7 +904,7 @@ "explosion": { "damage": 40, "radius": 3, - "fragment": { "impact": { "damage_type": "cut", "amount": 40, "armor_multiplier": 3 }, "range": 6 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 40, "armor_multiplier": 3 }, "range": 6 } } }, "flags": [ "BOMB", "TRADER_AVOID" ] @@ -1033,7 +1033,7 @@ "explosion": { "damage": 20, "radius": 4, - "fragment": { "impact": { "damage_type": "cut", "amount": 70, "armor_multiplier": 3 }, "range": 8 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 70, "armor_multiplier": 3 }, "range": 8 } }, "use_action": { "target": "improvised_pipebomb_act", @@ -1068,7 +1068,7 @@ "explosion": { "damage": 20, "radius": 4, - "fragment": { "impact": { "damage_type": "cut", "amount": 70, "armor_multiplier": 3 }, "range": 8 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 70, "armor_multiplier": 3 }, "range": 8 } }, "use_action": { "type": "explosion", @@ -1078,7 +1078,7 @@ "explosion": { "damage": 20, "radius": 4, - "fragment": { "impact": { "damage_type": "cut", "amount": 70, "armor_multiplier": 3 }, "range": 8 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 70, "armor_multiplier": 3 }, "range": 8 } } }, "flags": [ "BOMB", "TRADER_AVOID", "DANGEROUS" ] @@ -1214,7 +1214,7 @@ "explosion": { "damage": 250, "radius": 12, - "fragment": { "impact": { "damage_type": "cut", "amount": 100, "armor_multiplier": 3 }, "range": 20 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 100, "armor_multiplier": 3 }, "range": 20 } }, "use_action": { "type": "explosion", @@ -1247,7 +1247,7 @@ "explosion": { "damage": 50, "radius": 6, - "fragment": { "impact": { "damage_type": "cut", "amount": 150, "armor_multiplier": 3 }, "range": 20 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 150, "armor_multiplier": 3 }, "range": 20 } }, "use_action": { "target": "tool_small_improvised_fragmentation_device_act", @@ -1280,7 +1280,7 @@ "explosion": { "damage": 50, "radius": 6, - "fragment": { "impact": { "damage_type": "cut", "amount": 150, "armor_multiplier": 3 }, "range": 20 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 150, "armor_multiplier": 3 }, "range": 20 } }, "use_action": { "type": "explosion", @@ -1290,7 +1290,7 @@ "explosion": { "damage": 50, "radius": 6, - "fragment": { "impact": { "damage_type": "cut", "amount": 150, "armor_multiplier": 3 }, "range": 20 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 150, "armor_multiplier": 3 }, "range": 20 } } }, "flags": [ "BOMB", "TRADER_AVOID" ] @@ -1315,7 +1315,7 @@ "explosion": { "damage": 200, "radius": 15, - "fragment": { "impact": { "damage_type": "cut", "amount": 80, "armor_multiplier": 3 }, "range": 20 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 80, "armor_multiplier": 3 }, "range": 20 } }, "use_action": { "target": "tool_improvised_barrel_bomb_act", @@ -1351,7 +1351,7 @@ "explosion": { "damage": 200, "radius": 15, - "fragment": { "impact": { "damage_type": "cut", "amount": 80, "armor_multiplier": 3 }, "range": 20 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 80, "armor_multiplier": 3 }, "range": 20 } }, "use_action": { "type": "explosion", @@ -1361,7 +1361,7 @@ "explosion": { "damage": 200, "radius": 15, - "fragment": { "impact": { "damage_type": "cut", "amount": 80, "armor_multiplier": 3 }, "range": 20 } + "fragment": { "impact": { "damage_type": "bullet", "amount": 80, "armor_multiplier": 3 }, "range": 20 } } }, "flags": [ "BOMB", "TRADER_AVOID" ] diff --git a/src/explosion.cpp b/src/explosion.cpp index 79c803cd78b9..c9d8cc4b67af 100644 --- a/src/explosion.cpp +++ b/src/explosion.cpp @@ -1876,7 +1876,7 @@ projectile shrapnel_from_legacy( int power, float blast_radius ) projectile proj; proj.speed = 1000; proj.range = range; - proj.impact.add_damage( DT_CUT, damage, 0.0f, 3.0f ); + proj.impact.add_damage( DT_BULLET, damage, 0.0f, 3.0f ); return proj; } diff --git a/src/trapfunc.cpp b/src/trapfunc.cpp index 6a3b47d6838d..d9679336b26f 100644 --- a/src/trapfunc.cpp +++ b/src/trapfunc.cpp @@ -590,7 +590,7 @@ static explosion_data get_basic_explosion_data() projectile fragment; fragment.range = 6; fragment.speed = 1000; - fragment.impact.add_damage( DT_CUT, 80, 0, 3.0F ); + fragment.impact.add_damage( DT_BULLET, 80, 0, 3.0F ); data.fragment = fragment; return data; }