Skip to content

Commit

Permalink
Rework the trash itemgroups: part 1 (#79855)
Browse files Browse the repository at this point in the history
* Create trash.json

* Itemgroups

* oa_custom_trash
  • Loading branch information
Milopetilo authored Feb 26, 2025
1 parent 1d1839b commit e0f1612
Show file tree
Hide file tree
Showing 11 changed files with 504 additions and 117 deletions.
2 changes: 1 addition & 1 deletion data/json/itemgroups/Clothing_Gear/gear_civilian.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
"type": "item_group",
"//": "Regular items for the homeless.",
"items": [
{ "group": "trash", "prob": 30 },
{ "group": "SUS_trash_floor", "prob": 30 },
{ "group": "donated_clothes", "prob": 25 },
{ "group": "gear_survival", "prob": 5 },
{ "group": "contraband", "prob": 20 },
Expand Down
30 changes: 2 additions & 28 deletions data/json/itemgroups/Locations_MapExtras/mansion.json
Original file line number Diff line number Diff line change
Expand Up @@ -858,27 +858,14 @@
"type": "item_group",
"subtype": "distribution",
"items": [
[ "cig_butt", 50 ],
[ "string_6", 50 ],
[ "wrapper", 50 ],
[ "wrapper_foil", 5 ],
[ "shot_hull", 40 ],
[ "splinter", 40 ],
[ "sinew", 40 ],
[ "cotton_patchwork", 40 ],
[ "cup_plastic", 30 ],
[ "can_drink", 30 ],
[ "bottle_plastic", 30 ],
[ "bag_plastic", 30 ],
{ "item": "rolling_paper", "prob": 20, "charges": [ 1, 30 ] },
{ "item": "paper", "prob": 30, "count": [ 20, 50 ] },
{ "item": "cotton_patchwork", "prob": 20, "custom-flags": [ "FILTHY" ] },
{ "item": "flashlight", "prob": 20, "charges": [ 0, 300 ] },
[ "9mm_casing", 20 ],
[ "38_casing", 20 ],
[ "45_casing", 20 ],
[ "stick", 20 ],
[ "joint_roach", 10 ],
{ "group": "SUS_trash_floor", "prob": 5 },
{ "group": "corpse_mansion", "prob": 5 },
[ "survnote", 1 ],
{ "item": "inflatable_dragon", "prob": 1, "charges": [ 0, 56 ] },
Expand All @@ -891,26 +878,13 @@
"type": "item_group",
"subtype": "distribution",
"items": [
[ "string_6", 50 ],
[ "wrapper", 50 ],
[ "wrapper_foil", 5 ],
{ "item": "paper", "prob": 50, "count": [ 20, 50 ] },
[ "ceramic_shard", 40 ],
[ "shot_hull", 40 ],
[ "splinter", 40 ],
[ "sinew", 40 ],
[ "cotton_patchwork", 40 ],
[ "cup_plastic", 30 ],
[ "can_drink", 30 ],
[ "bottle_plastic", 30 ],
{ "item": "glass_shard", "prob": 30, "count": [ 1, 8 ] },
[ "bag_plastic", 30 ],
{ "item": "cotton_patchwork", "prob": 20, "custom-flags": [ "FILTHY" ] },
[ "9mm_casing", 20 ],
[ "38_casing", 20 ],
[ "45_casing", 20 ],
{ "group": "tinware", "prob": 20 },
[ "bone_tainted", 5 ],
{ "group": "SUS_trash_floor", "prob": 5 },
{ "group": "corpse_mansion", "prob": 5 },
{ "group": "writing_utensils", "prob": 10 }
]
Expand Down
485 changes: 485 additions & 0 deletions data/json/itemgroups/SUS/trash.json

Large diffs are not rendered by default.

18 changes: 4 additions & 14 deletions data/json/itemgroups/collections_domestic.json
Original file line number Diff line number Diff line change
Expand Up @@ -1383,7 +1383,7 @@
"type": "item_group",
"subtype": "distribution",
"items": [
{ "group": "trash", "prob": 100 },
{ "group": "SUS_trash_floor", "prob": 100 },
{ "group": "cleaning", "prob": 20 },
{ "group": "dishes_dining", "prob": 20 },
{ "group": "dishes_utility", "prob": 10 },
Expand Down Expand Up @@ -1454,25 +1454,15 @@
"subtype": "distribution",
"items": [
{ "group": "laundry", "prob": 10 },
{ "group": "trash_domestic", "prob": 7 },
{ "group": "SUS_trash_floor", "prob": 7 },
{ "group": "untidy_floor_clutter", "prob": 7 },
{ "group": "coins", "prob": 5 },
{
"collection": [ { "group": "trash_domestic", "prob": 75, "count": [ 3, 6 ] }, { "item": "bag_garbage", "prob": 100 } ],
"collection": [ { "group": "SUS_trash_trashcan", "prob": 75, "count": [ 3, 6 ] }, { "item": "bag_garbage", "prob": 100 } ],
"prob": 2
},
{ "item": "string_6", "prob": 1 },
{ "item": "lighter", "prob": 1, "charges": [ 0, 10 ] },
{ "item": "cig_butt", "prob": 1 }
}
]
},
{
"id": "untidy_workbench_clutter",
"//": "Items you might find on the floor in a disorganized house.",
"type": "item_group",
"subtype": "distribution",
"items": [ { "item": "splinter", "prob": 10 }, { "item": "nail", "prob": 10, "charges": [ 1, 3 ] } ]
},
{
"type": "item_group",
"id": "iodine_bottle_plastic_pill_supplement_1_10",
Expand Down
62 changes: 0 additions & 62 deletions data/json/itemgroups/oa_shared_item_groups.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,68 +4,6 @@
"id": "oa_discarded_news",
"items": [ { "group": "newspaper", "prob": 60 }, [ "news_regional", 20 ], [ "mag_news", 20 ] ]
},
{
"type": "item_group",
"id": "oa_custom_trash",
"ammo": 50,
"magazine": 100,
"items": [
{ "item": "lighter", "prob": 50, "charges": [ 0, 10 ] },
{ "item": "matches", "prob": 50, "charges": [ 0, 20 ] },
{ "item": "ref_matches", "prob": 50, "charges": [ 0, 32 ] },
{ "prob": 20, "group": "cig_box_cigarette_1_5" },
[ "plastic_shopping_bag", 50 ],
[ "wrapper", 50 ],
[ "wrapper_foil", 5 ],
{ "item": "wrapper_foil_roll", "prob": 8 },
{ "prob": 2, "group": "meth_bag_zipper_1_6" },
{ "prob": 1, "group": "heroin_bag_zipper_1_4" },
[ "string_6", 10 ],
[ "chain", 20 ],
{ "item": "glass_shard", "prob": 30, "count": [ 1, 8 ] },
[ "ceramic_shard", 35 ],
[ "stick", 30 ],
[ "joint_roach", 20 ],
[ "pipe", 10 ],
[ "bag_plastic", 30 ],
[ "bottle_plastic", 30 ],
[ "bottle_plastic_small", 35 ],
[ "bag_canvas", 15 ],
[ "bag_canvas_small", 25 ],
[ "bottle_glass", 30 ],
[ "can_drink", 30 ],
[ "can_food", 30 ],
[ "box_small", 30 ],
[ "bubblewrap", 20 ],
[ "cig_butt", 70 ],
[ "syringe", 10 ],
[ "cotton_patchwork", 20 ],
[ "hairpin", 5 ],
[ "leather", 5 ],
[ "file", 15 ],
[ "fuel_tin", 10 ],
[ "jug_plastic", 10 ],
[ "spray_can", 20 ],
[ "jar_glass_sealed", 20 ],
[ "jar_3l_glass_sealed", 5 ],
[ "flyer", 40 ],
[ "talking_doll", 10 ],
{ "item": "marble", "prob": 20, "charges": [ 1, 20 ] },
[ "creepy_doll", 5 ],
[ "straw_doll", 5 ],
[ "razor_blade", 10 ],
[ "survnote", 5 ],
[ "eclipse_glasses", 5 ],
{ "group": "newspaper", "prob": 60 },
[ "news_regional", 15 ],
{ "item": "paper", "prob": 20, "count": [ 5, 15 ] },
{ "item": "cotton_patchwork", "prob": 35, "custom-flags": [ "FILTHY" ] },
[ "mask_dust", 10 ],
{ "item": "gum", "prob": 6, "count": [ 1, 10 ] },
{ "item": "caff_gum", "prob": 6, "count": [ 1, 10 ] },
{ "item": "nic_gum", "prob": 4, "count": [ 1, 10 ] }
]
},
{
"type": "item_group",
"id": "cig_box_cigarette_1_5",
Expand Down
4 changes: 2 additions & 2 deletions data/json/mapgen/cs_car_dealership.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,8 @@
],
"items": {
"s": { "item": "oa_discarded_news", "chance": 33 },
"c": { "item": "oa_custom_trash", "chance": 70 },
"D": { "item": "oa_custom_trash", "chance": 60 },
"c": { "item": "SUS_trash_trashcan_public", "chance": 70 },
"D": { "item": "SUS_trash_dumpster", "chance": 60 },
"d": { "item": "SUS_office_desk", "chance": 33 },
"L": { "item": "oa_ig_cd_lockers", "chance": 70, "repeat": [ 1, 4 ] },
"F": { "item": "SUS_fridge_breakroom", "chance": 90 }
Expand Down
10 changes: 5 additions & 5 deletions data/json/mapgen/cs_car_showroom.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,17 +69,17 @@
"vendingmachines": { "v": { "item_group": "vending_drink", "lootable": true }, "V": { "item_group": "vending_food", "lootable": true } },
"place_vehicles": [ { "vehicle": "oa_vg_cs_vehicles", "x": 16, "y": 8, "rotation": 270, "chance": 100, "status": 0, "fuel": 0 } ],
"items": {
"c": { "item": "oa_custom_trash", "chance": 70 },
"á": { "item": "oa_custom_trash", "chance": 70 },
"C": { "item": "oa_custom_trash", "chance": 70 },
"c": { "item": "SUS_trash_trashcan", "chance": 70 },
"á": { "item": "SUS_trash_trashcan", "chance": 70 },
"C": { "item": "SUS_trash_dumpster", "chance": 70 },
"d": { "item": "SUS_office_desk", "chance": 33 },
"L": { "item": "oa_ig_cs_lockers", "chance": 70, "repeat": [ 1, 4 ] },
"F": { "item": "SUS_fridge_breakroom", "chance": 90 },
"f": { "item": "SUS_office_filing_cabinet", "chance": 70 }
},
"place_items": [
{ "item": "oa_custom_trash", "chance": 80, "repeat": [ 2, 4 ], "x": 17, "y": 22 },
{ "item": "oa_custom_trash", "chance": 80, "repeat": [ 2, 4 ], "x": 18, "y": 22 },
{ "item": "SUS_trash_dumpster", "chance": 80, "repeat": [ 2, 4 ], "x": 17, "y": 22 },
{ "item": "SUS_trash_dumpster", "chance": 80, "repeat": [ 2, 4 ], "x": 18, "y": 22 },
{ "item": "fridgesnacks", "chance": 70, "repeat": [ 0, 4 ], "x": 3, "y": 4 }
],
"add": [ { "item": "microwave", "x": 4, "y": 4, "chance": 1 }, { "item": "coffeemaker", "x": 5, "y": 4, "chance": 1 } ],
Expand Down
2 changes: 1 addition & 1 deletion data/json/mapgen/cs_public_art_piece.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
],
"terrain": { " ": "t_region_groundcover_urban", "s": "t_sidewalk", "X": "t_pavement", "O": "t_concrete" },
"furniture": { "b": "f_bench", "c": "f_trashcan" },
"items": { "c": { "item": "oa_custom_trash", "chance": 30 }, "b": { "item": "oa_discarded_news", "chance": 5 } },
"items": { "c": { "item": "SUS_trash_trashcan", "chance": 30 }, "b": { "item": "oa_discarded_news", "chance": 5 } },
"item": { "X": { "item": "rock", "chance": 20 }, "O": { "item": "rock", "chance": 20 } }
}
}
Expand Down
2 changes: 1 addition & 1 deletion data/json/mapgen/ws_biker_dump.json
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@
"palettes": [ "regional_dump" ],
"furniture": { "H": "f_55gal_firebarrel" },
"items": {
"B": { "item": "oa_custom_trash", "chance": 15 },
"B": { "item": "SUS_trash_trashcan", "chance": 15 },
"1": { "item": "oa_ig_rd_electronic_trash", "chance": 10 },
"2": { "item": "trash", "chance": 10 },
"3": { "item": "oa_ig_rd_metal_trash", "chance": 10 },
Expand Down
2 changes: 1 addition & 1 deletion data/json/mapgen/ws_regional_dump.json
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@
"palettes": [ "regional_dump" ],
"items": {
".": { "item": "trash", "chance": 5 },
"B": { "item": "oa_custom_trash", "chance": 15 },
"B": { "item": "SUS_trash_trashcan", "chance": 15 },
"1": { "item": "oa_ig_rd_electronic_trash", "chance": 10 },
"2": { "item": "trash", "chance": 10 },
"3": { "item": "oa_ig_rd_metal_trash", "chance": 10 },
Expand Down
4 changes: 2 additions & 2 deletions data/json/mapgen_palettes/house_general_palette.json
Original file line number Diff line number Diff line change
Expand Up @@ -690,7 +690,7 @@
{ "item": "tools_common", "chance": 20, "repeat": [ 1, 2 ] },
{ "item": "hardware", "chance": 30, "repeat": [ 1, 2 ] },
{ "item": "cleaning", "chance": 10, "repeat": [ 1, 2 ] },
{ "item": "untidy_workbench_clutter", "chance": 33, "repeat": [ 2, 5 ] }
{ "item": "SUS_trash_hardware", "chance": 33, "repeat": [ 2, 5 ] }
],
"R": [
{ "item": "novels", "chance": 40, "repeat": [ 1, 3 ] },
Expand Down Expand Up @@ -809,7 +809,7 @@
{ "item": "tools_common", "chance": 20, "repeat": [ 1, 2 ] },
{ "item": "hardware", "chance": 30, "repeat": [ 1, 2 ] },
{ "item": "cleaning", "chance": 10, "repeat": [ 1, 2 ] },
{ "item": "untidy_workbench_clutter", "chance": 33, "repeat": [ 2, 5 ] }
{ "item": "SUS_trash_hardware", "chance": 33, "repeat": [ 2, 5 ] }
],
"R": [
{ "item": "novels", "chance": 40, "repeat": [ 1, 3 ] },
Expand Down

0 comments on commit e0f1612

Please sign in to comment.