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

feat(UI): move item notes to be with description, move MAGIC_FOCUS flag description to flag section #4339

Merged
merged 2 commits into from
Mar 12, 2024

Conversation

chaosvolt
Copy link
Member

Purpose of change

This implements a lil streamlining of some item UI stuff.

Describe the solution

C++ changes:

  1. In item.cpp, removed the special bit in item::basic_info that places a description for the MAGIC_FOCUS flag directly above the item's description, as this is almost never actually important enough to be given such prominant placement.
  2. Meanwhile, moved the check for notes inscribed on items out of item::final_info and into item::basic_info immediately below the item's basic description. This places it where you'd expect flavor text of this sort to be instead of being way down in its own dedicated section, separated by horizontal rules.

JSON changes:

  1. Gave the MAGIC_FOCUS flag its orignal hardcoded text as its flag description.

Describe alternatives you've considered

Keeping item incriptions isolated by separators but still move them to directly below item description. I slapped some <info> on it so it doesn't blend in with the description though, so should be fine.

Testing

  1. Checked affected JSON change for syntax and lint errors.
  2. Compiled and load-tested.
  3. Started up a world with Magiclysm added, spawned in a lesser staff of the magi.
  4. Confirmed the magic focus text is now in the flag section, and that item description format hasn't been screwed up.
  5. Spawned in a gun and checked that its description is normal, added a note to it and confirmed it correctly displays right under the description.
  6. Spawned in a survivor's note, confirmed it shows the snippet correctly, and that slapping an inscription on it with a marker doesn't break anything.
  7. Checked affected C++ changes for astyle.

image

image

Additional context

Checklist

@github-actions github-actions bot added src changes related to source code. JSON related to game datas in JSON format. labels Mar 11, 2024
@scarf005 scarf005 self-requested a review March 12, 2024 01:03
@scarf005 scarf005 self-assigned this Mar 12, 2024
@scarf005 scarf005 merged commit 8ee6428 into cataclysmbnteam:main Mar 12, 2024
13 checks passed
@chaosvolt chaosvolt deleted the item-desc-tweaks branch March 12, 2024 17:57
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. src changes related to source code.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants