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

Convert weapon_list to weapons.json #90

Merged
merged 1 commit into from
Jun 4, 2022
Merged

Convert weapon_list to weapons.json #90

merged 1 commit into from
Jun 4, 2022

Conversation

royfalk
Copy link
Contributor

@royfalk royfalk commented Jun 3, 2022

Including generating script and actual file.
Note that this change and the previous one to units will break Wing Commander.

Code Changes:

Issues:

  • There are previous issues in the weapon_list that should be addressed at some point.
  • The JSON library does not conform to the standard, making the code sloppier than I would have liked.
  • Old files (units.csv and weapon_list.xml) have not been deleted yet.

Including generating script and actual file.
Copy link
Member

@BenjamenMeyer BenjamenMeyer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Assuming the weapons.json is correct.

@BenjamenMeyer
Copy link
Member

@royfalk @ermo we need something similar for PWCU

@royfalk
Copy link
Contributor Author

royfalk commented Jun 3, 2022

@royfalk @ermo we need something similar for PWCU

Simply run convert.py (weapon_list.xml) and parser.py (units.csv) and it will generate it for you.

@royfalk
Copy link
Contributor Author

royfalk commented Jun 3, 2022

Assuming the weapons.json is correct.

I did not run a complete comparison of the two, but I did spot check and they seem identical. Also, the script is pretty simple so I don't see a lot of places where it can go wrong.

@stephengtuggy
Copy link
Contributor

@royfalk @ermo we need something similar for PWCU

Simply run convert.py (weapon_list.xml) and parser.py (units.csv) and it will generate it for you.

Yeah, I'm working on the units conversion as we speak.

@stephengtuggy
Copy link
Contributor

Here's the draft pull request for the units conversion for PWCU: pwcu/privateer_wcu#9

@royfalk royfalk merged commit b76d26b into master Jun 4, 2022
@royfalk royfalk deleted the task_json_weapons branch June 4, 2022 12:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants