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

Migration for vehicle parts that are installed in vehicles #37635

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

Migration for vehicle parts that are installed in vehicles #37635

Soup-de-Loop opened this issue Feb 2, 2020 · 3 comments
Labels
[C++] Changes (can be) made in C++. Previously named `Code` <Enhancement / Feature> New features, or enhancements on existing stale Closed for lack of activity, but still valid.

Comments

@Soup-de-Loop
Copy link
Contributor

Soup-de-Loop commented Feb 2, 2020

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

In my attempts to modernise blazemod code, I initially thought that I would be able to make it save-game compatible, albeit with some extensive migration and obsoletion code. However, while items and recipes seem to be able to be redacted without too much issue, and even vehicleparts as items, vehicle parts as they exist as part of an existing vehicle in the save resist transition.

Describe the solution you'd like

If at all possible, a json form to migrate vehicle parts existent on vehicles over to another part or even the ability to have removed would be excellent for keeping saves backwards compatible when a vehicle part becomes superseded or unnecessary in its current form.

Describe alternatives you've considered

Requiring a save-compatibility break every time a vehicle part is removed or noticeably changed in the code, as it stands.

Additional context

Testing: Start a new world, mechanics 3 skill. Save game and quit, add "blazemod" entry to mods.json in the save, start up game, spawn a humvee vehicle and a TDI gun, remove the M240 from the turret and install the TDI as a blazemod turret. Save game, quit. Remove "blazemod" from mods.json, attempt to load the save, receive a seg fault which has this error in the debuglog:

ERROR : src/veh_type.cpp:589 [static void vpart_info::check()] vehicle part turretframe uses undefined item turretframe

Same error occurs with or without migration code line:

  {
    "id": "turretframe",
    "type": "MIGRATION",
    "replace": "turret"
  }

I'm not sure if being able to separately migrate items and vehicleparts would help, though in this case the turretframe item and the turretframe vehiclepart share the same id.

@stale
Copy link

stale bot commented Mar 3, 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 3, 2020
@kevingranade kevingranade added <Enhancement / Feature> New features, or enhancements on existing [C++] Changes (can be) made in C++. Previously named `Code` labels Mar 9, 2020
@stale stale bot removed the stale Closed for lack of activity, but still valid. label Mar 9, 2020
@stale
Copy link

stale bot commented Apr 8, 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 Apr 8, 2020
@stale
Copy link

stale bot commented May 8, 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 May 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[C++] Changes (can be) made in C++. Previously named `Code` <Enhancement / Feature> New features, or enhancements on existing stale Closed for lack of activity, but still valid.
Projects
None yet
Development

No branches or pull requests

2 participants