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

Enchantment/relic cleanup 3 #2264

Merged
merged 20 commits into from
Jan 8, 2023
Merged

Conversation

olanti-p
Copy link
Contributor

@olanti-p olanti-p commented Dec 30, 2022

Summary

SUMMARY: Infrastructure "Finish enchantment values code cleanup"

Purpose of change

Continuation of #400
Completes steps 1 and 2 of #1816

Describe the solution

  1. Add strict json check for legacy enchant values' names
  2. Check, implement, add tests and/or write docs for the following values:
    • STAMINA_CAP
    • STAMINA_REGEN
    • THIRST
    • FATIGUE
    • BONUS_DODGE
    • ITEM_ARMOR_*
    • ARMOR_*
    • ITEM_DAMAGE_BASH
    • ITEM_DAMAGE_CUT
    • ITEM_DAMAGE_STAB
  3. Remove all other unimplemented enchantments from docs and from the enum. Some of these are tricky to implement cleanly and wouldn't have use at the moment, so I'd rather avoid spending time on these now. This way, all enchant vals are implemented and tested, which is good enough by itself.

Testing

Wrote some tests.

@github-actions github-actions bot added JSON related to game datas in JSON format. mods PR changes related to mods. src changes related to source code. tests changes related to tests labels Dec 30, 2022
@Coolthulhu Coolthulhu self-assigned this Jan 4, 2023
@Coolthulhu Coolthulhu merged commit 3e639fc into cataclysmbnteam:upload Jan 8, 2023
@Coolthulhu
Copy link
Member

I didn't test how well does it handle legacy JSONs. Will it still understand them, just complain, or will it fail?

@olanti-p
Copy link
Contributor Author

olanti-p commented Jan 8, 2023

It fails to load when it encounters removed values, and turns out that kinda broke some mods. Pushed a hotfix (#2281)

@olanti-p olanti-p deleted the ench-cleanup-3 branch January 8, 2023 22:02
chaosvolt added a commit to chaosvolt/cdda-arcana-mod that referenced this pull request Jan 10, 2023
Easy lil fixes after cataclysmbnteam/Cataclysm-BN#2264, simple enough.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
JSON related to game datas in JSON format. mods PR changes related to mods. src changes related to source code. tests changes related to tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants