From 59eb28f4a7404d1ec2f4be1eaa387d4317a8a812 Mon Sep 17 00:00:00 2001 From: Lil Shining Man <56778776+LilShiningMan@users.noreply.github.com> Date: Sat, 9 Mar 2024 15:09:31 -0800 Subject: [PATCH] feat(content): residential personal items (#4312) * residential personal items add nested container for unique personal items to spawn in houses * Update residential_personal_items.json * updated palette symbol * Fix No Hope Why is there not just not one full override of `standard_domestic_palette` in No Hope but TWO of them!? --------- Co-authored-by: Chaosvolt --- data/json/mapgen/house/house_fence09.json | 2 +- .../nested/residential_personal_items.json | 60 +++++++++++++++++++ .../house_general_palette.json | 3 +- data/mods/No_Hope/Mapgen/office_doctor.json | 3 +- data/mods/No_Hope/palettes.json | 3 +- 5 files changed, 67 insertions(+), 4 deletions(-) create mode 100644 data/json/mapgen/nested/residential_personal_items.json diff --git a/data/json/mapgen/house/house_fence09.json b/data/json/mapgen/house/house_fence09.json index 6be1890e22c3..8738872eab56 100644 --- a/data/json/mapgen/house/house_fence09.json +++ b/data/json/mapgen/house/house_fence09.json @@ -126,7 +126,7 @@ ".............^.,,,,,....", "...######oo######oo##...", "...#wQ|8888B|d+ IIID#...", - "...#z |S___B|d+ #...", + "...#z |S___B|ɸ+ #...", "...#|+|t___||||b #...", "...oy |||+||!!| @@ o...", "...oy + ¤@@¤o...", diff --git a/data/json/mapgen/nested/residential_personal_items.json b/data/json/mapgen/nested/residential_personal_items.json new file mode 100644 index 000000000000..4c9ff653d484 --- /dev/null +++ b/data/json/mapgen/nested/residential_personal_items.json @@ -0,0 +1,60 @@ +[ + { + "type": "mapgen", + "method": "json", + "nested_mapgen_id": "NC_res_personal_items_1X1", + "//": "NEST CONTAINER - Items of interest or use to a specific person (hobbies, job-related, uniforms, tools, etc), meant to add personality. Should be able to fit in a closet or corner of a bedroom. This should be the nested chunk called by each individual house file. Global spawn rates for all houses that call this chunk can be managed by editing values below. ", + "object": { + "mapgensize": [ 1, 1 ], + "rows": [ "_" ], + "terrain": { "_": "t_null" }, + "place_nested": [ + { + "chunks": [ [ "null", 1 ], [ "res_personal_scuba_1X1", 5 ], [ "res_personal_elecgtr_1X1", 5 ] ], + "x": [ 0 ], + "y": [ 0 ] + } + ] + } + }, + { + "type": "mapgen", + "method": "json", + "nested_mapgen_id": "res_personal_scuba_1X1", + "object": { + "mapgensize": [ 1, 1 ], + "rows": [ "x" ], + "terrain": { "x": "t_null" }, + "furniture": { "x": "f_cardboard_box" }, + "place_loot": [ + { "item": "wetsuit", "x": 0, "y": 0 }, + { "item": "small_scuba_tank", "x": 0, "y": 0 }, + { "item": "dive_bag", "x": 0, "y": 0 }, + { "item": "swim_fins", "x": 0, "y": 0 }, + { "item": "diving_watch", "x": 0, "y": 0, "chance": 5 }, + { "item": "wetsuit_hood", "x": 0, "y": 0, "chance": 5 }, + { "item": "wetsuit_spring", "x": 0, "y": 0, "chance": 5 }, + { "item": "wetsuit_gloves", "x": 0, "y": 0, "chance": 5 }, + { "item": "wetsuit_booties", "x": 0, "y": 0, "chance": 5 }, + { "item": "rebreather", "x": 0, "y": 0, "chance": 5 }, + { "item": "rebreather_filter", "x": 0, "y": 0, "chance": 5 } + ] + } + }, + { + "type": "mapgen", + "method": "json", + "nested_mapgen_id": "res_personal_elecgtr_1X1", + "object": { + "mapgensize": [ 1, 1 ], + "rows": [ "x" ], + "terrain": { "x": "t_null" }, + "furniture": { "x": "f_speaker_cabinet" }, + "place_loot": [ + { "item": "cable_instrument", "x": 0, "y": 0, "repeat": [ 2, 3 ] }, + { "item": "amplifier_head", "x": 0, "y": 0 }, + { "item": "guitar_electric", "x": 0, "y": 0 } + ] + } + } +] diff --git a/data/json/mapgen_palettes/house_general_palette.json b/data/json/mapgen_palettes/house_general_palette.json index b2f331652d2f..a4747ec7b266 100644 --- a/data/json/mapgen_palettes/house_general_palette.json +++ b/data/json/mapgen_palettes/house_general_palette.json @@ -218,7 +218,8 @@ { "item": "stash_drugs", "chance": 1 }, { "item": "maps", "chance": 7 } ] - } + }, + "nested": { "ɸ": { "chunks": [ "NC_res_personal_items_1X1" ] } } }, { "type": "palette", diff --git a/data/mods/No_Hope/Mapgen/office_doctor.json b/data/mods/No_Hope/Mapgen/office_doctor.json index 0a5454b4db57..974a6db02a65 100644 --- a/data/mods/No_Hope/Mapgen/office_doctor.json +++ b/data/mods/No_Hope/Mapgen/office_doctor.json @@ -218,7 +218,8 @@ { "item": "toy_store", "chance": 60, "repeat": [ 1, 2 ] }, { "item": "allsporting", "chance": 5 } ] - } + }, + "nested": { "ɸ": { "chunks": [ "NC_res_personal_items_1X1" ] } } }, { "type": "palette", diff --git a/data/mods/No_Hope/palettes.json b/data/mods/No_Hope/palettes.json index 0a5454b4db57..974a6db02a65 100644 --- a/data/mods/No_Hope/palettes.json +++ b/data/mods/No_Hope/palettes.json @@ -218,7 +218,8 @@ { "item": "toy_store", "chance": 60, "repeat": [ 1, 2 ] }, { "item": "allsporting", "chance": 5 } ] - } + }, + "nested": { "ɸ": { "chunks": [ "NC_res_personal_items_1X1" ] } } }, { "type": "palette",