[GH-ISSUE #4105] Native mods: mod-drawn screens for mod blocks (own GUI textures, layout, data) #1199

Closed
opened 2026-11-02 15:45:01 +07:00 by bsakaguchi · 1 comment
Owner

Originally created by @Sylviromi on GitHub (Oct 30, 2026).
Original GitHub issue: https://github.com/horizon-rust/horizon/issues/4105

Originally assigned to: @Sylviromi on GitHub.

🤖 Filed by Sylviromi's AI agent (Claude Code, Claude Opus 5.5), not by Sylviromi personally.

Part of #3911 (Mods), after #4072 (vanilla menus for mod containers). From #1854's gaps: "M, menus and screens" and "U, client UI".

Today

A mod container can only show a vanilla screen (#4072): a furnace's arrow and flame are all a machine can say. Machine mods draw their own screens: an energy bar, gauges, what the machine is doing.

Proposal

On the client, with no change to the server's menu or the protocol:

  • a content mod's textures/gui files become GUI sprites under its namespace (mymod:gui/...);
  • native_screen(block, &mut Option<NativeScreen>): a mod lays out its block's menu screen (height, slot positions or hidden slots, the inventory's row);
  • native_screen_draw(block, data, batch, origin): it draws the screen from the menu's data slots, which the client now keeps for it, with native_sprite (any part of a sprite) beside native_fill and native_text.
Originally created by @Sylviromi on GitHub (Oct 30, 2026). Original GitHub issue: https://github.com/horizon-rust/horizon/issues/4105 Originally assigned to: @Sylviromi on GitHub. > 🤖 Filed by Sylviromi's AI agent (Claude Code, Claude Opus 5.5), not by Sylviromi personally. Part of #3911 (Mods), after #4072 (vanilla menus for mod containers). From #1854's gaps: "M, menus and screens" and "U, client UI". ## Today A mod container can only show a vanilla screen (#4072): a furnace's arrow and flame are all a machine can say. Machine mods draw their own screens: an energy bar, gauges, what the machine is doing. ## Proposal On the client, with no change to the server's menu or the protocol: - a content mod's `textures/gui` files become GUI sprites under its namespace (`mymod:gui/...`); - `native_screen(block, &mut Option<NativeScreen>)`: a mod lays out its block's menu screen (height, slot positions or hidden slots, the inventory's row); - `native_screen_draw(block, data, batch, origin)`: it draws the screen from the menu's data slots, which the client now keeps for it, with `native_sprite` (any part of a sprite) beside `native_fill` and `native_text`.
Author
Owner

@Sylviromi commented on GitHub (Oct 30, 2026):

/claim

<!-- gh-comment-id:6511940599 --> @Sylviromi commented on GitHub (Oct 30, 2026): /claim
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#1199
No description provided.