-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Add infrastructure for restricting clothing mods #34705
Add infrastructure for restricting clothing mods #34705
Conversation
Do you really need the bool? You could just use |
Well, this was created with #34593 in mind. Doing it this way, snipercup doesn't have to add |
Co-Authored-By: Jianxiang Wang (王健翔) <[email protected]>
Summary
SUMMARY: Infrastructure "Can set up clothing mods to be valid only for certain items"
Purpose of change
Allows more granularity for clothing mods.
Required infrastructure for #34593
Describe the solution
"restricted"
to clothing mod JSONs (defaults to false)vector<string>
field"valid_mods"
to armor JSONs (defaults to empty list)"restricted": true
can only be applied to armor which lists that clothing mod's ID in"valid_mods"
Describe alternatives you've considered
Discussed in #34593, this seemed the best solution.
Testing
"restricted": true
to one of the clothing mods (I'll usekevlar_padded
as an example)."valid_mods": ["kevlar_padded"]
to any clothing item(s).Additional context
NB: Does not affect existing clothing modifications (as of yet), since
"restricted"
defaults tofalse
.Screenshot of UI changes: