diff --git a/data/json/item_groups.json b/data/json/item_groups.json index 9dd009d9df60e..2b50b729ffb07 100644 --- a/data/json/item_groups.json +++ b/data/json/item_groups.json @@ -185,6 +185,8 @@ { "type": "item_group", "id": "livingroom", + "ammo": 50, + "magazine": 100, "items": [ [ "rootbeer", 65 ], [ "mag_computer", 35 ], @@ -395,6 +397,8 @@ { "type": "item_group", "id": "kitchen", + "ammo": 75, + "magazine": 100, "items": [ [ "aluminum_foil", 25 ], [ "chips", 65 ], @@ -809,6 +813,8 @@ { "type": "item_group", "id": "bedroom", + "ammo": 50, + "magazine": 100, "items": [ [ "inhaler", 14 ], [ "eyedrops", 25 ], @@ -878,7 +884,7 @@ [ "banjo", 5 ], [ "ukulele", 15 ], [ "gobag", 5 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "bb", 8 ], [ "bbgun", 10 ], [ "fan", 10 ], @@ -1023,6 +1029,8 @@ { "type": "item_group", "id": "dresser", + "ammo": 50, + "magazine": 100, "items": [ [ "jeans", 90 ], [ "pants_checkered", 5 ], @@ -1514,7 +1522,7 @@ [ "ecig", 10 ], [ "advanced_ecig", 8 ], [ "nicotine_liquid", 8 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "l_enforcer_45", 4 ], [ "l_sp_45", 3 ], [ "l_mp_45", 2 ], @@ -1910,12 +1918,14 @@ }, { "type": "item_group", + "ammo": 25, + "magazine": 100, "id": "consumer_electronics", "items": [ [ "amplifier", 8 ], [ "mag_electronics", 15 ], [ "antenna", 18 ], - [ "battery", 50 ], + { "group": "ammo_any_batteries_full", "prob": 50 }, [ "soldering_iron", 70 ], [ "solder_wire", 70 ], [ "solar_cell", 5 ], @@ -2056,6 +2066,8 @@ { "type": "item_group", "id": "camping", + "ammo": 75, + "magazine": 100, "items": [ [ "rope_30", 35 ], [ "hatchet", 10 ], @@ -2204,6 +2216,8 @@ { "type": "item_group", "id": "allsporting", + "ammo": 50, + "magazine": 100, "items": [ [ "aspirin", 85 ], [ "sports_drink", 20 ], @@ -2698,6 +2712,8 @@ { "type": "item_group", "id": "winter", + "ammo": 50, + "magazine": 100, "items": [ [ "coat_winter", 50 ], [ "peacoat", 30 ], @@ -3226,7 +3242,7 @@ [ "rope_6", 5 ], [ "rope_30", 2 ], [ "duct_tape", 10 ], - [ "battery", 15 ], + { "group": "ammo_pocket_batteries_full", "prob": 15 }, [ "matches", 10 ], [ "gum", 10 ], [ "cable", 5 ], @@ -3516,7 +3532,7 @@ [ "briefcase", 40 ], [ "purse", 40 ], [ "mbag", 20 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries", "prob": 50 }, [ "mag_news", 35 ], [ "manual_business", 40 ], [ "textbook_business", 12 ], @@ -3595,7 +3611,7 @@ [ "briefcase", 40 ], [ "purse", 40 ], [ "mbag", 20 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries", "prob": 50 }, [ "mag_news", 35 ], [ "manual_business", 40 ], [ "textbook_business", 12 ], @@ -3685,7 +3701,7 @@ [ "glasses_eye", 30 ], [ "contacts", 30 ], [ "radio", 100 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "umbrella", 50 ], [ "teleumbrella", 20 ], [ "mag_barter", 10 ], @@ -3713,7 +3729,7 @@ [ "glasses_reading", 90 ], [ "purse", 40 ], [ "mbag", 20 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "mag_news", 35 ], [ "file", 20 ], [ "manual_computers", 20 ], @@ -4567,7 +4583,7 @@ [ "backpack", 38 ], [ "backpack_leather", 8 ], [ "slingpack", 8 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "novel_scifi", 20 ], [ "novel_drama", 40 ], [ "mag_dodge", 20 ], @@ -5062,14 +5078,13 @@ [ "mask_dust", 65 ], [ "glasses_safety", 40 ], [ "goggles_welding", 70 ], - [ "battery", 50 ], + { "group": "ammo_any_batteries_full", "prob": 50 }, [ "plut_cell", 10 ], [ "manual_electronics", 20 ], [ "textbook_electronics", 6 ], [ "radio_book", 16 ], [ "advanced_electronics", 6 ], [ "small_lcd_screen", 20 ], - [ "battery_compartment", 20 ], [ "double_plutonium_core", 2 ], [ "battery_ups", 15 ], [ "cell_phone", 15 ], @@ -5140,7 +5155,7 @@ [ "purse", 40 ], [ "mbag", 20 ], [ "fanny", 10 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "bb", 8 ], [ "bbgun", 10 ], [ "fan", 10 ], @@ -6013,7 +6028,7 @@ [ "hat_hard_hooded", 25 ], [ "wearable_light", 5 ], [ "ear_plugs", 50 ], - [ "battery", 50 ], + { "group": "ammo_any_batteries_full", "prob": 50 }, [ "flashlight", 40 ], [ "boots_rubber", 20 ], [ "toolbox", 1 ], @@ -6061,7 +6076,7 @@ [ "slingpack", 19 ], [ "briefcase", 20 ], [ "backpack_leather", 18 ], - [ "battery", 50 ], + { "group": "ammo_any_batteries", "prob": 50 }, [ "flashlight", 40 ], [ "heavy_flashlight", 10 ], [ "pickaxe", 1 ], @@ -6134,7 +6149,7 @@ [ "camera_pro", 2 ], [ "screwdriver", 40 ], [ "screwdriver_set", 10 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "file", 30 ], [ "mag_porn", 20 ], [ "mag_tv", 40 ], @@ -6538,7 +6553,7 @@ [ "kevlar_plate", 10 ], [ "ceramic_armor", 15 ], [ "motor", 2 ], - [ "battery", 50 ], + { "group": "ammo_heavy_batteries_full", "prob": 50 }, [ "plut_cell", 10 ] ] }, @@ -6684,7 +6699,7 @@ [ "mask_gas", 10 ], [ "helmet_army", 40 ], [ "helmet_liner", 10 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "plut_cell", 10 ], [ "m249", 1 ], [ "m240", 1 ], @@ -6991,7 +7006,6 @@ [ "eyedrops", 20 ], [ "adderall", 10 ], [ "id_science", 2 ], - [ "battery_compartment", 5 ], [ "double_plutonium_core", 1 ], [ "cleansuit", 5 ], [ "laptop", 10 ], @@ -7315,7 +7329,7 @@ [ "crackpipe", 37 ], [ "lsd", 10 ], [ "chemistry_set", 50 ], - [ "battery", 70 ], + { "group": "ammo_pocket_batteries_full", "prob": 70 }, [ "flashlight", 40 ], [ "chem_acetone", 40 ], [ "chem_hexamine", 15 ] @@ -7417,7 +7431,7 @@ [ "mintpatties", 20 ], [ "electrohack", 3 ], [ "usb_drive", 5 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "file", 10 ], [ "manual_computers", 20 ], [ "textbook_computer", 8 ], @@ -7587,7 +7601,7 @@ [ "UPS_off", 5 ], [ "adv_UPS_off", 2 ], [ "emer_blanket", 5 ], - [ "battery", 10 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "tool_belt", 5 ], [ "oxygen_tank", 15 ], [ "fireman_belt", 15 ], @@ -8485,7 +8499,7 @@ "items": [ [ "jumpsuit", 90 ], [ "mask_filter", 10 ], - [ "battery", 10 ], + { "group": "ammo_pocket_batteries_full", "prob": 10 }, { "item": "radio", "prob": 10, "charges-min": 10, "charges-max": 95 }, [ "boots_combat", 20 ], { "item": "bandages", "prob": 10, "charges-min": 1, "charges-max": 3 }, @@ -8525,7 +8539,7 @@ [ "winter_jacket_army", 20 ], [ "winter_gloves_army", 20 ], [ "army_top", 70 ], - [ "battery", 40 ], + { "group": "ammo_pocket_batteries_full", "prob": 40 }, { "item": "radio", "prob": 10, "charges-min": 10, "charges-max": 95 }, [ "boots_combat", 50 ], { "item": "bandages", "prob": 10, "charges-min": 1, "charges-max": 3 }, @@ -9062,7 +9076,7 @@ "id": "recycle_battery", "type": "item_group", "items": [ - { "item": "battery", "prob": 70, "charges-min": 0, "charges-max": 30 }, + { "group": "ammo_any_batteries", "prob": 70 }, [ "storage_battery", 25 ], [ "medium_storage_battery", 35 ], [ "small_storage_battery", 45 ], @@ -9206,7 +9220,7 @@ [ "duct_tape", 25 ], [ "flashlight", 25 ], [ "thread", 20 ], - [ "battery", 25 ], + { "group": "ammo_pocket_batteries_full", "prob": 25 }, [ "superglue", 25 ], [ "candle", 25 ], [ "hammer", 20 ], @@ -9441,21 +9455,11 @@ "type": "item_group", "subtype": "distribution", "id": "phones", - "entries": [ - { - "distribution": [ - { "item": "cell_phone", "prob": 90, "charges": 0 }, - { "item": "cell_phone", "prob": 10, "charges-min": 0, "charges-max": 15 } - ], - "prob": 50 - }, - { - "distribution": [ - { "item": "smart_phone", "prob": 90, "charges": 0 }, - { "item": "smart_phone", "prob": 10, "charges-min": 0, "charges-max": 15 } - ], - "prob": 50 - } + "items": [ + { "item": "cell_phone", "prob": 9, "charges-min": 0, "charges-max": 15 }, + { "item": "cell_phone", "prob": 1, "charges-min": 150, "charges-max": 150 }, + { "item": "smart_phone", "prob": 9, "charges-min": 0, "charges-max": 15 }, + { "item": "smart_phone", "prob": 1, "charges-min": 130, "charges-max": 130 } ] }, { diff --git a/data/json/itemgroups/ammo.json b/data/json/itemgroups/ammo.json index c0922af619127..1744b98f85547 100644 --- a/data/json/itemgroups/ammo.json +++ b/data/json/itemgroups/ammo.json @@ -377,5 +377,83 @@ { "item": "9x18mm_casing", "prob": 80, "count": 20 }, { "item": "shot_hull", "prob": 100, "count": 20 } ] + }, + { + "type": "item_group", + "id": "ammo_light_batteries", + "items": [ + { "item": "light_battery_cell", "prob": 50, "charges-min": 0, "charges-max": 100 }, + { "item": "light_minus_battery_cell", "prob": 30, "charges-min": 0, "charges-max": 50 }, + { "item": "light_plus_battery_cell", "prob": 20, "charges-min": 0, "charges-max": 150 } + ] + }, + { + "type": "item_group", + "id": "ammo_light_batteries_full", + "items": [ + { "item": "light_battery_cell", "prob": 50, "charges-min": 100, "charges-max": 100 }, + { "item": "light_minus_battery_cell", "prob": 30, "charges-min": 50, "charges-max": 50 }, + { "item": "light_plus_battery_cell", "prob": 20, "charges-min": 150, "charges-max": 150 } + ] + }, + { + "type": "item_group", + "id": "ammo_medium_batteries", + "items": [ + { "item": "medium_battery_cell", "prob": 80, "charges-min": 0, "charges-max": 500 }, + { "item": "medium_plus_battery_cell", "prob": 20, "charges-min": 0, "charges-max": 600 } + ] + }, + { + "type": "item_group", + "id": "ammo_medium_batteries_full", + "items": [ + { "item": "medium_battery_cell", "prob": 80, "charges-min": 500, "charges-max": 500 }, + { "item": "medium_plus_battery_cell", "prob": 20, "charges-min": 600, "charges-max": 600 } + ] + }, + { + "type": "item_group", + "id": "ammo_heavy_batteries", + "items": [ + { "item": "heavy_battery_cell", "prob": 80, "charges-min": 0, "charges-max": 1000 }, + { "item": "heavy_plus_battery_cell", "prob": 20, "charges-min": 0, "charges-max": 1250 } + ] + }, + { + "type": "item_group", + "id": "ammo_heavy_batteries_full", + "items": [ + { "item": "heavy_battery_cell", "prob": 80, "charges-min": 1000, "charges-max": 1000 }, + { "item": "heavy_plus_battery_cell", "prob": 20, "charges-min": 1250, "charges-max": 1250 } + ] + }, + { + "type": "item_group", + "id": "ammo_any_batteries_full", + "items": [ + { "group": "ammo_light_batteries_full", "prob": 5 }, + { "group": "ammo_medium_batteries_full", "prob": 5 }, + { "group": "ammo_heavy_batteries_full", "prob": 5 } + ] + }, + { + "type": "item_group", + "id": "ammo_any_batteries", + "items": [ + { "group": "ammo_light_batteries", "prob": 5 }, + { "group": "ammo_medium_batteries", "prob": 5 }, + { "group": "ammo_heavy_batteries", "prob": 5 } + ] + }, + { + "type": "item_group", + "id": "ammo_pocket_batteries", + "items": [ { "group": "ammo_light_batteries", "prob": 10 }, { "group": "ammo_medium_batteries", "prob": 1 } ] + }, + { + "type": "item_group", + "id": "ammo_pocket_batteries_full", + "items": [ { "group": "ammo_light_batteries_full", "prob": 5 }, { "group": "ammo_medium_batteries_full", "prob": 5 } ] } ] diff --git a/data/json/itemgroups/collections_domestic.json b/data/json/itemgroups/collections_domestic.json index f7336c87a2a42..35f180a05df79 100644 --- a/data/json/itemgroups/collections_domestic.json +++ b/data/json/itemgroups/collections_domestic.json @@ -2,6 +2,8 @@ { "type": "item_group", "id": "home_hw", + "ammo": 50, + "magazine": 100, "items": [ { "group": "tools_home", "prob": 150 }, { "group": "tools_general", "prob": 30 }, diff --git a/data/json/itemgroups/defense_mode.json b/data/json/itemgroups/defense_mode.json index 8766f39a29d17..8294c120df6a8 100644 --- a/data/json/itemgroups/defense_mode.json +++ b/data/json/itemgroups/defense_mode.json @@ -84,7 +84,7 @@ { "item": "hose" }, { "item": "pot" }, { "item": "2x4" }, - { "item": "battery" }, + { "group": "ammo_any_batteries_full" }, { "item": "nail" }, { "item": "gasoline" } ] diff --git a/data/json/itemgroups/gear.json b/data/json/itemgroups/gear.json index 8acbab30fdd06..8840f559158f0 100644 --- a/data/json/itemgroups/gear.json +++ b/data/json/itemgroups/gear.json @@ -43,7 +43,7 @@ [ "portable_game", 50 ], [ "vibrator", 5 ], [ "gum", 50 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries", "prob": 50 }, [ "wrapper", 50 ], [ "string_6", 50 ], [ "pocket_firstaid", 5 ], @@ -132,7 +132,7 @@ { "group": "tools_lighting", "prob": 50 }, { "group": "tools_survival", "prob": 100 }, { "group": "tools_tailor", "prob": 20 }, - [ "battery", 10 ], + { "group": "ammo_pocket_batteries_full", "prob": 10 }, [ "duct_tape", 10 ], [ "survivormap", 5 ] ] diff --git a/data/json/itemgroups/mall_item_groups.json b/data/json/itemgroups/mall_item_groups.json index b8c2a8760b948..a1a1629e066c2 100644 --- a/data/json/itemgroups/mall_item_groups.json +++ b/data/json/itemgroups/mall_item_groups.json @@ -68,7 +68,7 @@ { "id": "music_shop", "type": "item_group", - "items": [ [ "battery", 30 ], [ "radio", 30 ], [ "mp3", 30 ] ] + "items": [ { "group": "ammo_any_batteries_full", "prob": 50 }, [ "radio", 30 ], [ "mp3", 30 ] ] }, { "id": "vitamin_shop", @@ -203,7 +203,7 @@ "items": [ [ "portable_game", 20 ], [ "antenna", 25 ], - [ "battery", 70 ], + { "group": "ammo_any_batteries_full", "prob": 50 }, [ "mp3", 40 ], [ "usb_drive", 10 ], [ "manual_electronics", 20 ], diff --git a/data/json/itemgroups/mansion.json b/data/json/itemgroups/mansion.json index 26bfa1ca6463f..669ff99ee5b9a 100644 --- a/data/json/itemgroups/mansion.json +++ b/data/json/itemgroups/mansion.json @@ -747,7 +747,7 @@ "items": [ [ "socks", 90 ], [ "sneakers", 50 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries", "prob": 50 }, [ "sunglasses", 40 ], [ "socks_wool", 40 ], [ "towel", 40 ], diff --git a/data/json/itemgroups/supplies.json b/data/json/itemgroups/supplies.json index 9b00ee760498f..40b7a2823e685 100644 --- a/data/json/itemgroups/supplies.json +++ b/data/json/itemgroups/supplies.json @@ -9,7 +9,8 @@ [ "light_detector", 5 ], [ "amplifier", 40 ], [ "antenna", 40 ], - [ "battery", 100 ], + { "group": "ammo_any_batteries_full", "prob": 100 }, + [ "cable", 60 ], [ "power_supply", 20 ], [ "processor", 20 ], [ "solar_cell", 10 ], @@ -20,13 +21,13 @@ [ "receiver", 30 ], [ "transponder", 30 ], [ "light_bulb", 60 ], - [ "lightstrip_inactive", 10 ], - [ "lightstrip_dead", 60 ], + [ "lightstrip_inactive", 60 ], [ "motor_small", 10 ], [ "motor_tiny", 30 ], [ "motor_micro", 40 ], [ "jumper_cable", 15 ], - [ "jumper_cable_heavy", 5 ] + [ "jumper_cable_heavy", 5 ], + [ "recharge_station", 20 ] ] }, { @@ -87,7 +88,7 @@ [ "jerrycan", 5 ], { "item": "scrap_copper", "prob": 15, "count": [ 1, 2 ] }, [ "wire", 10 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "pilot_light", 50 ], [ "duct_tape", 200 ], [ "superglue", 100 ], @@ -98,7 +99,8 @@ [ "water_faucet", 100 ], [ "bubblewrap", 20 ], [ "pump_complex", 5 ], - [ "well_pump", 5 ] + [ "well_pump", 5 ], + [ "recharge_station", 20 ] ] }, { @@ -174,14 +176,15 @@ [ "cu_pipe", 50 ], [ "fungicide", 5 ], [ "charcoal", 5 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "solar_cell", 5 ], [ "fertilizer_commercial", 30 ], [ "chem_sulphuric_acid", 30 ], [ "peephole", 25 ], [ "chem_chromium_oxide", 5 ], [ "chem_zinc_powder", 5 ], - [ "denat_alcohol", 5 ] + [ "denat_alcohol", 5 ], + [ "recharge_station", 10 ] ] }, { @@ -343,7 +346,7 @@ [ "generator_7500w", 3 ], [ "storage_battery", 6 ], [ "solar_panel", 3 ], - [ "recharge_station", 2 ] + [ "recharge_station", 8 ] ] }, { @@ -379,7 +382,7 @@ [ "cell_phone", 10 ], [ "smart_phone", 10 ], [ "duct_tape", 5 ], - [ "battery", 5 ], + { "group": "ammo_pocket_batteries", "prob": 5 }, [ "flashlight", 10 ], [ "umbrella", 5 ], [ "teleumbrella", 10 ], @@ -409,7 +412,7 @@ [ "duct_tape", 15 ], [ "file", 15 ], [ "bubblewrap", 15 ], - [ "battery", 10 ], + { "group": "ammo_pocket_batteries_full", "prob": 10 }, [ "flashlight", 7 ], [ "laptop", 7 ], [ "eink_tablet_pc", 7 ], diff --git a/data/json/itemgroups/tools.json b/data/json/itemgroups/tools.json index 2561d20379fee..73b86f0a8dc7c 100644 --- a/data/json/itemgroups/tools.json +++ b/data/json/itemgroups/tools.json @@ -30,7 +30,8 @@ [ "elec_jackhammer", 40 ], [ "metal_smoother", 90 ], [ "jackhammer", 40 ], - [ "toolbox", 25 ] + [ "toolbox", 25 ], + [ "recharge_station", 10 ] ] }, { @@ -52,7 +53,8 @@ [ "funnel", 50 ], [ "crowbar", 10 ], [ "thermometer", 5 ], - [ "multitool", 10 ] + [ "multitool", 10 ], + [ "recharge_station", 10 ] ] }, { @@ -132,7 +134,8 @@ { "group": "tools_common", "prob": 100 }, [ "soldering_iron", 100 ], [ "magnifying_glass", 100 ], - [ "voltmeter", 100 ] + [ "voltmeter", 100 ], + [ "recharge_station", 10 ] ] }, { @@ -319,7 +322,7 @@ [ "syringe", 4 ], [ "xacto", 4 ], [ "cotton_ball", 4 ], - [ "battery", 50 ] + { "group": "ammo_any_batteries_full", "prob": 50 } ] }, { diff --git a/data/json/items/ammo.json b/data/json/items/ammo.json index ff9222454c9c0..cd179d1d6900b 100644 --- a/data/json/items/ammo.json +++ b/data/json/items/ammo.json @@ -8,7 +8,8 @@ "name_plural": "batteries", "symbol": "=", "color": "yellow", - "description": "A set of universal batteries. Used to charge almost any electronic device.", + "description": "Using an onboard screen, you can see how many kilojoules of energy are in the battery.", + "flags": "TRADER_AVOID", "material": "iron", "volume": 1, "weight": 1, @@ -17,6 +18,132 @@ "//": "1 battery is 1 kJ of energy. 40 batteries is an alkaline C-cell.", "fuel": { "energy": 1 } }, + { + "id": "light_minus_battery_cell", + "type": "MAGAZINE", + "category": "spare_parts", + "name": "ultra-light battery cell", + "name_plural": "ultra-light battery cells", + "description": "This is a light battery cell designed for small size over everything else. It retains its universal compatibility, though.", + "weight": 5, + "volume": 0, + "price": 1500, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "capacity": 50, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "NO_UNLOAD", "RECHARGE" ] + }, + { + "id": "light_battery_cell", + "type": "MAGAZINE", + "category": "spare_parts", + "name": "light battery cell", + "name_plural": "light battery cells", + "description": "This is a light battery cell, universally compatible with all kinds of small devices.", + "weight": 50, + "volume": "75ml", + "price": 3500, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "capacity": 100, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "NO_UNLOAD", "RECHARGE" ] + }, + { + "id": "light_plus_battery_cell", + "type": "MAGAZINE", + "category": "spare_parts", + "name": "light battery cell (high-capacity)", + "name_plural": "light battery cells (high-capacity)", + "description": "This is a high-capacity light battery cell, universally compatible with all kinds of personal electronic devices.", + "weight": 75, + "volume": "115ml", + "price": 5000, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "capacity": 150, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "NO_UNLOAD", "RECHARGE" ] + }, + { + "id": "medium_battery_cell", + "type": "MAGAZINE", + "category": "spare_parts", + "name": "medium battery cell", + "name_plural": "light battery cells", + "description": "This is a medium battery cell, universally compatible with all kinds of appliances and power tools.", + "weight": 250, + "volume": "375ml", + "price": 10000, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "capacity": 500, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "NO_UNLOAD", "RECHARGE" ] + }, + { + "id": "medium_plus_battery_cell", + "type": "MAGAZINE", + "category": "spare_parts", + "name": "medium battery cell (high-capacity)", + "name_plural": "medium battery cells (high-capacity)", + "description": "This is a high-capacity medium battery cell, universally compatible with all kinds of appliances and power tools.", + "weight": 350, + "volume": "450ml", + "price": 12500, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "capacity": 600, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "NO_UNLOAD", "RECHARGE" ] + }, + { + "id": "heavy_battery_cell", + "type": "MAGAZINE", + "category": "spare_parts", + "name": "heavy battery cell", + "name_plural": "heavy battery cells", + "description": "This is a heavy battery cell, universally compatible with all kinds of industrial-grade equipment and large tools.", + "weight": 500, + "volume": "750ml", + "price": 10000, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "capacity": 1000, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "NO_UNLOAD", "RECHARGE" ] + }, + { + "id": "heavy_plus_battery_cell", + "type": "MAGAZINE", + "category": "spare_parts", + "name": "heavy battery cell (high-capacity)", + "name_plural": "heavy battery cells (high-capacity)", + "description": "This is a high-capacity heavy battery cell, universally compatible with all kinds of industrial-grade equipment and large tools.", + "weight": 950, + "volume": "1000ml", + "price": 12500, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "capacity": 1250, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "NO_UNLOAD", "RECHARGE" ] + }, { "type": "AMMO", "id": "aluminum_foil", diff --git a/data/json/items/tool/lighting.json b/data/json/items/tool/lighting.json index 3402ff7585ce0..ab9bde2d2aed5 100644 --- a/data/json/items/tool/lighting.json +++ b/data/json/items/tool/lighting.json @@ -13,8 +13,6 @@ "material": [ "plastic" ], "symbol": ";", "color": "green", - "max_charges": 576, - "initial_charges": 576, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -25,7 +23,8 @@ "need_charges": 1, "need_charges_msg": "The lantern has no batteries." }, - "flags": [ "RADIO_MODABLE", "ALLOWS_REMOTE_USE" ] + "flags": [ "RADIO_MODABLE", "ALLOWS_REMOTE_USE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "electric_lantern_on", @@ -50,8 +49,6 @@ "weight": 400, "volume": 2, "price": 500, - "max_charges": 100, - "initial_charges": 100, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -61,7 +58,8 @@ "active": true, "need_charges": 1, "need_charges_msg": "The flashlight's batteries are dead." - } + }, + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "flashlight_on", @@ -122,8 +120,6 @@ "material": [ "aluminum" ], "symbol": ";", "color": "blue", - "max_charges": 205, - "initial_charges": 205, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -133,7 +129,8 @@ "active": true, "need_charges": 1, "need_charges_msg": "The heavy duty flashlight's batteries are dead." - } + }, + "magazines": [ [ "battery", [ "light_plus_battery_cell", "light_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "heavy_flashlight_on", diff --git a/data/json/items/tool/radio_tools.json b/data/json/items/tool/radio_tools.json index 7c64944ba95fc..986bdb87865da 100644 --- a/data/json/items/tool/radio_tools.json +++ b/data/json/items/tool/radio_tools.json @@ -23,11 +23,10 @@ "symbol": "#", "color": "yellow", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, "turns_per_charge": 5, "proportional": { "weight": 0.21, "volume": 0.25, "price": 0.2 }, - "use_action": "RADIOCONTROL" + "use_action": "RADIOCONTROL", + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "radio_car", @@ -37,12 +36,11 @@ "description": "A remote-controlled car. Fun for young and old alike.", "symbol": "#", "ammo": "battery", - "initial_charges": 50, - "max_charges": 50, "revert_to": "radio_car", "proportional": { "weight": 0.73, "volume": 0.75, "price": 0.8 }, "use_action": "RADIOCAR", - "flags": [ "RADIO_CONTAINER" ] + "flags": [ "RADIO_CONTAINER" ], + "magazines": [ [ "battery", [ "light_minus_battery_cell" ] ] ] }, { "id": "radio_car_on", @@ -85,9 +83,8 @@ "symbol": ";", "color": "light_gray", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, - "use_action": "RADIO_OFF" + "use_action": "RADIO_OFF", + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "radio_on", @@ -104,8 +101,6 @@ "symbol": ";", "color": "light_gray", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, "turns_per_charge": 8, "revert_to": "radio", "use_action": "RADIO_ON", @@ -124,9 +119,8 @@ "symbol": ";", "color": "green", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, - "flags": [ "TWO_WAY_RADIO" ] + "flags": [ "TWO_WAY_RADIO" ], + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "remotevehcontrol", @@ -141,10 +135,9 @@ "symbol": "#", "color": "yellow", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, "charges_per_use": 1, "turns_per_charge": 10, - "use_action": "REMOTEVEH" + "use_action": "REMOTEVEH", + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] } ] diff --git a/data/json/items/tool/science.json b/data/json/items/tool/science.json index 5889ec508c188..9af0b36a81af2 100644 --- a/data/json/items/tool/science.json +++ b/data/json/items/tool/science.json @@ -13,10 +13,10 @@ "color": "light_gray", "ammo": "battery", "sub": "hotplate", - "max_charges": 200, "charges_per_use": 1, "qualities": [ [ "DISTILL", 1 ], [ "CHEM", 3 ], [ "BOIL", 1 ] ], - "use_action": "HOTPLATE" + "use_action": "HOTPLATE", + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "chemistry_set_basic", @@ -43,12 +43,12 @@ "volume": 20, "price": 25000, "ammo": "battery", - "max_charges": 300, "to_hit": -5, "material": [ "plastic", "steel" ], "symbol": ";", "color": "light_gray", - "qualities": [ [ "ANALYSIS", 1 ] ] + "qualities": [ [ "ANALYSIS", 1 ] ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "balance_small", @@ -74,11 +74,11 @@ "volume": 8, "price": 8000, "ammo": "battery", - "max_charges": 100, "to_hit": -5, "material": [ "plastic", "steel" ], "symbol": ";", - "color": "light_gray" + "color": "light_gray", + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "cuvettes", @@ -105,11 +105,11 @@ "volume": 6, "price": 6000, "ammo": "battery", - "max_charges": 100, "to_hit": -5, "material": [ "plastic", "glass" ], "symbol": ";", - "color": "light_gray" + "color": "light_gray", + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "voltmeter", @@ -121,11 +121,11 @@ "volume": 6, "price": 6000, "ammo": "battery", - "max_charges": 100, "to_hit": -5, "material": [ "plastic" ], "symbol": ";", - "color": "light_gray" + "color": "light_gray", + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "melting_point", @@ -138,11 +138,11 @@ "volume": 6, "price": 6000, "ammo": "battery", - "max_charges": 100, "to_hit": -5, "material": [ "plastic", "glass" ], "symbol": ";", - "color": "light_gray" + "color": "light_gray", + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "vortex", @@ -322,8 +322,8 @@ "symbol": "n", "color": "white", "ammo": "battery", - "max_charges": 100, - "qualities": [ [ "CONCENTRATE", 1 ] ] + "qualities": [ [ "CONCENTRATE", 1 ] ], + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "stopcock", diff --git a/data/json/items/tool_armor.json b/data/json/items/tool_armor.json index ed222c0e7927f..d062656850db2 100644 --- a/data/json/items/tool_armor.json +++ b/data/json/items/tool_armor.json @@ -13,8 +13,6 @@ "weight": 1196, "volume": 12, "bashing": 6, - "max_charges": 100, - "initial_charges": 100, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -30,7 +28,8 @@ "warmth": 5, "encumbrance": 15, "coverage": 80, - "material_thickness": 4 + "material_thickness": 4, + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "miner_hat_on", @@ -47,8 +46,6 @@ "weight": 1196, "volume": 12, "bashing": 6, - "max_charges": 100, - "initial_charges": 100, "turns_per_charge": 15, "ammo": "battery", "revert_to": "miner_hat", @@ -79,8 +76,7 @@ "symbol": "[", "ammo": "battery", "use_action": "PORTABLE_GAME", - "max_charges": 60, - "initial_charges": 60 + "magazines": [ [ "battery", [ "light_minus_battery_cell" ] ] ] }, { "id": "holo_cloak", @@ -142,8 +138,6 @@ "material": [ "cotton" ], "weight": 182, "volume": 3, - "max_charges": 100, - "initial_charges": 100, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -157,7 +151,8 @@ "covers": [ "FEET" ], "warmth": 10, "coverage": 100, - "material_thickness": 1 + "material_thickness": 1, + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "thermal_socks_on", @@ -173,8 +168,6 @@ "material": [ "cotton" ], "weight": 182, "volume": 3, - "max_charges": 100, - "initial_charges": 100, "turns_per_charge": 50, "ammo": "battery", "revert_to": "thermal_socks", @@ -197,8 +190,6 @@ "material": [ "cotton" ], "weight": 864, "volume": 8, - "max_charges": 200, - "initial_charges": 200, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -212,7 +203,8 @@ "covers": [ "TORSO", "ARMS", "LEGS" ], "warmth": 10, "coverage": 100, - "material_thickness": 1 + "material_thickness": 1, + "magazines": [ [ "battery", [ "light_plus_battery_cell", "light_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "thermal_suit_on", @@ -228,8 +220,6 @@ "material": [ "cotton" ], "weight": 864, "volume": 8, - "max_charges": 200, - "initial_charges": 200, "turns_per_charge": 25, "ammo": "battery", "revert_to": "thermal_suit", @@ -253,8 +243,6 @@ "material": [ "cotton" ], "weight": 210, "volume": 3, - "max_charges": 100, - "initial_charges": 100, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -268,7 +256,8 @@ "covers": [ "HANDS" ], "warmth": 10, "coverage": 100, - "material_thickness": 1 + "material_thickness": 1, + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "thermal_gloves_on", @@ -284,8 +273,6 @@ "material": [ "cotton" ], "weight": 210, "volume": 3, - "max_charges": 100, - "initial_charges": 100, "turns_per_charge": 50, "ammo": "battery", "revert_to": "thermal_gloves", @@ -308,8 +295,6 @@ "material": [ "cotton" ], "weight": 196, "volume": 4, - "max_charges": 100, - "initial_charges": 100, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -323,7 +308,8 @@ "covers": [ "HEAD", "MOUTH" ], "warmth": 10, "coverage": 100, - "material_thickness": 1 + "material_thickness": 1, + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "thermal_mask_on", @@ -339,8 +325,6 @@ "material": [ "cotton" ], "weight": 196, "volume": 4, - "max_charges": 100, - "initial_charges": 100, "turns_per_charge": 50, "ammo": "battery", "revert_to": "thermal_mask", @@ -386,8 +370,6 @@ "weight": 520, "volume": 2, "bashing": 1, - "max_charges": 100, - "initial_charges": 100, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -400,7 +382,8 @@ }, "covers": [ "HEAD" ], "coverage": 15, - "material_thickness": 1 + "material_thickness": 1, + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "wearable_light_on", @@ -417,15 +400,14 @@ "weight": 520, "volume": 2, "bashing": 1, - "max_charges": 100, - "initial_charges": 100, "turns_per_charge": 20, "ammo": "battery", "revert_to": "wearable_light", "use_action": { "type": "transform", "menu_text": "Turn off", "msg": "The %s flicks off.", "target": "wearable_light" }, "covers": [ "HEAD" ], "coverage": 15, - "material_thickness": 1 + "material_thickness": 1, + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "survivor_light", @@ -441,8 +423,6 @@ "weight": 620, "volume": 2, "bashing": 1, - "max_charges": 150, - "initial_charges": 150, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -455,7 +435,8 @@ }, "covers": [ "HEAD" ], "coverage": 20, - "material_thickness": 1 + "material_thickness": 1, + "magazines": [ [ "battery", [ "light_plus_battery_cell", "light_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "survivor_light_on", @@ -472,8 +453,6 @@ "weight": 620, "volume": 2, "bashing": 1, - "max_charges": 150, - "initial_charges": 150, "turns_per_charge": 18, "ammo": "battery", "revert_to": "survivor_light", @@ -1004,8 +983,6 @@ "weight": 1020, "volume": 4, "to_hit": -3, - "max_charges": 200, - "initial_charges": 200, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -1021,7 +998,8 @@ "environmental_protection": 6, "encumbrance": 40, "coverage": 100, - "material_thickness": 2 + "material_thickness": 2, + "magazines": [ [ "battery", [ "light_plus_battery_cell", "light_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "goggles_nv_on", @@ -1038,9 +1016,7 @@ "weight": 1020, "volume": 4, "to_hit": -3, - "max_charges": 200, - "initial_charges": 200, - "turns_per_charge": 7, + "turns_per_charge": 9, "ammo": "battery", "revert_to": "goggles_nv", "use_action": { "type": "transform", "menu_text": "Turn off", "msg": "Your %s deactivates.", "target": "goggles_nv" }, @@ -1066,8 +1042,6 @@ "weight": 1240, "volume": 4, "to_hit": -3, - "max_charges": 200, - "initial_charges": 200, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -1083,7 +1057,8 @@ "environmental_protection": 6, "encumbrance": 40, "coverage": 100, - "material_thickness": 2 + "material_thickness": 2, + "magazines": [ [ "battery", [ "light_plus_battery_cell", "light_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "goggles_ir_on", @@ -1100,9 +1075,7 @@ "weight": 1240, "volume": 4, "to_hit": -3, - "max_charges": 200, - "initial_charges": 200, - "turns_per_charge": 10, + "turns_per_charge": 14, "ammo": "battery", "revert_to": "goggles_ir", "use_action": { "type": "transform", "menu_text": "Turn off", "msg": "Your %s deactivates.", "target": "goggles_ir" }, @@ -1111,7 +1084,8 @@ "environmental_protection": 6, "encumbrance": 20, "coverage": 100, - "material_thickness": 2 + "material_thickness": 2, + "magazines": [ [ "battery", [ "light_plus_battery_cell", "light_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "wearable_rx12", @@ -1354,15 +1328,14 @@ "weight": 68, "volume": 1, "to_hit": -1, - "max_charges": 20, - "initial_charges": 20, "charges_per_use": 1, "ammo": "battery", "use_action": "RADGLOVE", "covers": [ "HAND_EITHER" ], "coverage": 5, "material_thickness": 1, - "flags": [ "BELTED", "FRAGILE", "ALLOWS_NATURAL_ATTACKS", "WATER_FRIENDLY", "OVERSIZE" ] + "flags": [ "BELTED", "FRAGILE", "ALLOWS_NATURAL_ATTACKS", "WATER_FRIENDLY", "OVERSIZE" ], + "magazines": [ [ "battery", [ "light_minus_battery_cell" ] ] ] }, { "type": "ARMOR", @@ -1903,8 +1876,6 @@ "material": [ "cotton" ], "weight": 1452, "volume": 18, - "max_charges": 500, - "initial_charges": 500, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -1918,7 +1889,8 @@ "covers": [ "HEAD", "MOUTH", "TORSO", "ARMS", "LEGS", "HANDS", "FEET" ], "warmth": 10, "coverage": 100, - "material_thickness": 1 + "material_thickness": 1, + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "thermal_outfit_on", @@ -1934,8 +1906,6 @@ "material": [ "cotton" ], "weight": 1452, "volume": 18, - "max_charges": 500, - "initial_charges": 500, "turns_per_charge": 10, "ammo": "battery", "revert_to": "thermal_outfit", @@ -2216,8 +2186,6 @@ "material": [ "plastic" ], "weight": 179, "volume": 4, - "max_charges": 200, - "initial_charges": 100, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -2232,7 +2200,8 @@ "warmth": 5, "encumbrance": 5, "coverage": 10, - "material_thickness": 2 + "material_thickness": 2, + "magazines": [ [ "battery", [ "light_plus_battery_cell", "light_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "powered_earmuffs_on", @@ -2248,8 +2217,6 @@ "material": [ "plastic" ], "weight": 179, "volume": 4, - "max_charges": 200, - "initial_charges": 100, "turns_per_charge": 60, "ammo": "battery", "revert_to": "powered_earmuffs", @@ -2537,8 +2504,6 @@ "warmth": 50, "material_thickness": 3, "environmental_protection": 1, - "max_charges": 500, - "initial_charges": 10, "charges_per_use": 1, "ammo": "battery", "use_action": { @@ -2549,7 +2514,8 @@ "need_charges": 1, "need_charges_msg": "The blanket's batteries are dead." }, - "flags": [ "OVERSIZE", "OUTER", "ALLOWS_NATURAL_ATTACKS" ] + "flags": [ "OVERSIZE", "OUTER", "ALLOWS_NATURAL_ATTACKS", "RECHARGE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "electric_blanket_on", diff --git a/data/json/items/toolmod.json b/data/json/items/toolmod.json index 9e960a2f8a395..f9308c1e705a1 100644 --- a/data/json/items/toolmod.json +++ b/data/json/items/toolmod.json @@ -21,15 +21,6 @@ "capacity_multiplier": 100, "flags": [ "NO_UNLOAD", "LEAK_DAM", "RADIOACTIVE" ] }, - { - "id": "battery_compartment", - "copy-from": "mod_battery", - "type": "TOOLMOD", - "category": "spare_parts", - "name": "extra battery mod", - "description": "This is a homemade battery compartment made with spare electronics. With enough electronics skill, you could attach this to any electronic tool to double the amount of batteries it can hold.", - "capacity_multiplier": 2 - }, { "id": "battery_ups", "copy-from": "mod_battery", @@ -65,5 +56,38 @@ "color": "light_green", "acceptable_ammo": [ "battery" ], "magazine_adaptor": [ [ "battery", [ "small_storage_battery", "battery_car", "battery_motorbike" ] ] ] + }, + { + "id": "magazine_battery_light_mod", + "copy-from": "mod_battery", + "type": "TOOLMOD", + "category": "spare_parts", + "name": "light battery mod", + "description": "A battery compartment mod that allows the use of light batteries in tools that otherwise could not.", + "color": "light_green", + "acceptable_ammo": [ "battery" ], + "magazine_adaptor": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] + }, + { + "id": "magazine_battery_medium_mod", + "copy-from": "mod_battery", + "type": "TOOLMOD", + "category": "spare_parts", + "name": "medium battery mod", + "description": "A battery compartment mod that allows the use of medium batteries in tools that otherwise could not.", + "color": "light_green", + "acceptable_ammo": [ "battery" ], + "magazine_adaptor": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] + }, + { + "id": "magazine_battery_heavy_mod", + "copy-from": "mod_battery", + "type": "TOOLMOD", + "category": "spare_parts", + "name": "heavy battery mod", + "description": "A battery compartment mod that allows the use of heavy batteries in tools that otherwise could not.", + "color": "light_green", + "acceptable_ammo": [ "battery" ], + "magazine_adaptor": [ [ "battery", [ "heavy_battery_cell", "heavy_plus_battery_cell" ] ] ] } ] diff --git a/data/json/items/tools.json b/data/json/items/tools.json index 9371c669fb620..7463d04a41536 100644 --- a/data/json/items/tools.json +++ b/data/json/items/tools.json @@ -89,8 +89,8 @@ "symbol": ";", "color": "light_gray", "ammo": "battery", - "max_charges": 1000, - "flags": [ "NO_UNLOAD", "RECHARGE" ] + "flags": [ "RECHARGE" ], + "magazines": [ [ "battery", [ "heavy_plus_battery_cell", "heavy_battery_cell" ] ] ] }, { "id": "acidbomb", @@ -140,11 +140,10 @@ "symbol": "!", "color": "white", "ammo": "battery", - "initial_charges": 40, - "max_charges": 100, "charges_per_use": 1, "turns_per_charge": 1, - "use_action": "ECIG" + "use_action": "ECIG", + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "airhorn", @@ -1293,8 +1292,8 @@ "symbol": ";", "color": "dark_gray", "ammo": "battery", - "max_charges": 1000, - "flags": [ "ALLOWS_REMOTE_USE" ] + "flags": [ "ALLOWS_REMOTE_USE" ], + "magazines": [ [ "battery", [ "heavy_battery_cell", "heavy_plus_battery_cell" ] ] ] }, { "id": "broadfire_off", @@ -1476,11 +1475,10 @@ "symbol": ";", "color": "yellow", "ammo": "battery", - "initial_charges": 200, - "max_charges": 200, "charges_per_use": 5, "revert_to": "camera", - "use_action": "CAMERA" + "use_action": "CAMERA", + "magazines": [ [ "battery", [ "light_plus_battery_cell", "light_minus_battery_cell", "light_battery_cell" ] ] ] }, { "id": "camera_pro", @@ -1495,12 +1493,11 @@ "symbol": ";", "color": "yellow", "ammo": "battery", - "initial_charges": 200, - "max_charges": 200, "charges_per_use": 5, "revert_to": "camera_pro", "use_action": "CAMERA", - "flags": [ "CAMERA_PRO", "ALWAYS_TWOHAND" ] + "flags": [ "CAMERA_PRO", "ALWAYS_TWOHAND" ], + "magazines": [ [ "battery", [ "light_plus_battery_cell", "light_minus_battery_cell", "light_battery_cell" ] ] ] }, { "id": "can_sealer", @@ -1611,10 +1608,9 @@ "symbol": "/", "color": "yellow", "ammo": "battery", - "initial_charges": 100, - "max_charges": 200, "use_action": "CARVER_OFF", - "flags": [ "SHEATH_SWORD", "NONCONDUCTIVE" ] + "flags": [ "SHEATH_SWORD", "NONCONDUCTIVE" ], + "magazines": [ [ "battery", [ "light_plus_battery_cell", "light_minus_battery_cell", "light_battery_cell" ] ] ] }, { "id": "carver_on", @@ -1631,12 +1627,12 @@ "symbol": "/", "color": "yellow", "ammo": "battery", - "max_charges": 200, "turns_per_charge": 1, "revert_to": "carver_off", "qualities": [ [ "CUT", 1 ], [ "BUTCHER", 25 ] ], "use_action": "CARVER_ON", - "flags": [ "MESSY", "TRADER_AVOID", "NONCONDUCTIVE" ] + "flags": [ "MESSY", "TRADER_AVOID", "NONCONDUCTIVE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "catfood", @@ -1686,8 +1682,7 @@ "symbol": ";", "color": "light_gray", "ammo": "battery", - "initial_charges": 110, - "max_charges": 120, + "initial_charges": 150, "charges_per_use": 1, "use_action": { "target": "cell_phone_flashlight", @@ -1697,7 +1692,8 @@ "need_charges_msg": "The cellphone's batteries need more charge.", "type": "transform" }, - "flags": [ "WATCH", "ALARMCLOCK" ] + "flags": [ "WATCH", "ALARMCLOCK" ], + "magazines": [ [ "battery", [ "light_plus_battery_cell", "light_minus_battery_cell", "light_battery_cell" ] ] ] }, { "id": "cell_phone_flashlight", @@ -1939,11 +1935,10 @@ "symbol": "/", "color": "yellow", "ammo": "battery", - "initial_charges": 50, - "max_charges": 100, - "charges_per_use": 1, + "charges_per_use": 5, "use_action": { "target": "circsaw_on", "msg": "You turn on the circular saw.", "active": true, "type": "transform" }, - "flags": [ "NONCONDUCTIVE" ] + "flags": [ "NONCONDUCTIVE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "circsaw_on", @@ -1962,7 +1957,6 @@ "symbol": "/", "color": "yellow", "ammo": "battery", - "max_charges": 100, "turns_per_charge": 1, "revert_to": "circsaw_off", "qualities": [ [ "CUT", 1 ], [ "SAW_W", 2 ], [ "BUTCHER", -40 ] ], @@ -2062,10 +2056,10 @@ "symbol": ";", "color": "light_gray", "ammo": "battery", - "max_charges": 200, - "charges_per_use": 1, + "charges_per_use": 10, "qualities": [ [ "BOIL", 1 ] ], - "use_action": "HOTPLATE" + "use_action": "HOTPLATE", + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "combatsaw_off", @@ -2128,9 +2122,9 @@ "symbol": "/", "color": "light_gray", "ammo": "battery", - "max_charges": 1000, "use_action": "E_COMBATSAW_OFF", - "techniques": [ "WBLOCK_1", "SWEEP" ] + "techniques": [ "WBLOCK_1", "SWEEP" ], + "magazines": [ [ "battery", [ "heavy_battery_cell", "heavy_plus_battery_cell" ] ] ] }, { "id": "e_combatsaw_on", @@ -2149,7 +2143,6 @@ "symbol": "/", "color": "light_gray", "ammo": "battery", - "max_charges": 1000, "turns_per_charge": 1, "revert_to": "e_combatsaw_off", "techniques": [ "WBLOCK_1", "SWEEP" ], @@ -2171,11 +2164,10 @@ "symbol": "$", "color": "dark_gray", "ammo": "battery", - "initial_charges": 100, - "max_charges": 500, "charges_per_use": 20, "qualities": [ [ "CONTAIN", 1 ] ], - "use_action": "HOTPLATE" + "use_action": "HOTPLATE", + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "control_laptop", @@ -2189,10 +2181,10 @@ "symbol": ",", "color": "yellow", "ammo": "battery", - "max_charges": 1000, - "charges_per_use": 5, + "charges_per_use": 2, "use_action": "ROBOTCONTROL", - "flags": [ "NO_UNLOAD", "RECHARGE" ] + "flags": [ "RECHARGE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "copper_ax", @@ -2243,9 +2235,8 @@ "symbol": ";", "color": "yellow", "ammo": "battery", - "initial_charges": 300, - "max_charges": 300, - "qualities": [ [ "DRILL", 3 ], [ "SCREW", 1 ] ] + "qualities": [ [ "DRILL", 3 ], [ "SCREW", 1 ] ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "cot", @@ -2312,10 +2303,10 @@ "color": "pink", "ammo": "battery", "initial_charges": 20, - "max_charges": 100, "charges_per_use": 1, "turns_per_charge": 20, - "use_action": "DOLLCHAT" + "use_action": "DOLLCHAT", + "magazines": [ [ "battery", [ "light_minus_battery_cell", "light_battery_cell", "light_plus_battery_cell" ] ] ] }, { "id": "crossbow_trap", @@ -2480,12 +2471,12 @@ "symbol": "/", "color": "red", "ammo": "battery", - "max_charges": 800, "turns_per_charge": 1, "revert_to": "elec_chainsaw_off", "techniques": [ "WBLOCK_1", "SPIN", "SWEEP" ], "use_action": "ECS_LAJATANG_OFF", - "flags": [ "NONCONDUCTIVE" ] + "flags": [ "NONCONDUCTIVE" ], + "magazines": [ [ "battery", [ "heavy_battery_cell", "heavy_plus_battery_cell" ] ] ] }, { "id": "ecs_lajatang_on", @@ -2503,7 +2494,6 @@ "symbol": "/", "color": "red", "ammo": "battery", - "max_charges": 800, "turns_per_charge": 1, "revert_to": "ecs_lajatang_off", "techniques": [ "WBLOCK_1", "SPIN", "SWEEP" ], @@ -2558,9 +2548,8 @@ "symbol": ";", "color": "blue", "ammo": "battery", - "initial_charges": 100, - "max_charges": 200, - "flags": [ "ALLOWS_REMOTE_USE" ] + "flags": [ "ALLOWS_REMOTE_USE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "digging_stick", @@ -2782,12 +2771,11 @@ "symbol": ";", "color": "blue", "ammo": "battery", - "initial_charges": 50, - "max_charges": 100, "charges_per_use": 1, "revert_to": "eink_tablet_pc", "use_action": "EINKTABLETPC", - "flags": [ "WATCH" ] + "flags": [ "WATCH" ], + "magazines": [ [ "battery", [ "light_plus_battery_cell", "light_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "elec_chainsaw_off", @@ -2804,10 +2792,10 @@ "symbol": "/", "color": "red", "ammo": "battery", - "max_charges": 400, "techniques": "SWEEP", "use_action": "ELEC_CHAINSAW_OFF", - "flags": [ "NONCONDUCTIVE" ] + "flags": [ "NONCONDUCTIVE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "elec_chainsaw_on", @@ -2825,7 +2813,6 @@ "symbol": "/", "color": "red", "ammo": "battery", - "max_charges": 400, "turns_per_charge": 1, "revert_to": "elec_chainsaw_off", "techniques": "SWEEP", @@ -2847,10 +2834,9 @@ "symbol": ";", "color": "yellow", "ammo": "battery", - "initial_charges": 50, - "max_charges": 50, "charges_per_use": 10, - "use_action": "HAIRKIT" + "use_action": "HAIRKIT", + "magazines": [ [ "battery", [ "light_minus_battery_cell" ] ] ] }, { "id": "elec_jackhammer", @@ -2867,10 +2853,10 @@ "symbol": ";", "color": "light_gray", "ammo": "battery", - "max_charges": 400, - "charges_per_use": 10, + "charges_per_use": 25, "use_action": "JACKHAMMER", - "flags": [ "STAB", "DIG_TOOL", "POWERED" ] + "flags": [ "STAB", "DIG_TOOL", "POWERED" ], + "magazines": [ [ "battery", [ "heavy_battery_cell", "heavy_plus_battery_cell" ] ] ] }, { "id": "electrohack", @@ -2887,7 +2873,7 @@ "symbol": ",", "color": "green", "ammo": "battery", - "max_charges": 100 + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "etched_skull", @@ -3503,8 +3489,8 @@ "symbol": ";", "color": "light_gray", "ammo": "battery", - "max_charges": 500, - "flags": [ "ALLOWS_REMOTE_USE" ] + "flags": [ "ALLOWS_REMOTE_USE" ], + "magazines": [ [ "battery", [ "heavy_battery_cell", "heavy_plus_battery_cell" ] ] ] }, { "id": "funnel", @@ -3704,10 +3690,9 @@ "symbol": ";", "color": "green", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, "charges_per_use": 1, - "use_action": "GEIGER" + "use_action": "GEIGER", + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "geiger_on", @@ -3723,8 +3708,6 @@ "symbol": ";", "color": "green", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, "turns_per_charge": 10, "revert_to": "geiger_off", "use_action": "GEIGER", @@ -4034,10 +4017,9 @@ "symbol": ";", "color": "green", "ammo": "battery", - "initial_charges": 100, - "max_charges": 200, - "charges_per_use": 1, - "use_action": "HOTPLATE" + "charges_per_use": 5, + "use_action": "HOTPLATE", + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "hygrometer", @@ -4496,7 +4478,6 @@ "symbol": "/", "color": "light_gray", "ammo": "battery", - "max_charges": 1000, "charges_per_use": 1, "techniques": [ "WBLOCK_1", "RAPID" ], "use_action": { @@ -4507,7 +4488,8 @@ "need_charges_msg": "The L-stick(tm)'s batteries are empty.", "type": "transform" }, - "flags": [ "DURABLE_MELEE", "SHEATH_SPEAR" ] + "flags": [ "DURABLE_MELEE", "SHEATH_SPEAR" ], + "magazines": [ [ "battery", [ "medium_plus_battery_cell", "medium_battery_cell" ] ] ] }, { "id": "l-stick_on", @@ -4525,7 +4507,6 @@ "symbol": ";", "color": "blue", "ammo": "battery", - "max_charges": 1000, "turns_per_charge": 40, "revert_to": "l-stick", "techniques": [ "WBLOCK_1", "RAPID" ], @@ -4569,8 +4550,6 @@ "symbol": ";", "color": "dark_gray", "ammo": "battery", - "initial_charges": 250, - "max_charges": 500, "charges_per_use": 25, "qualities": [ [ "HAMMER_FINE", 1 ], @@ -4585,6 +4564,7 @@ [ "CHISEL", 3 ] ], "use_action": "GUN_REPAIR", + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ], "flags": [ "ALLOWS_REMOTE_USE" ] }, { @@ -4653,45 +4633,23 @@ "id": "lightstrip", "type": "TOOL", "name": "lightstrip", + "copy-from": "lightstrip_inactive", "name_plural": "lightstrips", - "description": "This is a light-emitting circuit wired directly to some batteries. It provides some weak light and can't be turned off. When the batteries die, you'll need to scrap it to recover the components that are reusable.", - "weight": 27, - "volume": 1, - "price": 500, - "to_hit": 2, - "bashing": 1, - "material": [ "plastic", "aluminum" ], + "description": "This is a light-emitting circuit that has been wired directly to a battery. It provides some weak light and can't be turned off until the battery dies.", "symbol": ";", "color": "green", - "initial_charges": 900, - "max_charges": 900, - "turns_per_charge": 120, - "revert_to": "lightstrip_dead", + "turns_per_charge": 1080, + "revert_to": "lightstrip_inactive", "revert_msg": "The lightstrip dies.", - "flags": [ "LIGHT_4" ] - }, - { - "id": "lightstrip_dead", - "type": "TOOL", - "category": "other", - "name": "lightstrip (unpowered)", - "name_plural": "lightstrips (unpowered)", - "description": "This is a unpowered lightstrip. You could connect it to batteries to get a light-emitting circuit.", - "weight": 27, - "volume": 1, - "price": 0, - "to_hit": 2, - "bashing": 1, - "material": [ "plastic", "aluminum" ], - "symbol": ";", - "color": "white" + "flags": [ "LIGHT_4", "NO_UNLOAD", "NO_RELOAD" ] }, { + "//": "This doesn't make too much sense, flavor-wise, but it's the best I can come up with. Put it on the todo list.", "id": "lightstrip_inactive", "type": "TOOL", "name": "lightstrip (inactive)", "name_plural": "lightstrips (inactive)", - "description": "This is a light-emitting circuit wired directly to some batteries. It will provide some weak light once activated and can't be turned off. When the batteries die, you'll need to scrap it to recover the components that are reusable.", + "description": "This is a light-emitting circuit that can be wired directly to a battery. It provides some weak light and can't be turned off until the battery dies.", "weight": 27, "volume": 1, "price": 500, @@ -4700,9 +4658,10 @@ "material": [ "plastic", "aluminum" ], "symbol": ";", "color": "white", - "initial_charges": 900, - "max_charges": 900, - "use_action": { "target": "lightstrip", "msg": "You irreversibly activate the lightstrip.", "active": true, "type": "transform" } + "ammo": "battery", + "use_action": { "target": "lightstrip", "msg": "You irreversibly activate the lightstrip.", "active": true, "type": "transform" }, + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ], + "magazine_well": 0 }, { "id": "lobotomizer", @@ -4883,8 +4842,8 @@ "symbol": ";", "color": "white", "ammo": "battery", - "max_charges": 200, - "flags": [ "ALLOWS_REMOTE_USE" ] + "flags": [ "ALLOWS_REMOTE_USE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "matchbomb", @@ -4973,11 +4932,10 @@ "color": "green", "ammo": "battery", "sub": "hotplate", - "initial_charges": 100, - "max_charges": 200, - "charges_per_use": 1, + "charges_per_use": 5, "qualities": [ [ "COOK", 2 ], [ "BOIL", 2 ], [ "CONTAIN", 1 ] ], - "use_action": [ "HOTPLATE", "HEAT_FOOD" ] + "use_action": [ "HOTPLATE", "HEAT_FOOD" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "metal_funnel", @@ -5030,11 +4988,10 @@ "color": "green", "ammo": "battery", "sub": "hotplate", - "initial_charges": 100, - "max_charges": 200, - "charges_per_use": 1, + "charges_per_use": 5, "qualities": [ [ "COOK", 2 ], [ "BOIL", 2 ], [ "CONTAIN", 1 ] ], - "use_action": [ "HOTPLATE", "HEAT_FOOD" ] + "use_action": [ "HOTPLATE", "HEAT_FOOD" ], + "magazines": [ [ "battery", [ "medium_plus_battery_cell", "medium_battery_cell" ] ] ] }, { "id": "mininuke", @@ -5098,7 +5055,6 @@ "symbol": ";", "color": "light_gray", "ammo": "tape", - "initial_charges": 100, "max_charges": 200, "charges_per_use": 50, "qualities": [ [ "CHISEL", 3 ], [ "HAMMER_FINE", 1 ], [ "HAMMER", 3 ], [ "PRY", 1 ] ], @@ -5214,9 +5170,8 @@ "symbol": ";", "color": "dark_gray", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, - "use_action": "MP3" + "use_action": "MP3", + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "mp3_on", @@ -5231,8 +5186,6 @@ "symbol": ";", "color": "dark_gray", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, "turns_per_charge": 150, "revert_to": "mp3", "use_action": "MP3_ON", @@ -5251,12 +5204,11 @@ "symbol": ";", "color": "red", "ammo": "battery", - "initial_charges": 300, - "max_charges": 300, "turns_per_charge": 10, "revert_to": "multi_cooker", "qualities": [ [ "CONTAIN", 1 ] ], - "use_action": "MULTICOOKER" + "use_action": "MULTICOOKER", + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "multitool", @@ -5392,10 +5344,9 @@ "symbol": ";", "color": "yellow", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, "use_action": "NOISE_EMITTER_OFF", - "flags": [ "RADIO_MODABLE" ] + "flags": [ "RADIO_MODABLE" ], + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "noise_emitter_on", @@ -5412,8 +5363,6 @@ "symbol": ";", "color": "yellow", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, "turns_per_charge": 1, "revert_to": "noise_emitter", "use_action": "NOISE_EMITTER_ON", @@ -5893,8 +5842,8 @@ "symbol": ";", "color": "light_gray", "ammo": "battery", - "max_charges": 100, - "flags": [ "TRADER_AVOID" ] + "flags": [ "TRADER_AVOID" ], + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "popcan_stove", @@ -5928,9 +5877,8 @@ "symbol": ";", "color": "light_gray", "ammo": "battery", - "initial_charges": 100, - "max_charges": 200, - "use_action": "PORTABLE_GAME" + "use_action": "PORTABLE_GAME", + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "portal", @@ -6176,8 +6124,6 @@ "symbol": ";", "color": "white", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, "charges_per_use": 1, "use_action": { "target": "reading_light_on", @@ -6186,7 +6132,8 @@ "need_charges": 1, "need_charges_msg": "The reading light winks out.", "type": "transform" - } + }, + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "reading_light_on", @@ -6657,12 +6604,12 @@ "symbol": "/", "color": "brown", "ammo": "battery", - "max_charges": 500, "charges_per_use": 100, "qualities": [ [ "HAMMER", 1 ] ], "techniques": [ "WBLOCK_2", "RAPID", "SWEEP" ], "use_action": "TAZER", - "flags": [ "DURABLE_MELEE", "NO_UNLOAD", "RECHARGE", "NONCONDUCTIVE", "SHEATH_SPEAR" ] + "flags": [ "DURABLE_MELEE", "RECHARGE", "NONCONDUCTIVE", "SHEATH_SPEAR" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "shocktonfa_off", @@ -6680,11 +6627,11 @@ "symbol": "/", "color": "dark_gray", "ammo": "battery", - "max_charges": 500, "charges_per_use": 1, "techniques": [ "WBLOCK_2", "RAPID" ], "use_action": "SHOCKTONFA_OFF", - "flags": [ "DURABLE_MELEE", "NO_UNLOAD", "RECHARGE", "NONCONDUCTIVE", "BELT_CLIP" ] + "flags": [ "DURABLE_MELEE", "RECHARGE", "NONCONDUCTIVE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "shocktonfa_on", @@ -6702,7 +6649,6 @@ "symbol": "/", "color": "dark_gray", "ammo": "battery", - "max_charges": 500, "charges_per_use": 1, "turns_per_charge": 15, "revert_to": "shocktonfa_off", @@ -6799,8 +6745,6 @@ "symbol": ";", "color": "light_gray", "ammo": "battery", - "initial_charges": 100, - "max_charges": 300, "charges_per_use": 100, "qualities": [ [ "HAMMER_FINE", 1 ], @@ -6816,6 +6760,7 @@ [ "CHISEL", 3 ] ], "use_action": "GUN_REPAIR", + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ], "flags": [ "ALLOWS_REMOTE_USE" ] }, { @@ -6833,8 +6778,6 @@ "symbol": "&", "color": "blue", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, "charges_per_use": 1, "use_action": { "target": "smart_lamp_on", @@ -6844,7 +6787,8 @@ "need_charges_msg": "The smart lamp batteries are dead.", "type": "transform" }, - "flags": [ "RADIO_ACTIVATION", "RADIOSIGNAL_2" ] + "flags": [ "RADIO_ACTIVATION", "RADIOSIGNAL_2" ], + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "smart_lamp_on", @@ -6861,8 +6805,6 @@ "symbol": "&", "color": "green", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, "turns_per_charge": 25, "revert_to": "smart_lamp", "use_action": { "target": "smart_lamp", "msg": "Your smart lamp turned off", "menu_text": "Turn off", "type": "transform" }, @@ -6900,8 +6842,6 @@ "symbol": ",", "color": "light_gray", "ammo": "battery", - "initial_charges": 20, - "max_charges": 200, "charges_per_use": 1, "use_action": [ { @@ -6914,7 +6854,8 @@ }, { "flame": false, "type": "cauterize" } ], - "flags": [ "SPEAR", "BELT_CLIP", "ALLOWS_REMOTE_USE" ] + "flags": [ "SPEAR", "BELT_CLIP", "ALLOWS_REMOTE_USE" ], + "magazines": [ [ "battery", [ "light_minus_battery_cell", "light_battery_cell", "light_plus_battery_cell" ] ] ] }, { "id": "spear_knife", @@ -7222,10 +7163,10 @@ "color": "pink", "ammo": "battery", "initial_charges": 20, - "max_charges": 100, "charges_per_use": 1, "turns_per_charge": 20, - "use_action": "DOLLCHAT" + "use_action": "DOLLCHAT", + "magazines": [ [ "battery", [ "light_minus_battery_cell", "light_battery_cell", "light_plus_battery_cell" ] ] ] }, { "id": "tanning_hide", @@ -7309,10 +7250,10 @@ "symbol": ";", "color": "dark_gray", "ammo": "battery", - "max_charges": 500, "charges_per_use": 100, "use_action": "TAZER", - "flags": [ "NO_UNLOAD", "RECHARGE" ] + "flags": [ "RECHARGE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "teapot", @@ -7353,17 +7294,16 @@ "name": "teleporter", "description": "This is an experimental device that will teleport you a short distance when activated.", "weight": 1360, - "volume": 3, + "volume": 8, "price": 600000, "to_hit": -1, "bashing": 4, "material": [ "plastic", "aluminum" ], "symbol": ";", "color": "magenta", - "initial_charges": 20, - "max_charges": 20, - "charges_per_use": 1, - "use_action": "TELEPORT" + "charges_per_use": 25, + "use_action": "TELEPORT", + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "teleumbrella", @@ -7489,7 +7429,6 @@ "symbol": ";", "color": "brown", "ammo": "battery", - "max_charges": 300, "flags": [ "ALLOWS_REMOTE_USE", "RECHARGE" ], "use_action": { "target": "small_space_heater_on", @@ -7499,7 +7438,8 @@ "need_charges_msg": "The heater needs more charge.", "menu_text": "Turn on", "type": "transform" - } + }, + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "small_space_heater_on", @@ -7516,7 +7456,6 @@ "symbol": ";", "color": "magenta", "ammo": "battery", - "max_charges": 300, "turns_per_charge": 30, "emits": [ "emit_hot_air2_stream" ], "flags": [ "ALLOWS_REMOTE_USE", "LIGHT_2", "RECHARGE" ], @@ -7537,7 +7476,6 @@ "symbol": ";", "color": "brown", "ammo": "battery", - "max_charges": 500, "flags": [ "ALLOWS_REMOTE_USE", "RECHARGE" ], "use_action": { "target": "large_space_heater_on", @@ -7547,7 +7485,8 @@ "need_charges_msg": "The heater needs more charge.", "menu_text": "Turn on", "type": "transform" - } + }, + "magazines": [ [ "battery", [ "heavy_battery_cell", "heavy_plus_battery_cell" ] ] ] }, { "id": "large_space_heater_on", @@ -7564,7 +7503,6 @@ "symbol": ";", "color": "magenta", "ammo": "battery", - "max_charges": 500, "turns_per_charge": 20, "emits": [ "emit_hot_air2_blast" ], "flags": [ "ALLOWS_REMOTE_USE", "LIGHT_2", "RECHARGE" ], @@ -8208,9 +8146,8 @@ "symbol": ";", "color": "white", "ammo": "battery", - "initial_charges": 100, - "max_charges": 200, - "flags": [ "ALLOWS_REMOTE_USE" ] + "flags": [ "ALLOWS_REMOTE_USE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "vacutainer", @@ -8245,9 +8182,8 @@ "symbol": ";", "color": "dark_gray", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, - "use_action": "VIBE" + "use_action": "VIBE", + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "violin", @@ -8393,11 +8329,10 @@ "symbol": ";", "color": "light_blue", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, "charges_per_use": 1, "use_action": "WATER_PURIFIER", - "flags": [ "ALLOWS_REMOTE_USE" ] + "flags": [ "ALLOWS_REMOTE_USE" ], + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "weather_reader", @@ -8414,10 +8349,10 @@ "symbol": ";", "color": "light_gray", "ammo": "battery", - "max_charges": 20, - "charges_per_use": 1, + "charges_per_use": 5, "use_action": "WEATHER_TOOL", - "flags": [ "THERMOMETER", "HYGROMETER", "BAROMETER" ] + "flags": [ "THERMOMETER", "HYGROMETER", "BAROMETER" ], + "magazines": [ [ "battery", [ "light_battery_cell", "light_plus_battery_cell", "light_minus_battery_cell" ] ] ] }, { "id": "welder", @@ -8433,7 +8368,6 @@ "symbol": ";", "color": "red", "ammo": "battery", - "max_charges": 500, "charges_per_use": 5, "qualities": [ [ "WELD", 2 ] ], "use_action": [ @@ -8448,7 +8382,8 @@ }, { "flame": false, "type": "cauterize" } ], - "flags": [ "FIRESTARTER", "ALLOWS_REMOTE_USE" ] + "flags": [ "FIRESTARTER", "ALLOWS_REMOTE_USE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "welder_crude", @@ -8464,8 +8399,7 @@ "symbol": ";", "color": "light_red", "ammo": "battery", - "max_charges": 450, - "charges_per_use": 5, + "charges_per_use": 10, "qualities": [ [ "WELD", 1 ] ], "use_action": [ { @@ -8479,7 +8413,8 @@ }, { "flame": false, "type": "cauterize" } ], - "flags": [ "FIRESTARTER", "ALLOWS_REMOTE_USE" ] + "flags": [ "FIRESTARTER", "ALLOWS_REMOTE_USE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "wood_smoother", @@ -8662,9 +8597,8 @@ "symbol": "%", "color": "white", "ammo": "battery", - "initial_charges": 100, - "max_charges": 100, - "flags": [ "ALLOWS_REMOTE_USE" ] + "flags": [ "ALLOWS_REMOTE_USE" ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "id": "cattlefodder", diff --git a/data/json/items/vehicle_parts.json b/data/json/items/vehicle_parts.json index e3d83725790f3..d9ad9d43810db 100644 --- a/data/json/items/vehicle_parts.json +++ b/data/json/items/vehicle_parts.json @@ -1015,7 +1015,7 @@ "type": "GENERIC", "id": "recharge_station", "name": "UPS-compatible recharging station", - "description": "A Unified Power System recharging station designed to operate on vehicle power. Once installed in a vehicle storage space and turned on from a dashboard or electronics control unit, it will slowly charge all tools with rechargeable batteries in that space. The system can only be installed in existing storage compartments.", + "description": "A Unified Power System recharging station designed to operate on vehicle power. Once installed in a vehicle storage space and turned on from a dashboard or electronics control unit, it will slowly charge all UPS compatible tools and battery cells in that space. The system can only be installed in existing storage compartments.", "weight": 10000, "to_hit": 1, "color": "light_blue", diff --git a/data/json/mapgen/abandoned01.json b/data/json/mapgen/abandoned01.json index 4df78020c5bf5..d0c4e72d3161a 100644 --- a/data/json/mapgen/abandoned01.json +++ b/data/json/mapgen/abandoned01.json @@ -553,10 +553,10 @@ { "item": "flashlight", "x": 11, "y": 16 }, { "item": "child_book", "x": 11, "y": 16 }, { "item": "child_book", "x": 11, "y": 15 }, - { "item": "pot", "x": 11, "y": 23 }, - { "item": "battery", "x": 11, "y": 16, "chance": 33 } + { "item": "pot", "x": 11, "y": 23 } ], "place_loot": [ + { "group": "ammo_any_batteries_full", "x": 11, "y": 16, "chance": 33 }, { "group": "cabin_suicide", "x": [ 4, 4 ], "y": [ 15, 15 ], "chance": 80 }, { "group": "cannedfood", "x": [ 11, 11 ], "y": [ 22, 23 ], "chance": 90 }, { "group": "cannedfood", "x": [ 13, 13 ], "y": [ 22, 23 ], "chance": 90 }, diff --git a/data/json/mapgen/cs_car_dealership.json b/data/json/mapgen/cs_car_dealership.json index aee926a43130e..e47f9dad69cfb 100644 --- a/data/json/mapgen/cs_car_dealership.json +++ b/data/json/mapgen/cs_car_dealership.json @@ -21,7 +21,7 @@ "type": "item_group", "id": "oa_ig_cd_desks", "items": [ - [ "battery", 30 ], + { "group": "ammo_pocket_batteries_full", "prob": 30 }, [ "radio", 10 ], [ "eyedrops", 10 ], [ "rag", 30 ], @@ -42,7 +42,7 @@ "type": "item_group", "id": "oa_ig_cd_lockers", "items": [ - [ "battery", 10 ], + { "group": "ammo_pocket_batteries_full", "prob": 10 }, [ "radio", 10 ], [ "rag", 30 ], [ "jack", 20 ], @@ -69,7 +69,7 @@ "type": "item_group", "id": "oa_ig_cd_crates", "items": [ - [ "battery", 10 ], + { "group": "ammo_any_batteries_full", "prob": 10 }, [ "radio", 10 ], [ "rag", 30 ], [ "jack", 20 ], diff --git a/data/json/mapgen/cs_car_showroom.json b/data/json/mapgen/cs_car_showroom.json index 518e01efdd03b..5d2fb51f5c5ee 100644 --- a/data/json/mapgen/cs_car_showroom.json +++ b/data/json/mapgen/cs_car_showroom.json @@ -16,7 +16,7 @@ "type": "item_group", "id": "oa_ig_cs_desks", "items": [ - [ "battery", 30 ], + { "group": "ammo_pocket_batteries_full", "prob": 30 }, [ "radio", 10 ], [ "eyedrops", 10 ], [ "rag", 30 ], @@ -37,7 +37,7 @@ "type": "item_group", "id": "oa_ig_cs_lockers", "items": [ - [ "battery", 10 ], + { "group": "ammo_pocket_batteries_full", "prob": 10 }, [ "radio", 10 ], [ "rag", 30 ], [ "dress_shoes", 20 ], diff --git a/data/json/mapgen/cs_city_dump_small.json b/data/json/mapgen/cs_city_dump_small.json index c867b9a9fc7c3..4b0f4e9159de7 100644 --- a/data/json/mapgen/cs_city_dump_small.json +++ b/data/json/mapgen/cs_city_dump_small.json @@ -4,7 +4,7 @@ "id": "custom_trash", "items": [ [ "mag_porn", 10 ], - [ "battery", 10 ], + { "group": "ammo_pocket_batteries", "prob": 10 }, [ "television", 20 ], [ "two_way_radio", 10 ], [ "eyedrops", 10 ], diff --git a/data/json/mapgen/cs_internet_cafe.json b/data/json/mapgen/cs_internet_cafe.json index 5cf23d1be7b9a..525bc8bcc22e2 100644 --- a/data/json/mapgen/cs_internet_cafe.json +++ b/data/json/mapgen/cs_internet_cafe.json @@ -18,7 +18,7 @@ "items": [ [ "cell_phone", 20 ], [ "mag_computer", 20 ], - [ "battery", 20 ], + { "group": "ammo_pocket_batteries_full", "prob": 20 }, [ "radio", 20 ], [ "television", 20 ], [ "two_way_radio", 20 ], diff --git a/data/json/mapgen/cs_tire_shop.json b/data/json/mapgen/cs_tire_shop.json index e11b6ffb2d9eb..5a7b55a43d13f 100644 --- a/data/json/mapgen/cs_tire_shop.json +++ b/data/json/mapgen/cs_tire_shop.json @@ -38,7 +38,7 @@ "type": "item_group", "id": "oa_ig_ts_lockers", "items": [ - [ "battery", 10 ], + { "group": "ammo_pocket_batteries_full", "prob": 10 }, [ "radio", 10 ], [ "rag", 30 ], [ "jack", 20 ], @@ -65,7 +65,7 @@ "type": "item_group", "id": "oa_ig_ts_crates", "items": [ - [ "battery", 10 ], + { "group": "ammo_any_batteries_full", "prob": 10 }, [ "radio", 10 ], [ "rag", 30 ], [ "jack", 20 ], diff --git a/data/json/mapgen/library.json b/data/json/mapgen/library.json index a4c980eaa9315..13962e60dd17f 100644 --- a/data/json/mapgen/library.json +++ b/data/json/mapgen/library.json @@ -12,7 +12,7 @@ [ "receiver", 10 ], [ "antenna", 18 ], [ "screwdriver", 40 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "manual_electronics", 20 ], [ "mobile_memory_card", 20 ], [ "usb_drive", 5 ], diff --git a/data/json/mapgen/necropolis/necropolisB1.json b/data/json/mapgen/necropolis/necropolisB1.json index 6c192f8da35de..3b4d8257d6134 100644 --- a/data/json/mapgen/necropolis/necropolisB1.json +++ b/data/json/mapgen/necropolis/necropolisB1.json @@ -38,7 +38,7 @@ "items": [ { "group": "guns_rare", "prob": 35 }, { "item": "mask_filter", "prob": 20 }, - { "item": "battery", "prob": 15 }, + { "group": "ammo_pocket_batteries_full", "prob": 15 }, { "item": "radio", "prob": 10 }, { "item": "bandages", "prob": 10 }, { "item": "knife_combat", "prob": 20 }, diff --git a/data/json/mapgen/s_electronics.json b/data/json/mapgen/s_electronics.json index e7763c102189c..6228374f047b1 100644 --- a/data/json/mapgen/s_electronics.json +++ b/data/json/mapgen/s_electronics.json @@ -53,7 +53,7 @@ "type": "item_group", "items": [ [ "cable", 95 ], - [ "battery", 85 ], + { "group": "ammo_pocket_batteries_full", "prob": 85 }, [ "scrap", 70 ], [ "e_scrap", 95 ], [ "antenna", 50 ], diff --git a/data/json/mapgen/ws_fire_lookout_tower.json b/data/json/mapgen/ws_fire_lookout_tower.json index 01308c3d7c93c..c950ffa53d19f 100644 --- a/data/json/mapgen/ws_fire_lookout_tower.json +++ b/data/json/mapgen/ws_fire_lookout_tower.json @@ -92,7 +92,7 @@ "type": "item_group", "id": "flt_loot_misc", "items": [ - [ "battery", 20 ], + { "group": "ammo_pocket_batteries_full", "prob": 20 }, [ "flashlight", 20 ], [ "heavy_flashlight", 20 ], [ "crowbar", 20 ], diff --git a/data/json/mapgen/ws_regional_dump.json b/data/json/mapgen/ws_regional_dump.json index a1c29c433ee09..33ef3bd431a5e 100644 --- a/data/json/mapgen/ws_regional_dump.json +++ b/data/json/mapgen/ws_regional_dump.json @@ -33,7 +33,7 @@ "type": "item_group", "id": "oa_ig_rd_desks", "items": [ - [ "battery", 30 ], + { "group": "ammo_pocket_batteries", "prob": 30 }, [ "radio", 10 ], [ "eyedrops", 10 ], [ "rag", 30 ], @@ -86,7 +86,7 @@ "type": "item_group", "id": "oa_ig_rd_lockers", "items": [ - [ "battery", 10 ], + { "group": "ammo_pocket_batteries", "prob": 10 }, [ "radio", 10 ], [ "rag", 30 ], [ "flashlight", 20 ], @@ -115,7 +115,7 @@ [ "hat_hard_hooded", 25 ], [ "wearable_light", 5 ], [ "ear_plugs", 50 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries", "prob": 50 }, [ "flashlight", 40 ], [ "boots_rubber", 20 ], [ "toolbox", 5 ], @@ -126,7 +126,7 @@ "type": "item_group", "id": "oa_ig_rd_electronic_trash", "items": [ - [ "battery", 10 ], + { "group": "ammo_pocket_batteries", "prob": 10 }, [ "solar_panel", 15 ], [ "jumper_cable", 5 ], [ "pipe", 20 ], diff --git a/data/json/mapgen/ws_survivor_bunker.json b/data/json/mapgen/ws_survivor_bunker.json index cb2f68c77080c..0eebefc01e199 100644 --- a/data/json/mapgen/ws_survivor_bunker.json +++ b/data/json/mapgen/ws_survivor_bunker.json @@ -65,7 +65,7 @@ [ "canteen", 20 ], [ "knife_hunting", 30 ], [ "shovel", 30 ], - [ "battery", 30 ] + { "group": "ammo_pocket_batteries_full", "prob": 30 } ] }, { diff --git a/data/json/npcs/NC_HACKER.json b/data/json/npcs/NC_HACKER.json index f77ce97ff8980..a820b5f20e8a0 100644 --- a/data/json/npcs/NC_HACKER.json +++ b/data/json/npcs/NC_HACKER.json @@ -15,7 +15,7 @@ [ "mintpatties", 20 ], [ "electrohack", 3 ], [ "usb_drive", 5 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "file", 10 ], [ "manual_computers", 20 ], [ "textbook_computer", 8 ], diff --git a/data/json/npcs/NC_JUNK_SHOPKEEP.json b/data/json/npcs/NC_JUNK_SHOPKEEP.json index dcfff8820888b..de09e022ad3ba 100644 --- a/data/json/npcs/NC_JUNK_SHOPKEEP.json +++ b/data/json/npcs/NC_JUNK_SHOPKEEP.json @@ -163,7 +163,7 @@ [ "cordless_drill", 10 ], [ "mask_dust", 65 ], [ "glasses_safety", 40 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "nail", 35 ], [ "nailgun", 12 ], [ "hand_drill", 10 ], @@ -366,7 +366,7 @@ [ "amplifier", 8 ], [ "mag_electronics", 15 ], [ "antenna", 18 ], - [ "battery", 50 ], + { "group": "ammo_pocket_batteries_full", "prob": 50 }, [ "soldering_iron", 70 ], [ "solder_wire", 70 ], [ "solar_cell", 5 ], diff --git a/data/json/npcs/items_generic.json b/data/json/npcs/items_generic.json index 5c7bbe325a7f7..4185a06b32030 100644 --- a/data/json/npcs/items_generic.json +++ b/data/json/npcs/items_generic.json @@ -362,8 +362,7 @@ [ "barrel_ported", 1 ], [ "baseball", 1 ], [ "bat", 5 ], - [ "battery", 25 ], - [ "battery_compartment", 5 ], + { "group": "ammo_pocket_batteries_full", "prob": 25 }, [ "beartrap", 10 ], [ "beer", 15 ], [ "belgian_ale", 3 ], diff --git a/data/json/professions.json b/data/json/professions.json index cf665eac133f4..fe974b2779c4c 100644 --- a/data/json/professions.json +++ b/data/json/professions.json @@ -436,6 +436,8 @@ "skills": [ { "level": 3, "name": "mechanics" } ], "items": { "both": { + "ammo": 100, + "magazine": 100, "items": [ "slingpack", "tank_top", @@ -448,9 +450,10 @@ "screwdriver", "cell_phone", "wristwatch", - "mag_cars" + "mag_cars", + "welder" ], - "entries": [ { "item": "welder", "charges": 500 }, { "item": "goggles_welding", "custom-flags": [ "no_auto_equip" ] } ] + "entries": [ { "item": "goggles_welding", "custom-flags": [ "no_auto_equip" ] } ] }, "male": [ "boxer_shorts" ], "female": [ "bra", "boy_shorts" ] @@ -1298,7 +1301,20 @@ "points": 1, "skills": [ { "level": 3, "name": "electronics" } ], "items": { - "both": [ "jumpsuit", "socks", "boots", "tool_belt", "flashlight", "cell_phone", "wristwatch" ], + "both": { + "ammo": 100, + "magazine": 100, + "items": [ + "jumpsuit", + "socks", + "boots", + "tool_belt", + "flashlight", + "cell_phone", + "wristwatch", + { "item": "light_battery_cell", "charges": 100 } + ] + }, "male": [ "boxer_briefs" ], "female": [ "bra", "panties" ] } @@ -1740,6 +1756,7 @@ "items": { "both": { "ammo": 100, + "magazine": 100, "items": [ "winter_pants_army", "army_top", @@ -2887,7 +2904,7 @@ "jacket_light", "baton", "tazer", - "battery", + "medium_battery_cell", "pockknife", "wristwatch", "cell_phone" @@ -3561,7 +3578,7 @@ "1st_aid", "smart_phone", "wristwatch", - "battery" + "medium_battery_cell" ], "male": [ "boxer_shorts" ], "female": [ "bra", "panties" ] diff --git a/data/json/recipes/electronics/toolmod.json b/data/json/recipes/electronics/toolmod.json index a9bbe55544a91..b6deabe1710d1 100644 --- a/data/json/recipes/electronics/toolmod.json +++ b/data/json/recipes/electronics/toolmod.json @@ -14,23 +14,6 @@ "qualities": [ { "id": "SCREW", "level": 1 } ], "components": [ [ [ "scrap", 6 ] ], [ [ "cable", 4 ] ], [ [ "plut_cell", 1 ] ] ] }, - { - "result": "battery_compartment", - "type": "recipe", - "category": "CC_ELECTRONIC", - "subcategory": "CSC_ELECTRONIC_COMPONENTS", - "skill_used": "fabrication", - "difficulty": 3, - "skills_required": [ "electronics", 3 ], - "time": 15000, - "reversible": true, - "decomp_learn": 2, - "autolearn": true, - "book_learn": [ [ "manual_electronics", 2 ], [ "advanced_electronics", 2 ] ], - "using": [ [ "soldering_standard", 5 ] ], - "qualities": [ { "id": "SCREW", "level": 1 } ], - "components": [ [ [ "scrap", 4 ] ], [ [ "cable", 5 ] ] ] - }, { "result": "battery_ups", "type": "recipe", @@ -83,5 +66,88 @@ "using": [ [ "soldering_standard", 5 ] ], "qualities": [ { "id": "SCREW", "level": 1 } ], "components": [ [ [ "power_supply", 1 ] ], [ [ "scrap", 4 ] ], [ [ "cable", 10 ] ] ] + }, + { + "result": "magazine_battery_light_mod", + "type": "recipe", + "category": "CC_ELECTRONIC", + "subcategory": "CSC_ELECTRONIC_COMPONENTS", + "skill_used": "fabrication", + "difficulty": 3, + "skills_required": [ "electronics", 3 ], + "time": 15000, + "reversible": true, + "decomp_learn": 2, + "autolearn": true, + "book_learn": [ [ "manual_electronics", 2 ], [ "advanced_electronics", 2 ] ], + "using": [ [ "soldering_standard", 5 ] ], + "qualities": [ { "id": "SCREW", "level": 1 } ], + "components": [ [ [ "scrap", 4 ] ], [ [ "cable", 5 ] ] ] + }, + { + "result": "magazine_battery_medium_mod", + "type": "recipe", + "category": "CC_ELECTRONIC", + "subcategory": "CSC_ELECTRONIC_COMPONENTS", + "skill_used": "fabrication", + "difficulty": 3, + "skills_required": [ "electronics", 3 ], + "time": 25000, + "reversible": true, + "decomp_learn": 2, + "autolearn": true, + "book_learn": [ [ "manual_electronics", 2 ], [ "advanced_electronics", 2 ] ], + "using": [ [ "soldering_standard", 10 ] ], + "qualities": [ { "id": "SCREW", "level": 1 } ], + "components": [ [ [ "scrap", 6 ] ], [ [ "cable", 8 ] ] ] + }, + { + "result": "magazine_battery_heavy_mod", + "type": "recipe", + "category": "CC_ELECTRONIC", + "subcategory": "CSC_ELECTRONIC_COMPONENTS", + "skill_used": "fabrication", + "difficulty": 3, + "skills_required": [ "electronics", 3 ], + "time": 40000, + "reversible": true, + "decomp_learn": 2, + "autolearn": true, + "book_learn": [ [ "manual_electronics", 2 ], [ "advanced_electronics", 2 ] ], + "using": [ [ "soldering_standard", 15 ] ], + "qualities": [ { "id": "SCREW", "level": 1 } ], + "components": [ [ [ "scrap", 8 ] ], [ [ "cable", 10 ] ] ] + }, + { + "type": "recipe", + "result": "medium_battery_cell", + "category": "CC_ELECTRONIC", + "subcategory": "CSC_ELECTRONIC_PARTS", + "skill_used": "electronics", + "skills_required": [ "fabrication", 1 ], + "difficulty": 3, + "time": 15000, + "reversible": true, + "decomp_learn": 3, + "book_learn": [ [ "manual_electronics", 2 ], [ "mag_electronics", 2 ] ], + "using": [ [ "soldering_standard", 10 ] ], + "qualities": [ { "id": "SCREW", "level": 1 } ], + "components": [ [ [ "light_battery_cell", 5 ] ], [ [ "scrap", 4 ] ], [ [ "cable", 5 ] ] ] + }, + { + "type": "recipe", + "result": "heavy_battery_cell", + "category": "CC_ELECTRONIC", + "subcategory": "CSC_ELECTRONIC_PARTS", + "skill_used": "electronics", + "skills_required": [ "fabrication", 1 ], + "difficulty": 3, + "time": 20000, + "reversible": true, + "decomp_learn": 3, + "book_learn": [ [ "manual_electronics", 2 ], [ "mag_electronics", 2 ] ], + "using": [ [ "soldering_standard", 10 ] ], + "qualities": [ { "id": "SCREW", "level": 1 } ], + "components": [ [ [ "medium_battery_cell", 2 ] ], [ [ "scrap", 4 ] ], [ [ "cable", 5 ] ] ] } ] diff --git a/data/json/recipes/recipe_deconstruction.json b/data/json/recipes/recipe_deconstruction.json index 892a2b1154954..552d9a61f331b 100644 --- a/data/json/recipes/recipe_deconstruction.json +++ b/data/json/recipes/recipe_deconstruction.json @@ -1306,7 +1306,7 @@ [ [ "gloves_tactical", 1 ] ], [ [ "gloves_rubber", 1 ] ], [ [ "fire_gauntlets", 1 ] ], - [ [ "battery", 100 ] ], + [ [ "light_plus_battery_cell", 1 ] ], [ [ "flashlight", 1 ] ], [ [ "lighter", 1 ] ], [ [ "pockknife", 1 ] ], @@ -1404,7 +1404,7 @@ [ [ "l_long_45", 1 ] ], [ [ "l_enforcer_45", 1 ] ], [ [ "small_repairkit", 1 ] ], - [ [ "battery", 300 ] ], + [ [ "light_battery_cell", 3 ] ], [ [ "manual_gun", 1 ] ], [ [ "holster", 1 ] ] ] @@ -1452,14 +1452,6 @@ "time": 100, "components": [ [ [ "pilot_light", 1 ] ], [ [ "plastic_chunk", 1 ] ] ] }, - { - "result": "lightstrip_dead", - "type": "uncraft", - "skill_used": "electronics", - "time": 1000, - "qualities": [ { "id": "CUT", "level": 1 } ], - "components": [ [ [ "amplifier", 1 ] ], [ [ "e_scrap", 1 ] ] ] - }, { "result": "locket", "type": "uncraft", @@ -1740,7 +1732,7 @@ "result": "radio_car_box", "type": "uncraft", "time": 500, - "components": [ [ [ "radio_car", 1 ] ], [ [ "radiocontrol", 1 ] ], [ [ "battery", 200 ] ] ] + "components": [ [ [ "radio_car", 1 ] ], [ [ "radiocontrol", 1 ] ], [ [ "light_battery_cell", 2 ] ] ] }, { "result": "radiocontrol", @@ -2080,7 +2072,7 @@ "type": "uncraft", "time": 500, "qualities": [ { "id": "SCREW", "level": 1 } ], - "components": [ [ [ "plastic_chunk", 1 ] ], [ [ "processor", 1 ] ], [ [ "battery", 20 ] ] ] + "components": [ [ [ "plastic_chunk", 1 ] ], [ [ "processor", 1 ] ], [ [ "light_minus_battery_cell", 1 ] ] ] }, { "result": "years_old_newspaper", diff --git a/data/json/recipes/recipe_electronics.json b/data/json/recipes/recipe_electronics.json index cad9b64c52b8d..e42db6e3f6a3b 100644 --- a/data/json/recipes/recipe_electronics.json +++ b/data/json/recipes/recipe_electronics.json @@ -205,27 +205,6 @@ "qualities": [ { "id": "SCREW", "level": 1 } ], "components": [ [ [ "cable", 8 ] ], [ [ "plastic_chunk", 2 ] ], [ [ "circuit", 2 ] ], [ [ "e_scrap", 2 ] ], [ [ "amplifier", 1 ] ] ] }, - { - "type": "recipe", - "result": "lightstrip_dead", - "category": "CC_ELECTRONIC", - "subcategory": "CSC_ELECTRONIC_LIGHTING", - "skill_used": "electronics", - "difficulty": 1, - "time": 10000, - "book_learn": [ [ "manual_electronics", 1 ], [ "mag_electronics", 1 ] ], - "components": [ [ [ "amplifier", 1 ] ], [ [ "cable", 5 ] ], [ [ "e_scrap", 1 ] ] ] - }, - { - "type": "recipe", - "result": "lightstrip_inactive", - "category": "CC_ELECTRONIC", - "subcategory": "CSC_ELECTRONIC_LIGHTING", - "skill_used": "electronics", - "time": 1000, - "flags": [ "BLIND_EASY" ], - "components": [ [ [ "lightstrip_dead", 1 ] ], [ [ "battery", 15 ] ] ] - }, { "type": "recipe", "result": "sheet_metal_lit", @@ -265,7 +244,7 @@ [ "bottle_plastic", 1 ], [ "bottle_plastic_small", 1 ] ], - [ [ "lightstrip_dead", 1 ], [ "light_bulb", 1 ] ], + [ [ "lightstrip_inactive", 1 ], [ "light_bulb", 1 ] ], [ [ "cable", 10 ] ] ] }, @@ -284,7 +263,7 @@ "components": [ [ [ "amplifier", 4 ] ], [ [ "steel_chunk", 2 ], [ "scrap", 6 ] ], - [ [ "lightstrip_dead", 4 ], [ "light_bulb", 4 ] ], + [ [ "lightstrip_inactive", 4 ], [ "light_bulb", 4 ] ], [ [ "cable", 10 ] ] ] }, @@ -303,7 +282,7 @@ "components": [ [ [ "amplifier", 4 ] ], [ [ "steel_chunk", 2 ], [ "scrap", 6 ] ], - [ [ "lightstrip_dead", 4 ], [ "light_bulb", 4 ] ], + [ [ "lightstrip_inactive", 4 ], [ "light_bulb", 4 ] ], [ [ "cable", 10 ] ] ] }, @@ -322,7 +301,7 @@ "components": [ [ [ "amplifier", 2 ] ], [ [ "plastic_chunk", 2 ], [ "scrap", 3 ] ], - [ [ "lightstrip_dead", 2 ], [ "light_bulb", 2 ] ], + [ [ "lightstrip_inactive", 2 ], [ "light_bulb", 2 ] ], [ [ "cable", 10 ] ] ] }, @@ -341,7 +320,7 @@ "components": [ [ [ "amplifier", 3 ] ], [ [ "plastic_chunk", 3 ], [ "scrap", 4 ] ], - [ [ "lightstrip_dead", 3 ], [ "light_bulb", 3 ] ], + [ [ "lightstrip_inactive", 3 ], [ "light_bulb", 3 ] ], [ [ "cable", 12 ] ] ] }, @@ -767,7 +746,7 @@ "time": 50000, "reversible": true, "decomp_learn": 6, - "book_learn": [ [ "textbook_mechanics", 8 ], [ "textbook_electronics", 7 ], [ "advanced_electronics", 7 ], [ "textbook_robots", 6 ] ], + "book_learn": [ [ "textbook_mechanics", 7 ], [ "textbook_electronics", 6 ], [ "advanced_electronics", 6 ], [ "textbook_robots", 5 ] ], "using": [ [ "soldering_standard", 35 ] ], "qualities": [ { "id": "SCREW", "level": 1 } ], "components": [ [ [ "power_supply", 2 ] ], [ [ "processor", 2 ] ], [ [ "scrap", 5 ] ], [ [ "cable", 8 ] ] ] @@ -1614,7 +1593,13 @@ "reversible": true, "autolearn": true, "qualities": [ { "id": "SCREW", "level": 1 } ], - "components": [ [ [ "antenna", 1 ] ], [ [ "pilot_light", 1 ] ], [ [ "battery", 10 ] ], [ [ "amplifier", 1 ] ], [ [ "cable", 2 ] ] ] + "components": [ + [ [ "antenna", 1 ] ], + [ [ "pilot_light", 1 ] ], + [ [ "light_minus_battery_cell", 1 ] ], + [ [ "amplifier", 1 ] ], + [ [ "cable", 2 ] ] + ] }, { "type": "recipe", diff --git a/data/json/recipes/recipe_medsandchemicals.json b/data/json/recipes/recipe_medsandchemicals.json index 9f58f29fc5fe4..6fb41f93a84ee 100644 --- a/data/json/recipes/recipe_medsandchemicals.json +++ b/data/json/recipes/recipe_medsandchemicals.json @@ -57,7 +57,17 @@ "time": 5000, "autolearn": true, "qualities": [ { "id": "SCREW", "level": 1 } ], - "components": [ [ [ "battery", 125 ] ] ] + "components": [ + [ + [ "light_minus_battery_cell", 20 ], + [ "light_battery_cell", 10 ], + [ "light_plus_battery_cell", 5 ], + [ "medium_battery_cell", 2 ], + [ "medium_plus_battery_cell", 2 ], + [ "heavy_battery_cell", 1 ], + [ "heavy_plus_battery_cell", 1 ] + ] + ] }, { "type": "recipe", diff --git a/data/json/recipes/recipe_weapon.json b/data/json/recipes/recipe_weapon.json index 4c09957142d4e..3acb18242dfe6 100644 --- a/data/json/recipes/recipe_weapon.json +++ b/data/json/recipes/recipe_weapon.json @@ -1146,7 +1146,7 @@ { "id": "SCREW", "level": 1 }, { "id": "WRENCH", "level": 1 } ], - "components": [ [ [ "elec_chainsaw_off", 1 ] ], [ [ "battery_compartment", 1 ] ], [ [ "steel_chunk", 3 ], [ "scrap", 9 ] ] ] + "components": [ [ [ "elec_chainsaw_off", 1 ] ], [ [ "steel_chunk", 3 ], [ "scrap", 9 ] ] ] }, { "type": "recipe", @@ -1405,7 +1405,7 @@ [ [ "power_supply", 1 ] ], [ [ "lens", 1 ], [ "lens_small", 1 ] ], [ [ "lens", 1 ], [ "lens_small", 1 ] ], - [ [ "battery", 100 ], [ "plut_cell", 1 ] ], + [ [ "light_battery_cell", 1 ], [ "plut_cell", 1 ] ], [ [ "scrap", 1 ], [ "can_drink_unsealed", 1 ], @@ -1496,7 +1496,7 @@ [ [ "power_supply", 1 ] ], [ [ "lens", 1 ], [ "lens_small", 1 ] ], [ [ "lens", 1 ], [ "lens_small", 1 ] ], - [ [ "battery", 100 ], [ "plut_cell", 1 ] ], + [ [ "light_battery_cell", 1 ], [ "plut_cell", 1 ] ], [ [ "scrap", 1 ], [ "can_drink_unsealed", 1 ], @@ -2942,7 +2942,7 @@ "book_learn": [ [ "manual_launcher", 7 ] ], "using": [ [ "welding_standard", 3 ] ], "qualities": [ { "id": "HAMMER", "level": 3 }, { "id": "SAW_M", "level": 1 } ], - "components": [ [ [ "sheet_metal", 2 ] ], [ [ "pilot_light", 2 ] ], [ [ "battery", 200 ] ], [ [ "processor", 2 ] ] ] + "components": [ [ [ "sheet_metal", 2 ] ], [ [ "pilot_light", 2 ] ], [ [ "light_battery_cell", 2 ] ], [ [ "processor", 2 ] ] ] }, { "type": "recipe", diff --git a/data/json/vehicles/helicopters.json b/data/json/vehicles/helicopters.json index 937759518aa68..8108b7df1e062 100644 --- a/data/json/vehicles/helicopters.json +++ b/data/json/vehicles/helicopters.json @@ -173,7 +173,7 @@ { "x": -1, "y": -1, "chance": 5, "items": [ "mre_hotdog_box" ] }, { "x": -1, "y": -1, "chance": 5, "items": [ "mre_chicken_box" ] }, { "x": -1, "y": -1, "chance": 10, "items": [ "canteen" ] }, - { "x": -1, "y": -1, "chance": 10, "items": [ "battery" ] }, + { "x": -1, "y": -1, "chance": 10, "items": [ "light_plus_battery_cell" ] }, { "x": -1, "y": -1, "chance": 10, "items": [ "1st_aid" ] }, { "x": -1, "y": -1, "chance": 10, "items": [ "mag_fieldrepair" ] }, { "x": -1, "y": -1, "chance": 15, "items": [ "e_scrap" ] }, @@ -314,7 +314,7 @@ { "x": -1, "y": -1, "chance": 7, "items": [ "mre_hotdog_box" ] }, { "x": -1, "y": -1, "chance": 7, "items": [ "mre_chicken_box" ] }, { "x": -1, "y": -1, "chance": 10, "items": [ "canteen" ] }, - { "x": -1, "y": -1, "chance": 10, "items": [ "battery" ] }, + { "x": -1, "y": -1, "chance": 10, "items": [ "light_plus_battery_cell" ] }, { "x": -1, "y": -1, "chance": 10, "items": [ "1st_aid" ] }, { "x": -1, "y": -1, "chance": 7, "items": [ "mag_fieldrepair" ] }, { "x": -1, "y": -1, "chance": 15, "items": [ "e_scrap" ] }, @@ -456,7 +456,7 @@ { "x": -1, "y": 1, "chance": 7, "items": [ "mre_hotdog_box" ] }, { "x": -1, "y": 1, "chance": 7, "items": [ "mre_chicken_box" ] }, { "x": -1, "y": 1, "chance": 10, "items": [ "canteen" ] }, - { "x": -1, "y": 1, "chance": 10, "items": [ "battery" ] }, + { "x": -1, "y": 1, "chance": 10, "items": [ "light_plus_battery_cell" ] }, { "x": -1, "y": 1, "chance": 10, "items": [ "1st_aid" ] }, { "x": -1, "y": 1, "chance": 7, "items": [ "mag_fieldrepair" ] }, { "x": -1, "y": 1, "chance": 15, "items": [ "e_scrap" ] }, diff --git a/data/mods/Aftershock/items/afs_armor.json b/data/mods/Aftershock/items/afs_armor.json index 6c323dbf19558..2b0f484ba6ef7 100644 --- a/data/mods/Aftershock/items/afs_armor.json +++ b/data/mods/Aftershock/items/afs_armor.json @@ -126,7 +126,8 @@ "need_charges_msg": "The helmet's batteries are dead." }, "flags": [ "WATERPROOF", "FLASH_PROTECTION", "ONLY_ONE", "STURDY" ], - "looks_like": "depowered_helmet" + "looks_like": "depowered_helmet", + "magazines": [ [ "battery", [ "light_battery_cell", "light_minus_battery_cell", "light_plus_battery_cell" ] ] ] }, { "id": "afs_hev_helmet_on", @@ -138,7 +139,8 @@ "turns_per_charge": 20, "use_action": { "menu_text": "Turn off", "type": "transform", "msg": "The %s flicks off.", "target": "afs_hev_helmet" }, "flags": [ "LIGHT_500", "WATERPROOF", "FLASH_PROTECTION", "ONLY_ONE", "STURDY" ], - "looks_like": "depowered_helmet" + "looks_like": "depowered_helmet", + "magazines": [ [ "battery", [ "light_battery_cell", "light_minus_battery_cell", "light_plus_battery_cell" ] ] ] }, { "id": "afs_quilt", diff --git a/data/mods/Aftershock/items/afs_weapons.json b/data/mods/Aftershock/items/afs_weapons.json index 32b8e0cb302c8..42edb10dfaa7f 100644 --- a/data/mods/Aftershock/items/afs_weapons.json +++ b/data/mods/Aftershock/items/afs_weapons.json @@ -12,7 +12,6 @@ "symbol": "[", "color": "gray", "ammo": "battery", - "max_charges": 50, "charges_per_use": 1, "use_action": { "menu_text": "Activate", @@ -23,7 +22,8 @@ "need_charges_msg": "The energy saber is out of charge.", "active": true }, - "flags": [ "USE_UPS", "NO_UNLOAD", "NO_RELOAD" ] + "flags": [ "USE_UPS", "NO_UNLOAD", "NO_RELOAD" ], + "magazines": [ [ "battery", [ "light_battery_cell", "light_minus_battery_cell", "light_plus_battery_cell" ] ] ] }, { "id": "afs_energy_saber_on", @@ -38,7 +38,6 @@ "symbol": "[", "color": "light_blue", "ammo": "battery", - "max_charges": 50, "turns_per_charge": 10, "cutting": 40, "to_hit": 2, @@ -50,7 +49,8 @@ "type": "transform", "target": "afs_energy_saber_off", "msg": "The blade dissipates into particles." - } + }, + "magazines": [ [ "battery", [ "light_battery_cell", "light_minus_battery_cell", "light_plus_battery_cell" ] ] ] }, { "id": "afs_hardlight_longbow", diff --git a/data/mods/Aftershock/recipes/afs__recipes.json b/data/mods/Aftershock/recipes/afs__recipes.json index dd3a73b8562e7..646279691bb8f 100644 --- a/data/mods/Aftershock/recipes/afs__recipes.json +++ b/data/mods/Aftershock/recipes/afs__recipes.json @@ -1,7 +1,7 @@ [ { "type": "recipe", - "result": "battery", + "result": "light_battery_cell", "category": "CC_ELECTRONIC", "subcategory": "CSC_ELECTRONIC_COMPONENTS", "skill_used": "electronics", @@ -53,7 +53,7 @@ "components": [ [ [ "canister_empty", 1 ] ], [ [ "plut_slurry", 10 ], [ "plut_slurry_dense", 5 ] ], [ [ "power_supply", 2 ] ] ] }, { - "result": "battery", + "result": "light_battery_cell", "id_suffix": "afs_plutonium_battery", "type": "recipe", "category": "CC_ELECTRONIC", @@ -190,7 +190,13 @@ "book_learn": [ [ "mag_electronics", 3 ], [ "manual_electronics", 2 ] ], "using": [ [ "soldering_standard", 10 ] ], "qualities": [ { "id": "SCREW_FINE", "level": 1 } ], - "components": [ [ [ "plastic_chunk", 1 ] ], [ [ "battery", 25 ] ], [ [ "cable", 5 ] ], [ [ "circuit", 1 ] ], [ [ "scrap", 1 ] ] ] + "components": [ + [ [ "plastic_chunk", 1 ] ], + [ [ "light_minus_battery_cell", 1 ] ], + [ [ "cable", 5 ] ], + [ [ "circuit", 1 ] ], + [ [ "scrap", 1 ] ] + ] }, { "type": "recipe", diff --git a/data/mods/Battery_Migration/items/batt_mag.json b/data/mods/Battery_Migration/items/batt_mag.json new file mode 100644 index 0000000000000..2ac3494214a91 --- /dev/null +++ b/data/mods/Battery_Migration/items/batt_mag.json @@ -0,0 +1,128 @@ +[ + { + "id": "light_minus_battery_cell", + "type": "AMMO", + "name": "ultra-light battery cell", + "name_plural": "ultra-light battery cells", + "description": "This is a light battery cell designed for small size over everything else. It retains its universal compatibility, though.", + "weight": 25, + "volume": "30ml", + "price": 1500, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "count": 50, + "capacity": 50, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "RECHARGE" ] + }, + { + "id": "light_battery_cell", + "type": "AMMO", + "name": "light battery cell", + "name_plural": "light battery cells", + "description": "This is a light battery cell, universally compatible with all kinds of small devices.", + "weight": 50, + "volume": "75ml", + "price": 3500, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "count": 100, + "capacity": 100, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "RECHARGE" ] + }, + { + "id": "light_plus_battery_cell", + "type": "AMMO", + "name": "light battery cell (high-capacity)", + "name_plural": "light battery cells (high-capacity)", + "description": "This is a high-capacity light battery cell, universally compatible with all kinds of personal electronic devices.", + "weight": 75, + "volume": "115ml", + "price": 5000, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "count": 150, + "capacity": 150, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "RECHARGE" ] + }, + { + "id": "medium_battery_cell", + "type": "AMMO", + "name": "medium battery cell", + "name_plural": "light battery cells", + "description": "This is a medium battery cell, universally compatible with all kinds of appliances and power tools.", + "weight": 250, + "volume": "375ml", + "price": 10000, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "count": 500, + "capacity": 500, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "RECHARGE" ] + }, + { + "id": "medium_plus_battery_cell", + "type": "AMMO", + "name": "medium battery cell (high-capacity)", + "name_plural": "medium battery cells (high-capacity)", + "description": "This is a high-capacity medium battery cell, universally compatible with all kinds of appliances and power tools.", + "weight": 350, + "volume": "450ml", + "price": 12500, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "count": 600, + "capacity": 600, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "RECHARGE" ] + }, + { + "id": "heavy_battery_cell", + "type": "AMMO", + "name": "heavy battery cell", + "name_plural": "heavy battery cells", + "description": "This is a heavy battery cell, universally compatible with all kinds of industrial-grade equipment and large tools.", + "weight": 250, + "volume": "750ml", + "price": 10000, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "count": 1000, + "capacity": 1000, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "RECHARGE" ] + }, + { + "id": "heavy_plus_battery_cell", + "type": "AMMO", + "name": "heavy battery cell (high-capacity)", + "name_plural": "heavy battery cells (high-capacity)", + "description": "This is a high-capacity heavy battery cell, universally compatible with all kinds of industrial-grade equipment and large tools.", + "weight": 350, + "volume": "1000ml", + "price": 12500, + "material": [ "iron" ], + "symbol": "=", + "color": "yellow", + "ammo_type": "battery", + "count": 1250, + "capacity": 1250, + "looks_like": "battery", + "flags": [ "NO_SALVAGE", "RECHARGE" ] + } +] diff --git a/data/mods/Battery_Migration/modinfo.json b/data/mods/Battery_Migration/modinfo.json new file mode 100644 index 0000000000000..266eef9e8f022 --- /dev/null +++ b/data/mods/Battery_Migration/modinfo.json @@ -0,0 +1,12 @@ +[ + { + "type": "MOD_INFO", + "ident": "Battery_Overhaul_Legacy_Mode", + "name": "Battery Migration for Existing Games", + "authors": [ "Inglonias" ], + "maintainers": [ "Inglonias" ], + "description": "Allows you to reload and unload battery cells with legacy batteries.", + "category": "rebalance", + "dependencies": [ "dda" ] + } +] diff --git a/data/mods/Craft_Gunpowder/cgp_recipes.json b/data/mods/Craft_Gunpowder/cgp_recipes.json index 52248f8d335d0..21503e865f594 100644 --- a/data/mods/Craft_Gunpowder/cgp_recipes.json +++ b/data/mods/Craft_Gunpowder/cgp_recipes.json @@ -350,7 +350,7 @@ [ [ "plastic_chunk", 2 ] ], [ [ "amplifier", 1 ] ], [ [ "power_supply", 1 ] ], - [ [ "battery", 100 ], [ "plut_cell", 1 ] ], + [ [ "light_battery_cell", 1 ], [ "plut_cell", 1 ] ], [ [ "silver_small", 10 ] ], [ [ "gold_small", 10 ] ], [ [ "chem_aluminium_powder", 10 ] ], diff --git a/data/mods/CrazyCataclysm/crazy_aperturepotato.json b/data/mods/CrazyCataclysm/crazy_aperturepotato.json index f613129bdbe92..970a0d70c1530 100644 --- a/data/mods/CrazyCataclysm/crazy_aperturepotato.json +++ b/data/mods/CrazyCataclysm/crazy_aperturepotato.json @@ -9,7 +9,13 @@ "time": 11000, "book_learn": [ [ "textbook_robots", 4 ] ], "qualities": [ { "id": "SCREW", "level": 1 } ], - "components": [ [ [ "circuit", 1 ] ], [ [ "e_scrap", 3 ] ], [ [ "cable", 5 ] ], [ [ "battery", 1 ] ], [ [ "potato", 1 ] ] ] + "components": [ + [ [ "circuit", 1 ] ], + [ [ "e_scrap", 3 ] ], + [ [ "cable", 5 ] ], + [ [ "light_minus_battery_cell", 1 ] ], + [ [ "potato", 1 ] ] + ] }, { "id": "aperture_potato", diff --git a/data/mods/Salvaged_Robots/items.json b/data/mods/Salvaged_Robots/items.json index e3234e8313e7d..cd7d6bdba5c47 100644 --- a/data/mods/Salvaged_Robots/items.json +++ b/data/mods/Salvaged_Robots/items.json @@ -193,7 +193,8 @@ "move_cost": 1000 }, { "type": "place_monster", "monster_id": "mon_craftbuddy", "moves": 100 } - ] + ], + "magazines": [ [ "battery", [ "medium_battery_cell", "medium_plus_battery_cell" ] ] ] }, { "type": "TOOL", diff --git a/tests/player_helpers.cpp b/tests/player_helpers.cpp index a1b291c520732..661f9771fe870 100644 --- a/tests/player_helpers.cpp +++ b/tests/player_helpers.cpp @@ -22,7 +22,7 @@ int get_remaining_charges( const std::string &tool_id ) } ); int remaining_charges = 0; for( const item *instance : items ) { - remaining_charges += instance->charges; + remaining_charges += instance->ammo_remaining(); } return remaining_charges; }