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

Ability to migrate items and vehiclepart-type items separately #37636

Closed
Soup-de-Loop opened this issue Feb 2, 2020 · 2 comments
Closed

Ability to migrate items and vehiclepart-type items separately #37636

Soup-de-Loop opened this issue Feb 2, 2020 · 2 comments
Labels
stale Closed for lack of activity, but still valid. <Suggestion / Discussion> Talk it out before implementing

Comments

@Soup-de-Loop
Copy link
Contributor

Is your feature request related to a problem? Please describe.

When trying to rework blazemod and migrate it, I noticed that a lot of the weapon turret vehicleparts have the exact same id as the items that are used to build them. Additionally, blazemod even has internal references like this, such as the turretframe vehiclepart item and the turretframe vehicle part on a vehicle. More discriminating migration code may help alleviate glued-together code like this in the future.

Describe the solution you'd like

Separate json lines to be able to migrate an item that is just an item, and an item that is also a vehicle part. CDDA is able to tell them apart ingame, but the tools we have on hand don't seem to be capable of disentangling id's this way yet.

Describe alternatives you've considered

Abandoning any code that performs this sin in the mainline or out.

Additional context

Example:

  {
    "id": "fn_fal",
    "copy-from": "turret_blaze",
    "type": "vehicle_part",
    "name": "FN FAL turret",
    "item": "fn_fal",
    "breaks_into": [ { "item": "fn_fal", "count": [ 0, 1 ] } ],
    "requirements": { "install": { "skills": [ [ "mechanics", 3 ] ] }, "removal": { "skills": [ [ "mechanics", 1 ] ] } }
  }

vs

  {
    "id": "fn_fal",
    "copy-from": "rifle_auto",
    "looks_like": "ar15",
    "type": "GUN",
    "name": "FN FAL",
    "name_plural": "FN FAL",
    "description": "Originally designed during the Cold War, the FN FAL is probably the most successful battle rifle ever designed.  Even though often labeled as obsolete, its high rate of fire and powerful ammunition make it perfectly capable of holding its ground against modern competitors.",
    "weight": "4250 g",
    "volume": "2 L",
    "price": 350000,
    "to_hit": -1,
    "bashing": 12,
    "material": [ "steel", "wood" ],
    "symbol": "(",
    "color": "dark_gray",
    "ammo": "308",
    "ranged_damage": -1,
    "dispersion": 150,
    "durability": 8,
    "min_cycle_recoil": 2700,
    "modes": [ [ "DEFAULT", "semi-auto", 1 ], [ "AUTO", "auto", 4 ] ],
    "barrel_length": 2,
    "magazines": [ [ "308", [ "falmag", "falbigmag", "fal_makeshiftmag" ] ] ]
  }
@stale
Copy link

stale bot commented Mar 26, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. Please do not 'bump' or comment on this issue unless you are actively working on it. Stale issues, and stale issues that are closed are still considered.

@stale stale bot added the stale Closed for lack of activity, but still valid. label Mar 26, 2020
@stale
Copy link

stale bot commented Apr 25, 2020

This issue has been automatically closed due to lack of activity. This does not mean that we do not value the issue. Feel free to request that it be re-opened if you are going to actively work on it

@stale stale bot closed this as completed Apr 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stale Closed for lack of activity, but still valid. <Suggestion / Discussion> Talk it out before implementing
Projects
None yet
Development

No branches or pull requests

2 participants