Skip to content

Commit

Permalink
Fixed items placed in condoms when spawned on zombie corpses (#73313)
Browse files Browse the repository at this point in the history
* Fixed items placed in condoms when spawned on zombie corpses

Changed wallet loot to use condom_sealed item, can be opened to get any existing condom in game. also added any_condom requirement list as to not require the player to open each condom prior to crafting.

* Update data/mods/innawood/recipes/chem_other.json

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Update containers.json

removed unused final row

* Update containers.json

* test

* Update data/json/ascii_art/containers/containers.json

* Update data/json/ascii_art/containers/containers.json

* Update wallets.json

A bruh moment typo.

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Anton Simakov <67688115+GuardianDll@users.noreply.github.com>
Co-authored-by: Maleclypse <54345792+Maleclypse@users.noreply.github.com>
  • Loading branch information
4 people authored May 10, 2024
1 parent dacd72a commit 58914c1
Show file tree
Hide file tree
Showing 8 changed files with 56 additions and 18 deletions.
9 changes: 9 additions & 0 deletions data/json/ascii_art/containers/containers.json
Original file line number Diff line number Diff line change
Expand Up @@ -2162,6 +2162,15 @@
"╚↔↔↔╝"
]
},
{
"type": "ascii_art",
"id": "condom_sealed",
"picture": [
"<color_dark_gray>╔↔↔↔╗",
"║( )║",
"╚↔↔↔╝"
]
},
{
"type": "ascii_art",
"id": "balloon",
Expand Down
26 changes: 13 additions & 13 deletions data/json/itemgroups/Clothing_Gear/wallets.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
{ "group": "banknotes", "prob": 80, "count": [ 1, 20 ] },
{ "group": "coins", "prob": 80, "count": [ 1, 10 ] },
{ "group": "discount_cards", "prob": 40, "count": [ 1, 3 ] },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "wallet_photo", "prob": 20 },
[ "scorecard", 20 ]
]
Expand All @@ -57,7 +57,7 @@
{ "group": "banknotes", "prob": 80, "count": [ 1, 20 ] },
{ "group": "coins", "prob": 80, "count": [ 1, 10 ] },
{ "group": "discount_cards", "prob": 40, "count": [ 1, 3 ] },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "wallet_photo", "prob": 20 },
[ "scorecard", 20 ]
]
Expand All @@ -73,7 +73,7 @@
{ "group": "banknotes", "prob": 80, "count": [ 1, 20 ] },
{ "group": "coins", "prob": 80, "count": [ 1, 10 ] },
{ "group": "discount_cards", "prob": 40, "count": [ 1, 3 ] },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "wallet_photo", "prob": 20 },
[ "scorecard", 20 ]
]
Expand All @@ -88,7 +88,7 @@
{ "group": "banknotes", "prob": 50, "count": [ 1, 20 ] },
{ "group": "coins", "prob": 80, "count": [ 1, 10 ] },
{ "group": "discount_cards", "prob": 10 },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "wallet_photo", "prob": 20 },
[ "scorecard", 40 ]
]
Expand All @@ -103,7 +103,7 @@
{ "group": "banknotes", "prob": 80, "count": [ 1, 20 ] },
{ "group": "coins", "prob": 80, "count": [ 1, 10 ] },
{ "group": "discount_cards", "prob": 60, "count": [ 2, 5 ] },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "money_hundred", "prob": 10, "count": [ 1, 5 ] },
{ "item": "wallet_photo", "prob": 20 },
[ "scorecard", 5 ]
Expand All @@ -121,7 +121,7 @@
{ "group": "banknotes", "prob": 80, "count": [ 1, 20 ] },
{ "group": "coins", "prob": 80, "count": [ 1, 10 ] },
{ "group": "discount_cards", "prob": 40, "count": [ 1, 3 ] },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "wallet_photo", "prob": 20 },
[ "scorecard", 20 ]
]
Expand All @@ -138,7 +138,7 @@
{ "group": "banknotes", "prob": 80, "count": [ 1, 20 ] },
{ "group": "coins", "prob": 80, "count": [ 1, 10 ] },
{ "group": "discount_cards", "prob": 40, "count": [ 1, 3 ] },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "wallet_photo", "prob": 20 },
[ "scorecard", 20 ]
]
Expand All @@ -157,7 +157,7 @@
{ "item": "id_science", "prob": 100 },
{ "item": "id_science_visitor_1", "prob": 100 },
{ "group": "discount_cards", "prob": 40, "count": [ 1, 3 ] },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "labmap", "prob": 30 },
{ "item": "wallet_photo", "prob": 20 },
[ "scorecard", 20 ]
Expand All @@ -177,7 +177,7 @@
{ "group": "banknotes", "prob": 80, "count": [ 1, 20 ] },
{ "group": "coins", "prob": 80, "count": [ 1, 10 ] },
{ "group": "discount_cards", "prob": 40, "count": [ 1, 3 ] },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "labmap", "prob": 20 },
{ "item": "wallet_photo", "prob": 20 },
[ "scorecard", 20 ]
Expand All @@ -197,7 +197,7 @@
{ "group": "banknotes", "prob": 80, "count": [ 1, 20 ] },
{ "group": "coins", "prob": 80, "count": [ 1, 10 ] },
{ "group": "discount_cards", "prob": 60, "count": [ 2, 5 ] },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "labmap", "prob": 20 },
{ "item": "wallet_photo", "prob": 20 },
[ "scorecard", 5 ]
Expand All @@ -215,7 +215,7 @@
{ "item": "id_science_visitor_1", "prob": 100 },
{ "group": "banknotes", "prob": 80, "count": [ 1, 10 ] },
{ "group": "discount_cards", "prob": 40, "count": [ 1, 3 ] },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "labmap", "prob": 20 },
{ "item": "wallet_photo", "prob": 30 },
[ "scorecard", 20 ]
Expand All @@ -233,7 +233,7 @@
{ "group": "banknotes", "prob": 80, "count": [ 1, 20 ] },
{ "group": "coins", "prob": 80, "count": [ 1, 10 ] },
{ "group": "discount_cards", "prob": 40, "count": [ 1, 3 ] },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "wallet_photo", "prob": 20 },
[ "scorecard", 20 ]
]
Expand All @@ -250,7 +250,7 @@
{ "group": "banknotes", "prob": 80, "count": [ 1, 20 ] },
{ "group": "coins", "prob": 80, "count": [ 1, 10 ] },
{ "group": "discount_cards", "prob": 40, "count": [ 1, 3 ] },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "wallet_photo", "prob": 20 },
[ "scorecard", 20 ]
]
Expand Down
17 changes: 17 additions & 0 deletions data/json/items/containers/containers.json
Original file line number Diff line number Diff line change
Expand Up @@ -3766,6 +3766,23 @@
"flags": [ "BANK_NOTE_SHAPED" ],
"properties": { "burst_when_filled": "75" }
},
{
"id": "condom_sealed",
"type": "GENERIC",
"looks_like": "condom",
"name": { "str": "sealed condom" },
"description": "A sealed condom wrapper, activate to open it.",
"ascii_picture": "condom_sealed",
"weight": "5 g",
"volume": "15 ml",
"price": "0 cent",
"price_postapoc": "25 cent",
"material": [ "plastic" ],
"symbol": ")",
"color": "white",
"use_action": { "menu_text": "open", "type": "transform", "target": "condom", "msg": "You rip open the wrapped condom." },
"flags": [ "BANK_NOTE_SHAPED" ]
},
{
"id": "balloon",
"type": "GENERIC",
Expand Down
8 changes: 7 additions & 1 deletion data/json/recipes/chem/other.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,13 @@
"components": [
[ [ "chem_acetone", 1 ], [ "chem_chloroform", 250 ], [ "ammonia_hydroxide", 1 ], [ "chem_toluene", 250 ] ],
[ [ "chem_ethanol", 10 ], [ "denat_alcohol", 10 ], [ "methed_alcohol", 10 ], [ "chem_methanol", 10 ] ],
[ [ "balloon", 3 ], [ "shredded_rubber", 20 ], [ "gloves_medical", 2 ], [ "latex", 2 ], [ "condom", 3 ] ]
[
[ "balloon", 3 ],
[ "shredded_rubber", 20 ],
[ "gloves_medical", 2 ],
[ "latex", 2 ],
[ "any_condom", 3, "LIST" ]
]
]
},
{
Expand Down
2 changes: 1 addition & 1 deletion data/json/recipes/other/medical.json
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@
[ "metal_funnel", 2 ]
],
[ [ "hose", 1 ] ],
[ [ "condom", 1 ], [ "balloon", 1 ] ]
[ [ "any_condom", 1, "LIST" ], [ "balloon", 1 ] ]
]
},
{
Expand Down
6 changes: 6 additions & 0 deletions data/json/requirements/materials.json
Original file line number Diff line number Diff line change
Expand Up @@ -640,5 +640,11 @@
[ "onyx", 1 ]
]
]
},
{
"id": "any_condom",
"type": "requirement",
"//": "Prevents having to open condoms before crafts",
"components": [ [ [ "condom", 1 ], [ "condom_sealed", 1 ] ] ]
}
]
2 changes: 1 addition & 1 deletion data/mods/MindOverMatter/items/clothing/wallets.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
{ "item": "id_science_visitor_phavian", "prob": 100 },
{ "item": "id_science_visitor_1", "prob": 15 },
{ "group": "discount_cards", "prob": 40, "count": [ 1, 3 ] },
{ "item": "condom", "prob": 10 },
{ "item": "condom_sealed", "prob": 10 },
{ "item": "labmap", "prob": 30 },
{ "item": "wallet_photo", "prob": 20 },
[ "scorecard", 20 ]
Expand Down
4 changes: 2 additions & 2 deletions data/mods/innawood/recipes/chem_other.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
[ [ "chem_ethanol", 10 ], [ "denat_alcohol", 10 ], [ "methed_alcohol", 10 ], [ "chem_methanol", 10 ] ],
[
[ "balloon", 2 ],
[ "condom", 2 ],
[ "any_condom", 2, "LIST" ],
[ "gloves_medical", 2 ],
[ "chunk_rubber", 1 ],
[ "latex", 2 ],
Expand Down Expand Up @@ -44,7 +44,7 @@
[ [ "chem_ethanol", 10 ], [ "denat_alcohol", 10 ], [ "methed_alcohol", 10 ], [ "chem_methanol", 10 ] ],
[
[ "balloon", 2 ],
[ "condom", 2 ],
[ "any_condom", 2, "LIST" ],
[ "gloves_medical", 2 ],
[ "chunk_rubber", 1 ],
[ "latex", 2 ],
Expand Down

0 comments on commit 58914c1

Please sign in to comment.