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

Replace hotbar_itemcount by hotbar_source #15905

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

cx384
Copy link
Contributor

@cx384 cx384 commented Mar 15, 2025

To do

Ready for Review.

How to test

  • Read the lua_api.md changes
  • Start devtest
  • Execute /hudhotbars three two times and notice that the hotbars behave like specified in lua_api.md
  • Change your window size and test if the hud_hotbar_max_width setting still works as expected.
  • Maybe test changing the wield item by pressing number keys.
  • Execute /hudinventories and see that it still behaves the same
  • Execute /unittests

@cx384 cx384 added @ Script API Feature ✨ PRs that add or enhance a feature labels Mar 15, 2025
@wsor4035 wsor4035 linked an issue Mar 15, 2025 that may be closed by this pull request
@cx384
Copy link
Contributor Author

cx384 commented Mar 20, 2025

I removed the hotbar element feature and will put it in another PR.
Maybe it will make this PR more likely to be reviewed.

(We will probably still want the feature, though, and I had to implement the functionality anyway to handle the hud_hotbar_max_width setting, and it was helpfull during testing.)

So with this PR you can no longer change which parts of the hotbar the hud element uses, it always uses all inventories of the hotbar source. (Like it is the case in master, but only with a fixed inventory.)

Copy link
Member

@SmallJoker SmallJoker left a comment

Choose a reason for hiding this comment

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

I like the concept of this PR, thus here's the first iteration of my review.

Copy link
Contributor Author

@cx384 cx384 left a comment

Choose a reason for hiding this comment

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

Thanks for the review. I fixed most things, I hope.

@cx384
Copy link
Contributor Author

cx384 commented Mar 20, 2025

The macos pipeline seems to be broken, for some reason, but this PR is ready for review again.

@SmallJoker SmallJoker self-requested a review March 30, 2025 17:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature ✨ PRs that add or enhance a feature @ Script API
Projects
None yet
2 participants