diff --git a/README.md b/README.md index 460e37d..2e9063b 100644 --- a/README.md +++ b/README.md @@ -17,3 +17,58 @@ See changelog.txt ### Localization + + + +## Description + +"The truth is the pathetically, stupidly, inconveniently obvious truth is helping only ourselves is bad and helping each other is good." - *Steve Basilone & Annie Mebane* + +---- + +Adds tin ore, tin plates, solder, organotins, and (optionall) tinned cable to the game. + +Tin is an early game resource and is slightly easier to process than other metals. This mod largely retains the vanilla feel and is not very complex on its own. If used alongside many of the other BZ mods, the game will become quite a bit more complex. + +If you want a vanilla-esque game with some tweaks, try this mod, or perhaps a less complex one like [Titanium](https://mods.factorio.com/mod/bztitanium) or [Lead](https://mods.factorio.com/mod/bzlead). + +### Details + +Tin ore is smelted directly to aluminum plates. Most tin plates go into solder (with [https://mods.factorio.com/mod/bzlead](lead plates) if available) and organotins, an ingredient used in plastic. + +Supported compatible mods: + +- Space Exploration (>= 0.6.0) & AAI +- Krastorio 2 +- 248k (beta) +- Several other mods like Deadlock Stacking, Deadlock Crating, etc. + +Coming soon: RSO +Coming soon: FE+, 5Dim's, ModMash, etc. +Planned but not yet supported: Omnimatter, Simple Compress, and much more. + +Many other mods are compatible, but not yet fully supported. Compatibility suggestions always appreciated. + +---- +Special thanks to + +- The community, for all the suggestions, feedback, and bug reports! +- [snouz](https://mods.factorio.com/user/snouz) (recolored ore graphics, thumbnail style) +- https://www.flickr.com/photos/free-stock/6837291528/ for beta solder icon (modified from public domain image) + +Localization thanks to + +---- + +### Detailed list of changes +See FAQ + +### Detailed list of changes (incomplete) + +#### Vanilla + +#### Krastorio 2 + +#### Space Exploration & AAI + +#### Other diff --git a/changelog.txt b/changelog.txt index da0843d..fc2a6fd 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,6 +1,6 @@ --------------------------------------------------------------------------------------------------- Version: 0.0.1 -Date: 2022-07-04 +Date: 2022-07-05 Features: - Alpha release. Adds tin, solder, organotins, and (optionally) tinned cable - Compatible with Krastorio 2 diff --git a/data-util.lua b/data-util.lua index 0994028..8b49132 100644 --- a/data-util.lua +++ b/data-util.lua @@ -551,7 +551,7 @@ end -- Set recipe category function util.set_category(recipe_name, category) if me.bypass[recipe_name] then return end - if data.raw.recipe[recipe_name] then + if data.raw.recipe[recipe_name] and data.raw["recipe-category"][category] then me.add_modified(recipe_name) data.raw.recipe[recipe_name].category = category end @@ -601,7 +601,7 @@ end -- Add crafting category to an entity function util.add_crafting_category(entity_type, entity, category) - if data.raw[entity_type][entity] then + if data.raw[entity_type][entity] and data.raw["recipe-category"][category] then for i, existing in pairs(data.raw[entity_type][entity].crafting_categories) do if existing == category then log(entity.." not adding "..category.." -- duplicate") diff --git a/info.json b/info.json index 3ef91ba..9014554 100644 --- a/info.json +++ b/info.json @@ -8,7 +8,7 @@ "homepage": "", "dependencies": [ "base >= 1.1.0", - "? bzfoundry", + "? bzfoundry >= 0.2.1", "? bztitanium >= 1.2.0", "? bzlead >= 1.2.0", "? bzzirconium >= 0.6.0", @@ -17,6 +17,7 @@ "? space-exploration >= 0.6.0", "? aai-industry", "? Krastorio2", + "? sand-and-glass", "? deadlock-beltboxes-loaders", "? DeadlockCrating" ], diff --git a/locale/en/tin.cfg b/locale/en/tin.cfg index 4cfd246..eff2ccf 100644 --- a/locale/en/tin.cfg +++ b/locale/en/tin.cfg @@ -26,6 +26,7 @@ organotins=Organotins tinned-cable=Tinned cable organotin-chemistry=Organotin chemistry tin-matter-processing=Tin conversion +glassmaking=Glassmaking [technology-description] enriched-tin=Enrich tin ore, purifying with sulfuric acid [fluid=sulfuric-acid] and water [fluid=water], improving the final yield. Produce dirty water [fluid=dirty-water] as a byproduct. diff --git a/tin-recipe-updates.lua b/tin-recipe-updates.lua index 7ae28f4..56959bb 100644 --- a/tin-recipe-updates.lua +++ b/tin-recipe-updates.lua @@ -52,13 +52,13 @@ else util.replace_some_ingredient("glass-from-sand", "sand", 1, "tin-plate", 1) util.add_product("glass-from-sand", {type="item", name="tin-plate", amount=1, probability=0.8}) util.set_main_product("glass-from-sand", "glass") - util.set_to_founding("glass-from-sand") + util.set_category("glass-from-sand", "basic-founding") -- sand and glass - util.replace_some_ingredient("sng-glass-plate", "sand", 1, "tin-plate", 1) + util.replace_some_ingredient("sng-glass-plate", "sng-sand", 1, "tin-plate", 1) util.add_product("sng-glass-plate", {type="item", name="tin-plate", amount=1, probability=0.8}) util.set_main_product("sng-glass-plate", "sng-glass-plate") - util.set_to_founding("sng-glass-plate") + util.set_category("sng-glass-plate", "basic-founding") end end -- -- NOTE: K2 seems to reset this recipe, so moved to final fixes: