Repository navigation
Build for Minecraft 26.1.x and 26.3 - #32
Merged
Merged
Conversation
Prepares builds for several Minecraft versions from the same sources. For now the only node is 26.2; the jar's version names the Minecraft release it is for. Unit tests run in every node, so the parity tests check against that version's vanilla. Formatting moves to google-java-format, since Spotless can't run on a Stonecutter root.
Two new nodes beside 26.2: 26.1.2, whose jar is labelled 26.1.x and declares 26.1 to 26.1.2, and 26.3. - Input uses InputConstants keys and mouse buttons and Minecraft.hasShiftDown, which mean the same in every version; 26.3 numbers mouse buttons differently. - Version seams live in compat packages, which the formatter skips: screens (Minecraft in 26.1, Gui in 26.2), the after-level draw, the pipeline vertex format, the level render call and the crosshair mixin target (Gui in 26.1, Hud since 26.2). - 26.3 moved the GPU API into com.mojang.renderpearl.api; sources keep the 26.2 names and Stonecutter swaps them, mixin descriptors included. - 26.3 compiles shaders to SPIR-V: the build rewrites ours for it, with #include and explicit locations. - Physics that changed in 26.3 follows that version: the fishing hook falls by 0.03F, and an arrow's hit within the entity margin stays where the path enters the inflated box. - Crossbow ammo is read through ItemStackTemplate, the same in all three. Version 1.1.0-dev.1.
26.2 reversed the depth buffer: it is cleared to 0 and nearer is greater. 26.1 keeps it forward, so the test for the path behind terrain passed in open air and failed behind blocks, and the zone's slope bias pushed it away from the camera. The comparison and the bias sign now come from the Gpu seam.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem and resulting behavior
The mod was built for 26.2 only. It now has a jar for each 26.x family:
+26.1.x(26.1, 26.1.1 and 26.1.2, built against 26.1.2),+26.2and+26.3.InputConstantskeys and mouse buttons andMinecraft.hasShiftDown. 26.3 numbers mouse buttons differently (left 1, right 3), so raw numbers would have broken clicks in the settings.compatpackages: the screen (onMinecraftin 26.1), the draw after the level, the pipelines' vertex format, the level render call and the crosshair mixin target (Guiin 26.1,Hudsince 26.2).com.mojang.renderpearl.api. The sources keep the 26.2 names, and Stonecutter swaps them, mixin descriptors included.#includeand explicitlayout(location).0.03F, and an arrow's hit within the entity margin stays where the path enters the inflated box instead of being projected onto it.Version 1.1.0-dev.1.
Validation performed
formatCheck buildacross all three nodes. Unit tests: 111 per node, including the parity tests against each version's vanilla classes.+26.1.xjar from a real mods folder: passed on 26.1 (Fabric API 0.145.1) and 26.1.1 (0.145.4), and on 26.1.2 without other mods.Limits and compatibility