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

Cut down on gun_variant_validator blacklist #74248

Merged
merged 4 commits into from
Jun 2, 2024

Conversation

anothersimulacrum
Copy link
Member

Summary

None

Purpose of change

Work towards the removal of the blacklists in gun_variant_validator.py so standards are enforced throughout the game.

Describe the solution

Rename some guns, make some gun/magazine/gunmod names variants.
Also, some slight modifications to the script to fix some more false positives.

Describe alternatives you've considered

Different names?

Testing

tools/json_tools/gun_variant_validator.py -cin -v data/json

Additional context

Would appreciate review from people who know guns (@Holli-Git)
I would recommend reviewing by commit.

Make name check case insensitive (so Rifle and rifle both work)
Also, don't treat linkages as magazines, because they aren't

Cull the blacklist based on this.
@github-actions github-actions bot added [JSON] Changes (can be) made in JSON Items: Ammo / Guns Ammunition for all kinds of weapons and these weapons themselves [Python] Code made in Python Code: Tooling Tooling that is not part of the main game but is part of the repo. labels Jun 1, 2024
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Auto-requesting reviews from non-collaborators: @jbytheway

@github-actions github-actions bot added astyled astyled PR, label is assigned by github actions json-styled JSON lint passed, label assigned by github actions labels Jun 1, 2024
Copy link
Contributor

github-actions bot commented Jun 1, 2024

Spell checker encountered unrecognized words in the in-game text added in this pull request. See below for details.

Click to expand
  • Kord AK rifle (Demilled)
  • Kord AK rifles (Demilled)

This alert is automatically generated. You can simply disregard if this is inaccurate, or (optionally) you can also add the new words to tools/spell_checker/dictionary.txt so they will not trigger an alert next time.

Hints for adding a new word to the dictionary
  • If the word is normally in all lowercase, such as the noun word or the verb does, add it in its lower-case form; if the word is a proper noun, such as the surname George, add it in its initial-caps form; if the word is an acronym or has special letter case, such as the acronym CDDA or the unit mW, add it by preserving the case of all the letters. A word in the dictionary will also match its initial-caps form (if the word is in all lowercase) and all-uppercase form, so a word should be added to the dictionary in its normal letter case even if used in a different letter case in a sentence.
  • For a word to be added to the dictionary, it should either be a real, properly-spelled modern American English word, a foreign loan word (including romanized foreign names), or a foreign or made-up word that is used consistently and commonly enough in the game. Intentional misspelling (including eye dialect) of a word should not be added unless it has become a common terminology in the game, because while someone may have a legitimate use for it, another person may spell it that way accidentally.

Add some variants to a few guns so that they pass the checks.

Yes, I know BAR rifle will annoy some people. No, I don't care.
@Holli-Git
Copy link
Contributor

Looks good to me!

@github-actions github-actions bot added the BasicBuildPassed This PR builds correctly, label assigned by github actions label Jun 2, 2024
@dseguin dseguin merged commit f3f4d6d into CleverRaven:master Jun 2, 2024
22 of 25 checks passed
@anothersimulacrum anothersimulacrum deleted the fix-some-variants branch June 9, 2024 19:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions Code: Tooling Tooling that is not part of the main game but is part of the repo. Items: Ammo / Guns Ammunition for all kinds of weapons and these weapons themselves [JSON] Changes (can be) made in JSON json-styled JSON lint passed, label assigned by github actions [Python] Code made in Python
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants