From 9ac7baa55d3a6b8f9613c5b055c78d08652eab7b Mon Sep 17 00:00:00 2001 From: jc_gargma Date: Sat, 27 Jun 2020 02:29:57 -0700 Subject: Reduce duplication of item references No longer require editing of 45.json --- json/items/gun/40.json | 2 +- json/items/gun/45.json | 13 +++++-------- json/items/gun/46.json | 36 ++--------------------------------- json/items/gun/9mm.json | 22 +++------------------- json/items/magazine/40.json | 14 +++----------- json/items/magazine/45.json | 45 +++++++++++++++++--------------------------- json/items/magazine/9mm.json | 42 ++++++----------------------------------- 7 files changed, 37 insertions(+), 137 deletions(-) (limited to 'json/items') diff --git a/json/items/gun/40.json b/json/items/gun/40.json index a43fda2..ac4bd96 100644 --- a/json/items/gun/40.json +++ b/json/items/gun/40.json @@ -3,7 +3,7 @@ "id": "usp_40", "copy-from": "usp_9mm", "type": "GUN", - "name": { "str": "H&K USP .40" }, + "name": { "str": "H&K USP .40", "str_pl": "H&K USP .40" }, "weight": "748 g", "ammo": "40", "magazines": [ [ "40", [ "usp40mag" ] ] ] diff --git a/json/items/gun/45.json b/json/items/gun/45.json index 10e8ad9..5963a8f 100644 --- a/json/items/gun/45.json +++ b/json/items/gun/45.json @@ -1,12 +1,9 @@ [ - { + { "id": "usp_45", - "copy-from": "usp_9mm", + "copy-from": "usp_45", "type": "GUN", - "name": { "str": "H&K USP .45" }, - "weight": "789 g", - "ammo": "45", - "built_in_mods": [ "match_trigger" ], - "magazines": [ [ "45", [ "usp45mag" ] ] ] -} + "name": { "str": "H&K USP .45", "str_pl": "H&K USP .45" }, + "weight": "789 g" + } ] diff --git a/json/items/gun/46.json b/json/items/gun/46.json index 1f84abd..6b9b51b 100644 --- a/json/items/gun/46.json +++ b/json/items/gun/46.json @@ -36,41 +36,9 @@ }, { "id": "hk_mp7", - "looks_like": "hk_mp5", + "copy-from": "hk_mp7", "type": "GUN", - "reload_noise_volume": 10, "name": { "str": "H&K MP7A2" }, - "description": "Designed as a personal defense weapon, the MP7 fires the high-powered 4.6x30mm round while being lightweight, compact in size, and practically recoil free.", - "weight": "1800 g", - "volume": "1000 ml", - "price": 175000, - "to_hit": -2, - "bashing": 7, - "material": [ "steel", "plastic" ], - "symbol": "(", - "color": "dark_gray", - "ammo": "46", - "skill": "smg", - "dispersion": 260, - "durability": 8, - "min_cycle_recoil": 81, - "modes": [ [ "DEFAULT", "semi-auto", 1 ], [ "AUTO", "auto", 5 ] ], - "built_in_mods": [ "wire_stock" ], - "valid_mod_locations": [ - [ "accessories", 3 ], - [ "barrel", 1 ], - [ "brass catcher", 1 ], - [ "grip", 1 ], - [ "mechanism", 4 ], - [ "muzzle", 1 ], - [ "rail", 1 ], - [ "sights", 1 ], - [ "sling", 1 ], - [ "stock", 1 ], - [ "underbarrel", 1 ] - ], - "faults": [ "fault_gun_blackpowder", "fault_gun_dirt", "fault_gun_chamber_spent" ], - "magazine_well": 1, - "magazines": [ [ "46", [ "hk46mag", "hk46bigmag" ] ] ] + "volume": "1000 ml" } ] diff --git a/json/items/gun/9mm.json b/json/items/gun/9mm.json index e3171f0..56a7f9a 100644 --- a/json/items/gun/9mm.json +++ b/json/items/gun/9mm.json @@ -1,25 +1,9 @@ [ { "id": "usp_9mm", - "copy-from": "pistol_base", - "looks_like": "glock_17", + "copy-from": "usp_9mm", "type": "GUN", "name": { "str": "H&K USP 9mm", "str_pl": "H&K USP 9mm" }, - "description": "A popular pistol, widely used among law enforcement. Extensively tested for durability, it has been found to stay accurate even after being subjected to extreme abuse.", - "weight": "748 g", - "volume": "500 ml", - "price": 68000, - "to_hit": -2, - "bashing": 8, - "material": [ "steel", "plastic" ], - "symbol": "(", - "color": "dark_gray", - "ammo": "9mm", - "dispersion": 400, - "durability": 9, - "blackpowder_tolerance": 48, - "min_cycle_recoil": 450, - "magazine_well": 1, - "magazines": [ [ "9mm", [ "usp9mag" ] ] ] -} + "weight": "748 g" + } ] diff --git a/json/items/magazine/40.json b/json/items/magazine/40.json index cd6fa13..f4736a3 100644 --- a/json/items/magazine/40.json +++ b/json/items/magazine/40.json @@ -1,19 +1,11 @@ [ { "id": "usp40mag", - "looks_like": "glock17_17", + "copy-from": "usp9mag", "type": "MAGAZINE", "name": { "str": "H&K USP .40 magazine" }, "description": "A standard capacity magazine for use with the H&K USP .40 handgun.", - "weight": "60 g", - "volume": "250 ml", - "price": 5900, - "material": "plastic", - "symbol": "#", - "color": "light_gray", "ammo_type": "40", - "capacity": 13, - "reliability": 10, - "flags": [ "MAG_COMPACT" ] -} + "capacity": 13 + } ] diff --git a/json/items/magazine/45.json b/json/items/magazine/45.json index 63695b3..3988982 100644 --- a/json/items/magazine/45.json +++ b/json/items/magazine/45.json @@ -1,36 +1,25 @@ [ - { - "id": "usp45mag", - "looks_like": "glock17_17", - "type": "MAGAZINE", - "name": { "str": "H&K USP .45 magazine" }, - "description": "A standard capacity magazine for use with the H&K USP .45 handgun.", - "weight": "60 g", - "volume": "250 ml", - "price": 5900, - "material": "plastic", - "symbol": "#", - "color": "light_gray", - "ammo_type": "45", - "capacity": 12, - "reliability": 10, - "flags": [ "MAG_COMPACT" ] -}, { "id": "ump45mag", - "looks_like": "mp5mag", + "looks_like": "ump45mag", "type": "MAGAZINE", "name": { "str": "H&K UMP45 magazine" }, "description": "A standard 25-round box magazine for use with the H&K UMP45 SMG.", - "weight": "200 g", - "volume": "500 ml", - "price": 4950, - "material": "steel", "symbol": "#", - "color": "light_gray", - "ammo_type": "45", - "capacity": 25, - "reliability": 9, - "flags": [ "MAG_COMPACT" ] -} + "ammo_type": "45" + }, + { + "id": "ump45_makeshiftmag", + "copy-from": "ump45_makeshiftmag", + "type": "MAGAZINE", + "name": { "str": "H&K UMP45 makeshift magazine" }, + "description": "An improvised 20-round straight single-stack box magazine consisting of little more than a bent sheet of steel held together by duct tape and hope, for use with the H&K UMP45 SMG." + }, + { + "id": "usp45mag", + "copy-from": "usp45mag", + "type": "MAGAZINE", + "name": { "str": "H&K USP .45 magazine" }, + "description": "A standard capacity magazine for use with the H&K USP .45 handgun." + } ] diff --git a/json/items/magazine/9mm.json b/json/items/magazine/9mm.json index 14e46c5..89a401c 100644 --- a/json/items/magazine/9mm.json +++ b/json/items/magazine/9mm.json @@ -1,54 +1,24 @@ [ { "id": "usp9mag", - "looks_like": "glock17_17", + "copy-from": "usp9mag", "type": "MAGAZINE", "name": { "str": "H&K USP 9mm magazine" }, - "description": "A factory specification 15-round box magazine for use with the dependable H&K USP 9x19mm pistol.", - "weight": "75 g", - "volume": "250 ml", - "price": 3850, - "material": "steel", - "symbol": "#", - "color": "light_gray", - "ammo_type": "9mm", - "capacity": 15, - "reliability": 10, - "flags": [ "MAG_COMPACT" ] + "ammo_type": "9mm" }, { "id": "mp5mag", + "copy-from": "usp9mag", "//": "Tileset whitelist for SMG magazines", "type": "MAGAZINE", "name": { "str": "H&K MP5 magazine" }, - "description": "A standard capacity curved magazine for use with the H&K MP5 SMG.", - "weight": "210 g", - "volume": "500 ml", - "price": 4100, - "material": "steel", - "symbol": "#", - "color": "light_gray", - "ammo_type": "9mm", - "capacity": 30, - "reliability": 9, - "flags": [ "MAG_COMPACT" ] + "ammo_type": "9mm" }, { "id": "mp5bigmag", - "looks_like": "glock17_17", + "copy-from": "usp9mag", "type": "MAGAZINE", "name": { "str": "H&K MP5 extended magazine" }, - "description": "A drum magazine for use with the H&K MP5 SMG. Much greater capacity but less reliable the factory specification magazine.", - "weight": "350 g", - "volume": "750 ml", - "price": 6920, - "material": "steel", - "symbol": "#", - "color": "light_gray", - "ammo_type": "9mm", - "capacity": 50, - "reliability": 8, - "reload_time": 160, - "flags": [ "MAG_BULKY" ] + "ammo_type": "9mm" } ] -- cgit v1.2.1