Skip to content

Commit

Permalink
feat(balance): shrapnel deals ballistic damage
Browse files Browse the repository at this point in the history
  • Loading branch information
chaosvolt committed Jun 5, 2024
1 parent 4286fd9 commit 39e9048
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 26 deletions.
8 changes: 4 additions & 4 deletions data/json/ammo_effects.json
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down Expand Up @@ -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",
Expand Down
2 changes: 1 addition & 1 deletion data/json/items/resources/misc.json
Original file line number Diff line number Diff line change
Expand Up @@ -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
},
Expand Down
38 changes: 19 additions & 19 deletions data/json/items/tool/explosives.json
Original file line number Diff line number Diff line change
Expand Up @@ -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!",
Expand All @@ -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" ]
},
Expand Down Expand Up @@ -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",
Expand Down Expand Up @@ -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",
Expand All @@ -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" ]
Expand Down Expand Up @@ -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" ]
Expand Down Expand Up @@ -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",
Expand Down Expand Up @@ -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" ]
Expand Down Expand Up @@ -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",
Expand Down Expand Up @@ -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",
Expand All @@ -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" ]
Expand Down Expand Up @@ -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",
Expand Down Expand Up @@ -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",
Expand Down Expand Up @@ -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",
Expand All @@ -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" ]
Expand All @@ -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",
Expand Down Expand Up @@ -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",
Expand All @@ -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" ]
Expand Down
2 changes: 1 addition & 1 deletion src/explosion.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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;
}
Expand Down
2 changes: 1 addition & 1 deletion src/trapfunc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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;
}
Expand Down

0 comments on commit 39e9048

Please sign in to comment.