Commit Graph

2040 Commits

Author SHA1 Message Date
Ludovic Marie 3cd26c6d0b server_bench: --gamerule, more game rules for both servers
Horizon has no locator bar yet, so equal-work runs turn vanilla's off
(--gamerule locator_bar=false): its waypoint updates cost every move
a pass over every other player.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 05:17:33 +02:00
Ludovic Marie c8003301bc horizon-bots: vanilla's chunk batch sizing, chunk-gated movement and chunk accounting
The bots acknowledge chunk batches with ChunkBatchSizeCalculator's
desired chunks per tick, from how long each batch takes to arrive,
instead of a fixed 25. A bot moves only while it holds the chunk it
stands in, as vanilla's client stops ticking its player in a chunk it
hasn't received, so no bot outruns a server's chunk sending. Each bot
keeps the chunks it holds, so the report separates chunks that entered
its view from chunks sent again while it still held them, and counts
the moves the server refused and the ticks it waited for its chunk.

server_bench.py runs one pass per behaviour (walk, explore), spawns
every bot on the world spawn itself (respawn_radius 0) so both servers
see the same paths, can run the bots on another machine (--bots-via,
--bots-bin, --connect) and the servers under nice, and reports new,
dropped and re-sent chunks per second, pull-backs and the server's
"moved too quickly" lines.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 05:17:33 +02:00
Ludovic Marie b347ceb195 Dedicated server: vanilla's chunk pacing and movement checks
PlayerChunkSender: one unacknowledged batch until the client's first
acknowledgement and ten after it, batches capped at the client's
desired chunks per tick (not twice that), and the quota reset to one
chunk whenever every batch is acknowledged.

ServerGamePacketListenerImpl.handleMovePlayer: a move further from
where the tick began (firstGood) than 100 blocks squared per move
packet (300 while gliding; the count falls back to 1 past 5 packets)
logs "<name> moved too quickly!" and pulls the player back, as the
player_movement_check and elytra_movement_check game rules allow.
NaN coordinates or non-finite angles and two position moves in one
client tick disconnect with invalid_player_movement, positions are
clamped to the world's limits, an unanswered teleport is sent again
after 20 ticks, and accepting a teleport runs the move it carries.

The move is then replayed against the blocks: a survival or adventure
player who ends more than 0.25 blocks short of the target (horizontally;
vanilla drops the vertical part) logs "<name> moved wrongly!" and is
sent back unless they were already stuck, and any move into a block
the old box did not touch (isEntityCollidingWithAnythingNew) is sent
back silently. Spectators and sleepers skip both. Angles wrap as
Mth.wrapDegrees does.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 05:16:08 +02:00
Ludovic Marie bf851bfea1 Merge pull request #648 from ludovic111/feat/modpack-bench
Content mods: refuse more block states than chunks hold; the pack against NeoForge, measured
2026-10-17 05:01:42 +02:00
Ludovic Marie ead46669a5 Merge pull request #641 from Online5277/fix/container-mouse-hotkeys
Honor mouse-bound hotbar swaps in inventories
2026-10-17 04:58:55 +02:00
Ludovic Marie 455967bd47 Merge pull request #647 from ludovic111/feat/sprite-arrays
Block textures: share identical sprites, and draw past 2048 layers
2026-10-17 04:58:13 +02:00
Ludovic Marie 1e514f8539 Merge pull request #633 from ludovic111/feat/port-pack-report
horizon-port-pack report: coverage per mod, and ATM10 measured
2026-10-17 04:58:09 +02:00
Ludovic Marie b0e31eb14f Merge pull request #632 from ludovic111/feat/neoforge-oracle-harness
Per-mod parity harness against a dev-only NeoForge oracle
2026-10-17 04:58:05 +02:00
Ludovic Marie 303c8d4452 Merge pull request #631 from ludovic111/feat/port-pack-oracle-carry
horizon-port-pack carry: templates and numbers from the NeoForge oracle, 1.21.1 loot upgraded
2026-10-17 04:58:00 +02:00
Ludovic Marie 03ca95e8af Merge pull request #630 from ludovic111/feat/mod-content-real-mods
Content mods: load real carried-over mods (large tables, convention tags, mod recipes)
2026-10-17 04:57:55 +02:00
Ludovic Marie 2822d4e1b7 Content mods: refuse more block states than chunks hold; the pack against NeoForge, measured
Loading the eight carried-over mods in the game (not only the probe) showed
two limits real packs reach. Block textures past 2048 layers are another PR;
this one handles block states and measures a pack.

- Chunk sections store a block state in 16 bits. Vanilla 26.3 has 35,723
  states; Macaw's four mods add 36,154, the eight 41,389. Past 65,536 ids
  wrapped onto other blocks (a trapdoor became a hanging sign).
  mod_content::build now refuses a set of mods past MAX_STATES and names the
  states per mod; the game then starts without content mods, as for any
  refused content.
- tools/mod_port_harness.py probes each mod on its own against vanilla, as a
  player adding it would load it.
- tools/perf_bench.py --game neoforge: Minecraft 1.21.1 on NeoForge 21.1.259
  with --mod-jars and --deps, driven by a dev-only NeoForge port of the bench
  mod (mods/horizon/src/neoforge-bench); --port-work loads a work folder's
  carried-over mods into Horizon. tools/neoforge_oracle.py installs the
  client once under .local/neoforge-oracle (the installer, then the vanilla
  libraries it inherits, sha1-checked) and builds the driver. A NeoForge
  start that crashes before the driver loads (FML reading fml.toml while
  creating it) is retried once.

Measured (docs/modpacks.md): six ported mods in Horizon against the same
mods on NeoForge, Mac mini M4 Pro, 2 games per row on a loaded machine. The
world is ready 3.1x sooner at 8 and 16 chunks, the flights run 1.7x and
3.6x the frames, and Horizon's RSS is not lower (+1.1 GB with the mods).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 04:55:20 +02:00
Ludovic Marie 5f9dba6011 Merge pull request #639 from Online5277/fix/classic-extras
Make Extras accessible from Classic Options
2026-10-17 04:53:35 +02:00
Ludovic Marie 103d44f72f Merge main into fix/container-mouse-hotkeys
game.rs: keep this branch's container hotbar-mouse check, then #637's
mouse-bound sort key.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 04:50:43 +02:00
Ludovic Marie 928f31e428 Merge main into fix/classic-extras
options_ui.rs: #585 put Mods... in the telemetry slot; keep it and put
Horizon Extras... in the credits slot as this branch intended.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 04:47:11 +02:00
Ludovic Marie 6c5b04694e Merge pull request #642 from Online5277/fix/redstone-ore-attack
Light both redstone ore variants when mining starts
2026-10-17 04:42:19 +02:00
Ludovic Marie 65e5640350 Merge pull request #640 from Online5277/feat/fullbright-extra
Add an off-by-default Fullbright toggle in Extras
2026-10-17 04:42:15 +02:00
Ludovic Marie b0a82da895 Merge pull request #638 from Online5277/fix/inventory-preview-layout
Correct inventory player scale, labels and equipment overlap
2026-10-17 04:42:11 +02:00
Ludovic Marie f3dd2c27e5 Merge pull request #637 from Online5277/fix/extras-mouse-bindings
Support mouse buttons for Extras sorting and zoom
2026-10-17 04:42:07 +02:00
Ludovic Marie 6eba3f034e Merge pull request #585 from Online5277/fix/classic-mod-management
Add mod management to Classic Options
2026-10-17 04:42:03 +02:00
Ludovic Marie 107671b1e8 Merge pull request #547 from Online5277/fix/banner-item-components
Fix Ominous Banner data, tooltips and breaking effects
2026-10-17 04:31:41 +02:00
Ludovic Marie 8ff9247edb Merge pull request #643 from ludovic111/ci/parity-timeout
CI parity: raise the per-harness timeout to 2400 s
2026-10-17 04:14:57 +02:00
Ludovic Marie 0da61e660b CI parity: raise the per-harness timeout to 2400 s
world_spawn now takes about 1480 s on a loaded Mac mini runner, just
under the old 1500 s limit, so PRs failed on a timeout rather than a
mismatch (#567, #514).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 04:08:08 +02:00
Ludovic Marie d9dc5de701 Merge pull request #567 from ludovic111/perf/villager-poi-index
Villagers search an index of POI blocks instead of scanning every block
2026-10-17 04:07:54 +02:00
Ludovic Marie 892b8ca743 Merge pull request #591 from ludovic111/perf/stronghold-ring-cache
Returning to the Overworld reuses its stronghold ring positions
2026-10-17 04:07:42 +02:00
Cosmic 6d8b174216 Depth-test inventory preview equipment and clip it with a scissor 2026-10-16 22:03:57 -04:00
Ludovic Marie 1e45fd3697 Merge pull request #604 from ludovic111/perf/sp-server-state
Integrated server: control socket and chat read the server's side
2026-10-17 03:58:42 +02:00
Ludovic Marie d6d97e087f Merge pull request #603 from ludovic111/perf/sp-open-to-lan
Integrated server: Open to LAN
2026-10-17 03:56:44 +02:00
Ludovic Marie 5ad2d80908 Merge perf/sp-open-to-lan into perf/sp-server-state
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 03:51:11 +02:00
Ludovic Marie c2f2e15643 Merge main into perf/sp-open-to-lan
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 03:51:10 +02:00
Ludovic Marie 1d79cf69e1 Merge pull request #602 from ludovic111/perf/vanilla-view-distance
Draw the columns vanilla draws (ChunkTrackingView.isInViewDistance)
2026-10-17 03:48:27 +02:00
Ludovic Marie 604d83ddcd Merge pull request #596 from ludovic111/perf/sp-server-effects
Network players have status effects
2026-10-17 03:48:19 +02:00
Ludovic Marie 2ea6689f46 Merge pull request #570 from ludovic111/perf/sp-pause-labels
Integrated server: single-player pause menu labels
2026-10-17 03:48:15 +02:00
Ludovic Marie c2c7d7f4bb Merge pull request #569 from ludovic111/perf/sp-server-fonts-atlas
Integrated server: build only the font, not the whole HUD atlas
2026-10-17 03:48:11 +02:00
Cosmic cf7ed868b9 Light redstone ore when mining begins 2026-10-16 21:46:47 -04:00
Cosmic d98ee9a760 Route mouse-bound hotbar keys through container swaps 2026-10-16 21:44:57 -04:00
Cosmic 8fa5c38663 Add an optional Fullbright extra 2026-10-16 21:42:01 -04:00
Ludovic Marie 803aee8beb Merge perf/sp-open-to-lan (with main) into perf/sp-server-state
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 03:41:16 +02:00
Ludovic Marie bbed107a6a Merge main into perf/sp-open-to-lan
integrated.rs: keep both the LAN port flag and #594's smoothed tick time.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 03:41:08 +02:00
Cosmic fab2a7cb06 Expose Horizon Extras in Classic Options 2026-10-16 21:40:07 -04:00
Cosmic b174299f25 Match vanilla player render scale and inventory title height 2026-10-16 21:37:36 -04:00
Cosmic b2f0af559b Accept and handle mouse bindings for Extras 2026-10-16 21:34:18 -04:00
Ludovic Marie ac87384749 Merge pull request #594 from Online5277/fix/debug-packet-rates
Show live packet rates and server brands in F3
2026-10-17 03:31:54 +02:00
Ludovic Marie ad5f05a8c7 Merge pull request #606 from Online5277/fix/inventory-break-progress
Clear block breaking progress when opening inventory
2026-10-17 02:39:14 +02:00
Cosmic 1fc3f6724e Cancel block mining immediately when opening screens 2026-10-16 19:59:23 -04:00
Ludovic Marie e422bd138a Merge pull request #595 from ludovic111/fix/prepare-again-wording
Name the launcher's real button in the incomplete-resources error
2026-10-17 01:46:40 +02:00
Ludovic Marie f03990f663 Integrated server: control socket and chat read the server's side
With single player on its server thread, the window is the server's
client, and some of what it answered was its own empty side:

- `horizon-ctl save` and `save-all` returned ok without saving: the
  window's save skips worlds it is connected to. They now save on the
  server thread (`Integrated::call`).
- `horizon-ctl chat-log` read the window's local chat, which never
  showed what the server said (command feedback, joins). It reads the
  connection's chat, as the agent's chat query already did.
- The game's own messages (Open to LAN, screenshots...) went to that
  local chat, which is not drawn while connected: they now join the
  connection's chat.
- `state` names the world (the server thread's `LevelName`).
- The client follows its permission level (EntityEvent 24..28,
  LocalPlayer.setPermissionLevel), which the commands the chat offers
  and checks depend on.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 01:45:15 +02:00
Ludovic Marie 2b1cd3e96e Name the launcher's real button in the incomplete-resources error
The launcher offers "Prepare again", not a Repair action.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 01:42:02 +02:00
Cosmic a024409a1a Show live connection packet rates and server brands in F3 2026-10-16 19:41:02 -04:00
Ludovic Marie 7e430564a6 Returning to the Overworld reuses its stronghold ring positions
Each dimension change builds the destination's generator again, and with
it a new structure state, so the 128 stronghold ring searches ran again on
every return to the Overworld (about 1.5 s on two workers) and held up the
first new chunks. The ring positions depend only on the shared generator
data, the seed and the dimension's generator definition, so the generator
data now keeps them by those (the last eight), and later generators for
the same world and dimension share them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 01:39:02 +02:00
Ludovic Marie 64a4c72ebd Merge pull request #574 from Online5277/fix/direct-connect-address
Remember Direct Connection server addresses
2026-10-17 01:37:47 +02:00