[PR #2647] [MERGED] Save and load creative toolbars with the toolbar keys #4502

Closed
opened 2026-11-03 04:17:38 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/2647
Author: @kacpherek
Created: 10/27/2026
Status: ✅ Merged
Merged: 10/27/2026
Merged by: @ludovic111

Base: main ← Head: fix/creative-hotbar-save-load


📝 Commits (1)

  • 85f3439 Save and load creative toolbars with the toolbar keys

📊 Changes

3 files changed (+70 additions, -1 deletions)

View changed files

📝 crates/horizon-client/src/game.rs (+11 -1)
➕ crates/horizon-client/src/game/creative_hotbar.rs (+39 -0)
📝 crates/horizon-client/src/hotbar.rs (+20 -0)

📄 Description

What and why

Holding C (save) or X (load) and pressing 1 to 9 in creative did nothing but select the slot. The hotbar.nbt reader existed but nothing used it.

Now, as a creative player with a toolbar key held, the hotbar keys load or save that toolbar instead of selecting the slot (load wins when both are held). Load puts the saved row into the nine hotbar slots, and the changed slots go to the server as creative slot packets like any other creative edit. Save stores the hotbar in hotbar.nbt beside options.txt and shows the "Item hotbar saved" message on the action bar.

The saved rows are not shown in the creative Hotbar tab yet.

Vanilla reference

  • Minecraft.handleKeybinds (the hotbar key loop)
  • CreativeModeInventoryScreen.handleHotbarLoadOrSave
  • HotbarManager.save and Hotbar.storeFrom

Self-check

cargo check -p horizon-client passes.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/2647 **Author:** [@kacpherek](https://github.com/kacpherek) **Created:** 10/27/2026 **Status:** ✅ Merged **Merged:** 10/27/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix/creative-hotbar-save-load` --- ### 📝 Commits (1) - [`85f3439`](https://github.com/horizon-rust/horizon/commit/85f34393fe6438c0b5563496408907bcf429cae2) Save and load creative toolbars with the toolbar keys ### 📊 Changes **3 files changed** (+70 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/src/game.rs` (+11 -1) ➕ `crates/horizon-client/src/game/creative_hotbar.rs` (+39 -0) 📝 `crates/horizon-client/src/hotbar.rs` (+20 -0) </details> ### 📄 Description ## What and why Holding C (save) or X (load) and pressing 1 to 9 in creative did nothing but select the slot. The `hotbar.nbt` reader existed but nothing used it. Now, as a creative player with a toolbar key held, the hotbar keys load or save that toolbar instead of selecting the slot (load wins when both are held). Load puts the saved row into the nine hotbar slots, and the changed slots go to the server as creative slot packets like any other creative edit. Save stores the hotbar in `hotbar.nbt` beside `options.txt` and shows the "Item hotbar saved" message on the action bar. The saved rows are not shown in the creative Hotbar tab yet. ## Vanilla reference - `Minecraft.handleKeybinds` (the hotbar key loop) - `CreativeModeInventoryScreen.handleHotbarLoadOrSave` - `HotbarManager.save` and `Hotbar.storeFrom` ## Self-check `cargo check -p horizon-client` passes. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 04:17:38 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#4502
No description provided.