Skip to content

Commit

Permalink
Appliance update. Extend crafting_pseudo_item. JSONize freezers and…
Browse files Browse the repository at this point in the history
… fridges. Update Freezers/Fridges to use `iexamine::transform` (#2172)

* Extend crafting_pseudo_item into array

Updates all relevant functions that depend on it.

Adds FOODCO kitchen buddy to construction list.

Gives vehicle welding rig construction a soldering iron to go with the welder.

* Linting

* Add freezers. Fix JSON

* Add freezer recipe

* Update mod files to new format

* Add glass fridge/freezer. Update load function

* Return to normal names

* Linting, add freezers/glass freezers

The future shall belong to the cockroaches.

* Recipe and group for glass fridge/freezer

* glass fridge recipe, more linting

* Incremental json fixes

* Weight update to  glass fridge/freezer weight

Based on tweaked components. Goal is a little trimming of weight

* Remove Const

I think this is what Clang wants from me?

* Fridge Tanks

Add documentation for flags and expansion of crafting_pseudo_items.

* Remove Fridge Tanks

* Quick fix to display and deconstruction

* floor lamp cleanup

They should be in appliances for one, and there's an extra f_floor_lamp in decorative that has no reason to exist.

* Fridges./Freezers use iexamine transform

Updated iexamine transform to use similar structure as iexamine fireplace.

* Update minifreezer

* Astyle

* Minor name fix

* TFLAG

* Update to accommodate extend/delete

With a JSON example in the welding rig

* Convert to reference.

There's no reason to initialise an entirely new variable.

* Update documentation

Vehicle parts have a separate enabled variable to decide if it's on or not, we don't have that for furniture, so FRIDGE and FREEZER flags can only be put on the active versions of said furniture.

* Update description text

Abstract furniture description updated to reflect abstract status.

* Simplify code
  • Loading branch information
KheirFerrum authored Nov 27, 2022
1 parent 82b62d6 commit 66a2164
Show file tree
Hide file tree
Showing 36 changed files with 817 additions and 336 deletions.
71 changes: 40 additions & 31 deletions data/json/construction.json
Original file line number Diff line number Diff line change
Expand Up @@ -4204,25 +4204,16 @@
},
{
"type": "construction",
"id": "constr_gridfridge_switch_off",
"group": "toggle_refrigerator_freezer",
"required_skills": [ ],
"id": "constr_gridglass_fridge",
"group": "install_glass_refrigerator",
"category": "FURN",
"time": "1 m",
"dark_craftable": true,
"pre_furniture": "f_fridge_on",
"post_furniture": "f_fridge_off"
},
{
"type": "construction",
"id": "constr_gridfridge_switch_on",
"group": "toggle_refrigerator_freezer",
"required_skills": [ ],
"category": "FURN",
"time": "1 m",
"dark_craftable": true,
"pre_furniture": "f_fridge_off",
"post_furniture": "f_fridge_on"
"time": "10 m",
"qualities": [ ],
"components": [ [ [ "glass_fridge", 1 ] ] ],
"pre_note": "Will only work if constructed in/on a building that has an electric grid with a mounted battery.",
"pre_special": "check_empty",
"post_furniture": "f_glass_fridge"
},
{
"type": "construction",
Expand All @@ -4239,25 +4230,29 @@
},
{
"type": "construction",
"id": "constr_gridminifreezer_switch_off",
"group": "toggle_refrigerator_freezer",
"required_skills": [ ],
"id": "constr_gridfreezer",
"group": "install_freezer",
"category": "FURN",
"time": "1 m",
"dark_craftable": true,
"pre_furniture": "f_minifreezer_on",
"post_furniture": "f_minifreezer_off"
"required_skills": [ ],
"time": "10 m",
"qualities": [ ],
"components": [ [ [ "fridge", 1 ] ] ],
"pre_note": "Will only work if constructed in/on a building that has an electric grid with a mounted battery.",
"pre_special": "check_empty",
"post_furniture": "f_freezer"
},
{
"type": "construction",
"id": "constr_gridminifreezer_switch_on",
"group": "toggle_refrigerator_freezer",
"required_skills": [ ],
"id": "constr_gridglass_freezer",
"group": "install_glass_freezer",
"category": "FURN",
"time": "1 m",
"dark_craftable": true,
"pre_furniture": "f_minifreezer_off",
"post_furniture": "f_minifreezer_on"
"required_skills": [ ],
"time": "10 m",
"qualities": [ ],
"components": [ [ [ "glass_freezer", 1 ] ] ],
"pre_note": "Will only work if constructed in/on a building that has an electric grid with a mounted battery.",
"pre_special": "check_empty",
"post_furniture": "f_glass_freezer"
},
{
"type": "construction",
Expand Down Expand Up @@ -4413,6 +4408,20 @@
"pre_special": "check_empty",
"post_furniture": "f_gridvac_sealer"
},
{
"type": "construction",
"id": "constr_gridcraftrig",
"group": "place_craftrig",
"category": "OTHER",
"required_skills": [ [ "electronics", 1 ] ],
"time": "30 m",
"qualities": [ [ { "id": "SCREW", "level": 1 } ] ],
"using": [ [ "soldering_standard", 20 ] ],
"components": [ [ [ "craftrig", 1 ] ], [ [ "cable", 5 ] ], [ [ "solder_wire", 10 ] ] ],
"pre_note": "Will only work if constructed in/on a building that has an electric grid with a mounted battery.",
"pre_special": "check_empty",
"post_furniture": "f_craftrig"
},
{
"type": "construction",
"id": "constr_gridrvkitchen",
Expand Down
25 changes: 20 additions & 5 deletions data/json/construction_group.json
Original file line number Diff line number Diff line change
Expand Up @@ -914,6 +914,16 @@
"id": "install_large_storage_battery",
"name": "Install Large Storage Battery"
},
{
"type": "construction_group",
"id": "install_freezer",
"name": "Install Freezer"
},
{
"type": "construction_group",
"id": "install_glass_freezer",
"name": "Install Glass Freezer"
},
{
"type": "construction_group",
"id": "install_minifreezer",
Expand All @@ -929,6 +939,11 @@
"id": "install_refrigerator",
"name": "Install Refrigerator"
},
{
"type": "construction_group",
"id": "install_glass_refrigerator",
"name": "Install Glass Refrigerator"
},
{
"type": "construction_group",
"id": "place_small_space_heater",
Expand Down Expand Up @@ -1104,6 +1119,11 @@
"id": "place_vaccuum_sealer",
"name": "Place Vaccuum Sealer"
},
{
"type": "construction_group",
"id": "place_craftrig",
"name": "Place FOODCO Kitchen Buddy"
},
{
"type": "construction_group",
"id": "place_water_mill",
Expand Down Expand Up @@ -1314,11 +1334,6 @@
"id": "tape_up_window",
"name": "Tape Up Window"
},
{
"type": "construction_group",
"id": "toggle_refrigerator_freezer",
"name": "Toggle Refrigerator/Freezer"
},
{
"type": "construction_group",
"id": "wax_floor",
Expand Down
Loading

0 comments on commit 66a2164

Please sign in to comment.