Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Obsolete and migrate legacy wire #76204

Merged
merged 14 commits into from
Sep 18, 2024
Merged

Conversation

XygenSS
Copy link
Contributor

@XygenSS XygenSS commented Sep 5, 2024

Summary

Balance "Obsolete and migrate legacy wire in favor of mild steel wire"

Purpose of change

Closes #75840. Legacy steel should be discontinued and split instances of wire and lc_wire should be unified.

Describe the solution

  • Migration and item handling
    Mass replace "wire" with "lc_wire".
    Create a migration for wire to lc_wire.
    Create a migration for piano wire to qt_wire.
    Create an "any_wire" requirement group that contains all wires (except legacy wire). Include it in appropriate places.

  • Constructions
    All constructions and deconstructions of terrain and furniture will use lc_wire only, except:
    Light, heavy, old, electronic machinery may drop all grades of wire
    Reinforced glass drops medium steel wire

  • Loot
    Itemgroups such as steel mill, farm supplies, hardware stores, exodii metal supplies may contain all grades of wire

  • Items, recipes, uncrafts
    Most recipes where wire grade does not matter uses any_wire requirement group
    wire baskets and cages use lc_wire only
    remove the recipe that converts wire to scrap
    remove the recipe that makes wire from scrap (all wire is now made from matching graded steel lump)
    mattresses no longer drop springs, instead drop high steel wire

  • chainmail
    Create a migration for chain_link to lc_chain_link
    Create a migration for link_sheet to lc_link_sheet
    All recipes that use chain_link or link_sheet now use appropriate graded steel versions

Describe alternatives you've considered

Not using an any_wire requirement group, or using it less

Testing

Create a world without changes. Spawn items. Update to include changes. Verify proper migration and handling.

  • Legacy wire, piano wire, chain link, and chainmail sheet migrates properly
  • Cannot craft legacy wire and legacy chainlink/mail anymore
  • Deconstruct/bash piano, chain link fence, heavy machinery, reinforced glass, and conveyor
  • Test affected itemgroups in debug
  • Craft and then disassemble a bra
  • Verify crafting wire, chain link, and link sheet in faction camp

Additional context

You know, it would be best if we just got rid of medium steel altogether.
Mild steel > case hardened steel
High steel > tempered steel
Pretty elegant I think. Medium steel makes the existence of case hardened and high steels complicated.
But that's an issue for another... issue.

@github-actions github-actions bot added NPC / Factions NPCs, AI, Speech, Factions, Ownership [JSON] Changes (can be) made in JSON Vehicles Vehicles, parts, mechanics & interactions Crafting / Construction / Recipes Includes: Uncrafting / Disassembling Spawn Creatures, items, vehicles, locations appearing on map Fields / Furniture / Terrain / Traps Objects that are part of the map or its features. Items: Containers Things that hold other things Items: Armor / Clothing Armor and clothing Appliance/Power Grid Anything to do with appliances and power grid Game: Balance Balancing of (existing) in-game features. astyled astyled PR, label is assigned by github actions labels Sep 5, 2024
@PatrikLundell
Copy link
Contributor

Testing: As well as you can. Some ideas:

  • Make/find save with legacy wire available. Verify it transforms without issue when loaded with new code.
  • Examine a number or recipes that used to use legacy wire and verify they now require mild steel wire.
  • Craft a couple of random modified recipes to verify they still work but uses mild steel wire.
  • Debug spawn some mild steel wire and verify it stacks with migrated wire (so the migrated one doesn't become some weird shadow version).

@XygenSS
Copy link
Contributor Author

XygenSS commented Sep 12, 2024

Should I keep the scrap > lc_wire recipe (old recipe was scrap > wire), or remove it in favor of lc_steel_chunk > lc_wire? I think removing one might mess with innawoods.

@XygenSS
Copy link
Contributor Author

XygenSS commented Sep 12, 2024

How broadly should the "any_wire" requirement group be used? Currently they're used in every recipe involving wire where the wire grade does not matter (anything like space heaters, wooden wheel mounts, canteens, vehicle controls, butchering racks...). However mild steel wire is indeed easier to work and weld, and the material properties of different wire grades are different. So the alternative is to only allow mild steel wire, which makes it very commonly used, but makes other wire grades harder to use, which may be a non-issue.

@github-actions github-actions bot added the json-styled JSON lint passed, label assigned by github actions label Sep 12, 2024
@github-actions github-actions bot added Missions Quests and missions Map / Mapgen Overmap, Mapgen, Map extras, Map display and removed json-styled JSON lint passed, label assigned by github actions labels Sep 15, 2024
@XygenSS XygenSS marked this pull request as ready for review September 15, 2024 08:22
@github-actions github-actions bot added the json-styled JSON lint passed, label assigned by github actions label Sep 15, 2024
@github-actions github-actions bot added the BasicBuildPassed This PR builds correctly, label assigned by github actions label Sep 15, 2024
@github-actions github-actions bot added the <Bugfix> This is a fix for a bug (or closes open issue) label Sep 17, 2024
@Maleclypse Maleclypse merged commit abbb6ce into CleverRaven:master Sep 18, 2024
24 checks passed
@XygenSS XygenSS deleted the killwire branch September 18, 2024 05:23
@MikasaTanikawa
Copy link
Contributor

Should it migrate in-progress items or such migrations are not implemented?

@XygenSS
Copy link
Contributor Author

XygenSS commented Sep 19, 2024

Should it migrate in-progress items or such migrations are not implemented?

I'm not aware of any ways of doing that, no.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Appliance/Power Grid Anything to do with appliances and power grid astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions <Bugfix> This is a fix for a bug (or closes open issue) Crafting / Construction / Recipes Includes: Uncrafting / Disassembling Fields / Furniture / Terrain / Traps Objects that are part of the map or its features. Game: Balance Balancing of (existing) in-game features. Items: Armor / Clothing Armor and clothing Items: Containers Things that hold other things [JSON] Changes (can be) made in JSON json-styled JSON lint passed, label assigned by github actions Map / Mapgen Overmap, Mapgen, Map extras, Map display Missions Quests and missions NPC / Factions NPCs, AI, Speech, Factions, Ownership Spawn Creatures, items, vehicles, locations appearing on map Vehicles Vehicles, parts, mechanics & interactions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Mild steel wire and legacy wire compatibility
4 participants