Treat every mod's version of a material as the same material
Silver comes from Ice and Fire, Immersive Engineering, Occultism and Superb Warfare; steel from Mekanism, Immersive Engineering and Superb Warfare. Picking one provider meant the other mods' ingots were not recognised as that material at all - they simply could not be used. Each material now also accepts the c: common tag that every provider registers into, on top of the primary provider's own items, so any mod's silver ingot is just silver. 43 materials unify this way. No origin is recorded, because there is nothing to record: MIAPI stores only the material id on the item. The primary provider's item stays first in the ingredient list, so anywhere a single representative item is read back out it resolves to the default rather than to whichever variant was used. Tags are also the safe half of the pair - an unknown tag resolves to nothing while an unknown item id fails the whole material - which is why the material still lives in its primary provider's pack, where its icon and first ingredient are guaranteed to exist. MIAPI's own wood material mixes items and tags the same way. Create: The Air War ships no common tags, so its titanium is added to c:ingots/titanium with optional entries. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>modules-and-missing-materials
parent
90f1b76864
commit
5828bbfb01
28
README.md
28
README.md
|
|
@ -24,13 +24,27 @@ and a material whose ingredient item is missing fails to parse. So each source
|
|||
mod's materials are a separate built-in datapack, registered in
|
||||
`CMModular.java` only when that mod is present.
|
||||
|
||||
**Overlapping metals.** Several metals come from more than one mod - steel,
|
||||
lead and uranium from Mekanism and Immersive Engineering, silver from Ice and
|
||||
Fire and Immersive Engineering, titanium from both aerospace addons. Each one
|
||||
picks a single provider rather than accepting either, so the crafting screen
|
||||
shows one entry per metal instead of two identical-looking ones. Providers are
|
||||
Mekanism for steel/lead/uranium, Ice and Fire for silver, Cosmonautics for
|
||||
titanium; swapping one is a one-line change in `tools/materials.py`.
|
||||
**Identical materials are one material.** Several metals and gems come from
|
||||
more than one mod - silver from Ice and Fire, Immersive Engineering, Occultism
|
||||
and Superb Warfare, steel from Mekanism, Immersive Engineering and Superb
|
||||
Warfare, and so on. There is one entry per metal, and every provider's version
|
||||
feeds it: alongside the primary provider's own items each material also accepts
|
||||
the `c:` common tag that all of them register into. Any mod's silver ingot is
|
||||
just silver.
|
||||
|
||||
Nothing records where a stack came from, because there is nothing to record -
|
||||
MIAPI stores only the material id on the item, so a tool built from Immersive
|
||||
Engineering silver is indistinguishable from one built with Ice and Fire silver.
|
||||
The primary provider's item is listed first, so anywhere a single representative
|
||||
item is read back out - repair and deconstruct previews - it resolves to the
|
||||
default rather than to whichever variant was used. Primaries are Mekanism for
|
||||
steel/lead/uranium, Ice and Fire for silver, Cosmonautics for titanium; each is
|
||||
a one-line change in `tools/materials.py`.
|
||||
|
||||
The material still lives in its primary provider's pack, so its icon and its
|
||||
first ingredient always point at an item that exists. Create: The Air War is the
|
||||
one provider that ships no common tags, so `data/c/` adds its titanium to
|
||||
`c:ingots/titanium` with optional entries.
|
||||
|
||||
**Fire immunity.** Cinder essence grants immunity to fire, which is not an
|
||||
attribute the game has and not a property MIAPI offers. Instead of coupling to
|
||||
|
|
|
|||
|
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
"replace": false,
|
||||
"values": [
|
||||
{
|
||||
"id": "create_the_air_wars:titaniumingot",
|
||||
"required": false
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
"replace": false,
|
||||
"values": [
|
||||
{
|
||||
"id": "create_the_air_wars:titaniumnugget",
|
||||
"required": false
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
"replace": false,
|
||||
"values": [
|
||||
{
|
||||
"id": "create_the_air_wars:titaniumsheet",
|
||||
"required": false
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -42,6 +42,10 @@
|
|||
{
|
||||
"item": "ae2:certus_quartz_crystal",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:gems/certus_quartz",
|
||||
"value": 1.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -50,6 +50,10 @@
|
|||
{
|
||||
"item": "ae2:fluix_crystal",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:gems/fluix",
|
||||
"value": 1.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -51,6 +51,10 @@
|
|||
{
|
||||
"item": "ars_nouveau:source_gem",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:gems/source",
|
||||
"value": 1.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -66,6 +66,18 @@
|
|||
{
|
||||
"item": "rocketnautics:titanium_block",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/titanium",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/titanium",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/titanium",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -56,6 +56,18 @@
|
|||
{
|
||||
"item": "rocketnautics:titanium_alloy_block",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/titanium_alloy",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/titanium_alloy",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/titanium_alloy",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -44,6 +44,18 @@
|
|||
{
|
||||
"item": "create:andesite_alloy_block",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/andesite_alloy",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/andesite_alloy",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/andesite_alloy",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -51,6 +51,18 @@
|
|||
{
|
||||
"item": "create:brass_sheet",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/brass",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/brass",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/brass",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -47,6 +47,18 @@
|
|||
{
|
||||
"item": "create:zinc_block",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/zinc",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/zinc",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/zinc",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -42,6 +42,18 @@
|
|||
{
|
||||
"item": "createdeco:industrial_iron_nugget",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/industrial_iron",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/industrial_iron",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/industrial_iron",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -50,6 +50,10 @@
|
|||
{
|
||||
"item": "enderio:ender_crystal",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:gems/ender_crystal",
|
||||
"value": 1.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -54,6 +54,10 @@
|
|||
{
|
||||
"item": "enderio:enticing_crystal",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:gems/enticing_crystal",
|
||||
"value": 1.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -47,6 +47,10 @@
|
|||
{
|
||||
"item": "enderio:prescient_crystal",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:gems/prescient_crystal",
|
||||
"value": 1.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -50,6 +50,10 @@
|
|||
{
|
||||
"item": "enderio:pulsating_crystal",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:gems/pulsating_crystal",
|
||||
"value": 1.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -50,6 +50,10 @@
|
|||
{
|
||||
"item": "enderio:vibrant_crystal",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:gems/vibrant_crystal",
|
||||
"value": 1.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -50,6 +50,10 @@
|
|||
{
|
||||
"item": "enderio:weather_crystal",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:gems/weather_crystal",
|
||||
"value": 1.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -42,6 +42,18 @@
|
|||
{
|
||||
"item": "enderio:conductive_alloy_nugget",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/conductive_alloy",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/conductive_alloy",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/conductive_alloy",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -48,6 +48,18 @@
|
|||
{
|
||||
"item": "enderio:dark_steel_nugget",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/dark_steel",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/dark_steel",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/dark_steel",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -48,6 +48,18 @@
|
|||
{
|
||||
"item": "enderio:end_steel_nugget",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/end_steel",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/end_steel",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/end_steel",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -52,6 +52,18 @@
|
|||
{
|
||||
"item": "enderio:energetic_alloy_nugget",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/energetic_alloy",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/energetic_alloy",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/energetic_alloy",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -50,6 +50,18 @@
|
|||
{
|
||||
"item": "enderio:pulsating_alloy_nugget",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/pulsating_alloy",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/pulsating_alloy",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/pulsating_alloy",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -50,6 +50,18 @@
|
|||
{
|
||||
"item": "enderio:redstone_alloy_nugget",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/redstone_alloy",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/redstone_alloy",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/redstone_alloy",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -47,6 +47,18 @@
|
|||
{
|
||||
"item": "enderio:soularium_nugget",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/soularium",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/soularium",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/soularium",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -52,6 +52,18 @@
|
|||
{
|
||||
"item": "enderio:vibrant_alloy_nugget",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/vibrant_alloy",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/vibrant_alloy",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/vibrant_alloy",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -46,6 +46,10 @@
|
|||
{
|
||||
"item": "iceandfire:sapphire_block",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:gems/sapphire",
|
||||
"value": 1.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -54,6 +54,18 @@
|
|||
{
|
||||
"item": "iceandfire:silver_block",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/silver",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/silver",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/silver",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -59,6 +59,18 @@
|
|||
{
|
||||
"item": "immersiveengineering:plate_aluminum",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/aluminum",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/aluminum",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/aluminum",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -46,6 +46,18 @@
|
|||
{
|
||||
"item": "immersiveengineering:plate_constantan",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/constantan",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/constantan",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/constantan",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -52,6 +52,18 @@
|
|||
{
|
||||
"item": "immersiveengineering:plate_electrum",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/electrum",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/electrum",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/electrum",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -58,6 +58,18 @@
|
|||
{
|
||||
"item": "immersiveengineering:plate_hop_graphite",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/hop_graphite",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/hop_graphite",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/hop_graphite",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -47,6 +47,18 @@
|
|||
{
|
||||
"item": "immersiveengineering:plate_nickel",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/nickel",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/nickel",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/nickel",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -50,6 +50,18 @@
|
|||
{
|
||||
"item": "industrialforegoing:pink_slime_ingot",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/pink_slime",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/pink_slime",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/pink_slime",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -52,6 +52,18 @@
|
|||
{
|
||||
"item": "irons_spellbooks:mithril_ingot",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/mithril",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/mithril",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/mithril",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -54,6 +54,10 @@
|
|||
{
|
||||
"item": "mekanism:block_fluorite",
|
||||
"value": 4.0
|
||||
},
|
||||
{
|
||||
"tag": "c:gems/fluorite",
|
||||
"value": 1.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -46,6 +46,18 @@
|
|||
{
|
||||
"item": "mekanism:block_bronze",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/bronze",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/bronze",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/bronze",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -59,6 +59,18 @@
|
|||
{
|
||||
"item": "mekanism:block_lead",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/lead",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/lead",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/lead",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -59,6 +59,18 @@
|
|||
{
|
||||
"item": "mekanism:block_osmium",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/osmium",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/osmium",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/osmium",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -58,6 +58,18 @@
|
|||
{
|
||||
"item": "mekanism:block_refined_glowstone",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/refined_glowstone",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/refined_glowstone",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/refined_glowstone",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -62,6 +62,18 @@
|
|||
{
|
||||
"item": "mekanism:block_refined_obsidian",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/refined_obsidian",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/refined_obsidian",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/refined_obsidian",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -47,6 +47,18 @@
|
|||
{
|
||||
"item": "mekanism:block_steel",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/steel",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/steel",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/steel",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -47,6 +47,18 @@
|
|||
{
|
||||
"item": "mekanism:block_tin",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/tin",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/tin",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/tin",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -65,6 +65,18 @@
|
|||
{
|
||||
"item": "mekanism:block_uranium",
|
||||
"value": 9.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/uranium",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/uranium",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/uranium",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -48,6 +48,18 @@
|
|||
{
|
||||
"item": "occultism:iesnium_nugget",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/iesnium",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/iesnium",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/iesnium",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -54,6 +54,18 @@
|
|||
{
|
||||
"item": "superbwarfare:tungsten_ingot",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:ingots/tungsten",
|
||||
"value": 1.0
|
||||
},
|
||||
{
|
||||
"tag": "c:nuggets/tungsten",
|
||||
"value": 0.11112
|
||||
},
|
||||
{
|
||||
"tag": "c:storage_blocks/tungsten",
|
||||
"value": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1088,3 +1088,68 @@ EXTENSIONS = [
|
|||
},
|
||||
},
|
||||
]
|
||||
|
||||
|
||||
# ------------------------------------------------- identical materials, one entry
|
||||
# Several of these metals and gems are added by more than one mod. Every
|
||||
# variant should behave as the same material rather than as a near-duplicate,
|
||||
# so on top of the primary provider's own items each material also accepts the
|
||||
# `c:` common tag, which every provider registers into. Any mod's silver ingot
|
||||
# is therefore just silver.
|
||||
#
|
||||
# Nothing records where a stack came from - MIAPI stores only the material id on
|
||||
# the item - so a tool built from Immersive Engineering silver is indistinguish-
|
||||
# able from one built with Ice and Fire silver. The primary provider's item stays
|
||||
# first in the list, so anything that reads a single representative item back out
|
||||
# (repair and deconstruct previews) resolves to the default rather than to
|
||||
# whichever variant happened to be used.
|
||||
COMMON_TAGS = {
|
||||
# metals
|
||||
"tin": "tin", "lead": "lead", "osmium": "osmium", "bronze": "bronze",
|
||||
"steel": "steel", "uranium": "uranium", "silver": "silver",
|
||||
"refined_obsidian": "refined_obsidian", "refined_glowstone": "refined_glowstone",
|
||||
"brass": "brass", "zinc": "zinc", "andesite_alloy": "andesite_alloy",
|
||||
"aluminum": "aluminum", "nickel": "nickel", "constantan": "constantan",
|
||||
"electrum": "electrum", "hop_graphite": "hop_graphite",
|
||||
"titanium": "titanium", "titanium_alloy": "titanium_alloy",
|
||||
"industrial_iron": "industrial_iron", "iesnium": "iesnium",
|
||||
"pink_slime": "pink_slime", "tungsten": "tungsten",
|
||||
"dark_steel": "dark_steel", "end_steel": "end_steel",
|
||||
"energetic_alloy": "energetic_alloy", "vibrant_alloy": "vibrant_alloy",
|
||||
"conductive_alloy": "conductive_alloy", "pulsating_alloy": "pulsating_alloy",
|
||||
"redstone_alloy": "redstone_alloy", "soularium": "soularium",
|
||||
"mithril": "mithril",
|
||||
}
|
||||
|
||||
COMMON_GEM_TAGS = {
|
||||
"certus_quartz": "certus_quartz", "fluix": "fluix", "source_gem": "source",
|
||||
"fluorite": "fluorite", "sapphire": "sapphire",
|
||||
"ender_crystal": "ender_crystal", "vibrant_crystal": "vibrant_crystal",
|
||||
"pulsating_crystal": "pulsating_crystal", "prescient_crystal": "prescient_crystal",
|
||||
"enticing_crystal": "enticing_crystal", "weather_crystal": "weather_crystal",
|
||||
}
|
||||
|
||||
|
||||
def _accept_every_provider():
|
||||
"""Append the common tag to each material that more than one mod can supply.
|
||||
|
||||
Tags are safe where item ids are not: an unknown tag resolves to nothing
|
||||
instead of failing the material, so a tag naming a mod that is not installed
|
||||
costs only an ingredient that matches no item.
|
||||
"""
|
||||
for material in MATERIALS:
|
||||
name = material["name"]
|
||||
if name in COMMON_TAGS:
|
||||
tag = COMMON_TAGS[name]
|
||||
material["items"] = material["items"] + [
|
||||
{"tag": f"c:ingots/{tag}", "value": 1.0},
|
||||
{"tag": f"c:nuggets/{tag}", "value": NUGGET},
|
||||
{"tag": f"c:storage_blocks/{tag}", "value": BLOCK},
|
||||
]
|
||||
elif name in COMMON_GEM_TAGS:
|
||||
material["items"] = material["items"] + [
|
||||
{"tag": f"c:gems/{COMMON_GEM_TAGS[name]}", "value": 1.0},
|
||||
]
|
||||
|
||||
|
||||
_accept_every_provider()
|
||||
|
|
|
|||
Loading…
Reference in New Issue