Skip to content

Add Minecraft 26.1.2 support#22

Open
grepsedawk wants to merge 1 commit intoJsMacrosCE:mainfrom
grepsedawk:feat/mc-26.1
Open

Add Minecraft 26.1.2 support#22
grepsedawk wants to merge 1 commit intoJsMacrosCE:mainfrom
grepsedawk:feat/mc-26.1

Conversation

@grepsedawk
Copy link
Copy Markdown

@grepsedawk grepsedawk commented Apr 25, 2026

What this PR does

Adds Minecraft 26.1.2 support to JsMacrosCE alongside the existing 1.21.5/8/10/11 targets, coordinated via stonecutter. All five Fabric jars build green; 26.1 launches clean in Fabulously Optimized and connects through to civmc.net.

The 26.1 port is a real overhaul — MC 26.1 ships deobfuscated (Mojang stopped publishing client_mappings from 26.x onward), split the GUI render pipeline into CPU extract + GPU render phases, and renamed a long tail of core classes (GuiGraphicsGuiGraphicsExtractor, ClickTypeContainerInput, LightTextureBrightness/LightCoordsUtil, ItemRendererItemStackRenderState + ItemModelResolver, etc). 112 files changed, ~1640 insertions, nearly all behind //? if >=26.1 { stonecutter gates.

Commit message has the full breakdown of source-level adaptations, mixin retargeting, dedup helpers, justified gaps, and deferred follow-ups.

Disclosure — Claude Opus 4.7 helped

Most of the mechanical rewrite surface here was produced with Claude Opus 4.7 (1M context): the per-file API-rename sweeps, mixin target rediscovery when MC 26.1 moved a hook (e.g. Screen.renderextractGui/extractRenderStateWithTooltipAndSubtitles, handleSystemMessagehandleOverlay), stonecutter gate construction across ~60 common files + ~30 mixins + fabric build/settings plumbing, and a multi-pass /simplify review that landed the dedup wins in this branch (SlotClickEventHelper, gradle version-list extraction via gradle.extra, LOGGER.error over printStackTrace, NeoForge dead-config cleanup). Architectural decisions (keeping 1.21.x, skipping NeoForge 26.1 for a follow-up, stubbing a few 26.1-removed APIs with rationale) were mine; the typing was mostly Claude.

Calling this out because the diff size reflects that amplification — a human wouldn't have produced it in this shape without LLM help, and I'd rather be upfront than have it feel surprising during review.

Could be a lot cleaner if we drop 1.21.*

Roughly ~40% of the diff is stonecutter gates keeping the <26.1 versions building. Things like render-element collector-param forks, ClickType↔ContainerInput dispatch, LightTexture↔LightCoordsUtil splits, drift between GuiGraphics/GuiGraphicsExtractor across dozens of call sites — all of that evaporates if the branch targets 26.1 only. The SubmitNodeCollector consolidation called out in the deferred follow-ups (unified default method on RenderElement3D) becomes much more tractable once you don't have to bridge the 5→6-arg render signature across two eras.

Suggested strategy: land this as-is so 26.1 users aren't blocked, keep 1.21.x alive for a few releases so existing script users have runway, then drop the pre-26.1 branches in a follow-up. That follow-up becomes a 500-line cleanup PR instead of a 1500-line port, and the codebase gets much easier to reason about.

I also like the idea of just cutting hard to 26.1 and having 1.21.x users stay on older versions of JSMacros if that is feasible.

Related

Test plan

  • ./gradlew :fabric:1.21.5:jar :fabric:1.21.8:jar :fabric:1.21.10:jar :fabric:1.21.11:jar :fabric:26.1.2:jar — all green
  • Runtime launch: Fabulously Optimized 26.1.2 boots clean, connects to play.civmc.net:25565
  • Older versions: 1.21.11 still runtime-clean in GrepsCiv instance (unchanged from main)
  • Runtime sanity on 1.21.5/8/10 (compile-verified only; no clients available to smoke-test)

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 25, 2026

Warning

Rate limit exceeded

@grepsedawk has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 44 minutes and 27 seconds before requesting another review.

Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 44 minutes and 27 seconds.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: c1e900be-c054-48b9-a6fb-a1648cfbf4f2

📥 Commits

Reviewing files that changed from the base of the PR and between d8fa56f and f5e6ca5.

📒 Files selected for processing (112)
  • common/build.gradle.kts
  • common/src/main/java/com/jsmacrosce/jsmacros/client/access/IScreenInternal.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/FakeServerCommandSource.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/RegistryHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/TextBuilder.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/inventory/Inventory.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/inventory/LoomInventory.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/Draw2D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/Draw3D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/IDraw2D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/ScriptScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Draw2DElement.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Image.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Item.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Line.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Rect.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/RenderElement.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Text.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Box.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/EntityTraceLine.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Line3D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/RenderElement3D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Surface.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/TraceLine.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/worldscanner/WorldScanner.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/event/impl/EventRecvMessage.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/CommandContextHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/InteractionManagerHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/OptionsHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/PacketByteBufferHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/StyleHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/inventory/ItemHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/inventory/ItemStackHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/ChatHudLineHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/ClickableWidgetHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/TextFieldWidgetHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/BlockDataHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/ChunkHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/StateHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/entity/ClientPlayerEntityHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/entity/EntityHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/library/impl/FClient.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/library/impl/FWorld.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/MacroContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/MacroListTopbar.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/RunningContextContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/ServiceContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/ServiceListTopbar.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/overlays/AboutOverlay.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/overlays/EventChooser.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/overlays/FileChooser.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/overlays/TextOverlay.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/screens/CancelScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/screens/EditorScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/screens/MacroScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/CategoryTreeContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/SettingsOverlay.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingcontainer/AbstractMapSettingContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingcontainer/PrimitiveSettingGroup.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/BooleanField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/DoubleField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/FileField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/FloatField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/IntField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/LongField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/OptionsField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/StringField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinChatHud.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinHandledScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinInGameHud.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinItemRenderer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinItemStackRenderState.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinItemStackRenderStateLayer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinMinecraftClient.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinStyleSerializer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinChatHud.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinClientPlayNetworkHandler.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinClientPlayerInteractionManager.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinCreativeInventoryScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinHandledScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinMessageHandler.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinWorldRenderer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/ChunkPosUtil.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/ContainerInputCompat.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/InteractionCompat.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/SlotClickEventHelper.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/BaseScreen.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/containers/CheckBoxContainer.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/containers/ListContainer.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/containers/MultiElementContainer.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/AnnotatedCheckBox.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/Button.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/Scrollbar.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/Slider.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/TextInput.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/ConfirmOverlay.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/OverlayContainer.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/SelectorDropdownOverlay.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/TextPrompt.java
  • common/src/main/resources/accesswideners/26.1.2-jsmacrosce.accesswidener
  • fabric/build.gradle.kts
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/JsMacrosFabric.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/api/classes/CommandBuilderFabric.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/api/classes/CommandManagerFabric.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinDebugHud.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinGameRenderer.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinKeyboard.java
  • gradle/wrapper/gradle-wrapper.properties
  • settings.gradle.kts
  • stonecutter.gradle.kts
  • versions/26.1.2/gradle.properties
📝 Walkthrough

Walkthrough

Adds broad Minecraft 26.1+ compatibility via version-gated API branches, compiler scaffolding, and utilities; updates rendering entrypoints (GuiGraphics → GuiGraphicsExtractor and SubmitNodeCollector), adapts inventory/container and item/nbt APIs, introduces ChunkPos/interaction/container compat helpers, and adjusts build/stonecutter/loom configuration and access wideners.

Changes

Cohort / File(s) Summary
Core build/config
common/build.gradle.kts, fabric/build.gradle.kts, settings.gradle.kts, stonecutter.gradle.kts, gradle/wrapper/gradle-wrapper.properties, versions/26.1.2/gradle.properties
Conditional Loom/mappings/parchment and deobfuscated vs normal dependency wiring; Gradle wrapper bump; stonecutter/versions driven config and new 26.1.2 profile.
Access widener
common/src/main/resources/accesswideners/26.1.2-jsmacrosce.accesswidener
New access widener for Minecraft 26.1.2 targets.
Rendering API surface (2D/GUI)
common/src/main/java/.../IScreenInternal.java, IDraw2D.java, Draw2D.java, ScriptScreen.java, BaseScreen.java, many GUI screens/containers/overlays/, wagyourgui/`
Version-gated switches from GuiGraphics-based render to GuiGraphicsExtractor/extractRenderState for >=26.1 and text API updates (drawString/drawWordWraptext/textWithWordWrap).
Rendering components (2D elements)
common/src/main/java/.../render/components/* (Image, Item, Line, Rect, Text, Draw2DElement, Draw2DElement.java)
Per-component conditional extractRenderState overloads and 2D draw API adaptations.
Rendering pipeline (3D)
common/src/main/java/.../render/Draw3D.java, RenderElement.java, RenderElement3D.java, components3d/*, Surface.java, TraceLine.java
Adds collector-aware overloads (SubmitNodeCollector) and frame-graph integration for >=26.1; updates render3D signatures and forwards collector through element chain.
Draw3D integration & world renderer
common/src/main/java/.../mixin/events/MixinWorldRenderer.java
New frame-graph FramePass integration that captures SubmitNodeStorage and invokes Draw3D within a frame pass on >=26.1; logging improvement on exceptions.
Mixins - GUI/render/event adaptations
common/src/main/java/.../mixin/access/*, .../mixin/events/*, fabric/.../mixins/*
Version-gated injection targets (renderextractRenderState, resize hooks), chat/addMessage overloads, slot/click handling adjustments and narrowed version gates.
Inventory / container input
common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/inventory/Inventory.java, util/ContainerInputCompat.java, util/SlotClickEventHelper.java
Replaced direct ClickType handling with ContainerInputCompat integer actions; centralized slot-click/drop event helper.
Interaction & input helpers
common/src/main/java/com/jsmacrosce/jsmacros/util/InteractionCompat.java, fabric/.../MixinKeyboard.java, InteractionManagerHelper.java
Introduces InteractionCompat to route entity interactions (EntityHitResult-aware for >=26.1); keyboard/char event shims for newer input events.
Chunk position abstraction
common/src/main/java/com/jsmacrosce/jsmacros/util/ChunkPosUtil.java, plus uses in WorldScanner.java, PacketByteBufferHelper.java, ChunkHelper.java, EntityHelper.java, MixinClientPlayNetworkHandler.java
New ChunkPosUtil.x/z accessors and replacements across code to avoid direct field access.
Item/stack/nbt and registry APIs
common/src/main/java/.../RegistryHelper.java, TextBuilder.java, ItemHelper.java, ItemStackHelper.java, CommandContextHelper.java
Version-gated migration from ItemParser.ItemResult to ItemInput paths, ItemStackTemplate/ItemInput-based construction, and other item API adaptations for >=26.1.
Helpers & small behavior changes
assorted helpers: OptionsHelper.java, StyleHelper.java, ClickableWidgetHelper.java, TextFieldWidgetHelper.java, BlockDataHelper.java, StateHelper.java, FClient.java, FWorld.java
Multiple targeted version-conditional implementation changes (difficulty key, hover item construction, focus handling, text filter no-ops, block state iteration, time-of-day sources).
Fabric module adjustments
fabric/src/main/java/.../JsMacrosFabric.java, CommandBuilderFabric.java, CommandManagerFabric.java, fabric/src/main/java/.../mixins/*
Keybinding registration conditional on Fabric/client API; command builder/dispatcher scaffolding and mixin updates for render interception.
New utilities
common/src/main/java/com/jsmacrosce/jsmacros/util/{ContainerInputCompat,InteractionCompat,ChunkPosUtil,SlotClickEventHelper}.java
New public utility classes to normalize container input, interactions, chunk pos access, and slot-click event dispatch across versions.
Other minor logic & mixin tweaks
many files across common/src and fabric/src
Widespread version-gated imports/comments, narrowed preprocessor gates, and small behavioral shims across many GUI, mixin, and helper classes.

Sequence Diagram(s)

sequenceDiagram
    participant FrameGraph
    participant FramePass
    participant SubmitNodeStorage
    participant Draw3D
    FrameGraph->>FramePass: register "jsmacrosce_draw3d"
    FramePass->>SubmitNodeStorage: capture storage (on enqueue)
    FramePass->>Draw3D: execute(tickDelta, SubmitNodeStorage)
    Draw3D->>SubmitNodeStorage: submit rendering nodes
    Draw3D-->FramePass: completed
Loading

Estimated code review effort

🎯 5 (Critical) | ⏱️ ~120 minutes

Possibly related PRs

✨ Finishing Touches
✨ Simplify code
  • Create PR with simplified code

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 17

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (7)
fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinDebugHud.java (1)

21-24: ⚠️ Potential issue | 🟠 Major

Missing implementation for MC 26.1.2 and newer versions.

The TODO comment indicates the mixin reference changed in 1.21.9/1.21.10, but there's no implementation for versions >1.21.8. This means the FHud.overlays rendering functionality on the debug screen is completely disabled for MC 26.1.2, resulting in a feature regression for the new version this PR is adding.

Would you like me to help identify the correct mixin target for MC 26.1.2? I can search for the updated DebugScreenOverlay method signature that replaced drawGameInformation(GuiGraphics).

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinDebugHud.java`
around lines 21 - 24, The mixin currently only targets the old
DebugScreenOverlay method (drawGameInformation(GuiGraphics)) and lacks support
for MC 26.1.2+; update MixinDebugHud to detect versions >1.21.8 and add a second
mixin target that matches the new DebugScreenOverlay render method signature
used in MC 26.1.2 (the method that replaced drawGameInformation), then inject
the same call to FHud.overlays(renderContext or GuiGraphics equivalent) from
that new target so overlays are rendered on newer versions; reference
MixinDebugHud, FHud.overlays, and the old drawGameInformation(GuiGraphics) to
locate and mirror the existing injection logic when adding the new target.
common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/TextFieldWidgetHelper.java (1)

165-188: ⚠️ Potential issue | 🟡 Minor

Confirm EditBox.setFilter removal in 26.1 and document the behavior change in the Javadoc.

The current Javadoc still reads as if the predicate is honored. Since on 26.1+ this is now a no-op, scripts that rely on rejection-based input filtering will silently accept all input (and only get a single one-shot warning per JVM). Worth noting in the public Javadoc so script authors aren't surprised.

Was EditBox.setFilter(Predicate<String>) removed in Minecraft 26.1, and is there any replacement on EditBox or via TextFormatter / StringUtil.filterText for user-configurable input rejection?
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/TextFieldWidgetHelper.java`
around lines 165 - 188, Update the public Javadoc for
TextFieldWidgetHelper.setTextPredicate and resetTextPredicate to state
explicitly that EditBox.setFilter was removed in Minecraft 26.1 and these
methods are no-ops on 26.1+ (they only emit a single JVM warning once per
session), so scripts cannot rely on rejection-based input filtering; mention
there is no upstream replacement on EditBox and suggest using alternative
filtering before calling setText/setTextSilent or utility methods such as
TextFormatter/StringUtil.filterText if applicable. Ensure the wording appears on
both method docs (and class-level doc if present) and references the exact
methods setTextPredicate and resetTextPredicate so callers know the changed
behavior.
common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinInGameHud.java (1)

20-32: ⚠️ Potential issue | 🟡 Minor

Overlays injected into extractRenderState on 26.1+ run during the state-extraction phase, not GPU render.

The IDraw2D.render and Draw2D.render methods accept GuiGraphicsExtractor on 26.1+, so the signature is compatible. However, the injection point timing differs: on 26.1+, overlays are rendered at TAIL of extractRenderState (CPU state-extraction phase), whereas pre-26.1 renders them at TAIL of render (GPU phase). This could affect z-order: overlays may render before the HUD's own GPU render completes, potentially appearing underneath HUD elements if they were previously drawn on top. If overlays should always appear above HUD elements, verify that extractRenderState or another 26.1 injection point preserves that ordering.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinInGameHud.java`
around lines 20 - 32, The injection currently renders FHud.overlays in
MixinInGameHud at the TAIL of extractRenderState on 26.1+ (and at TAIL of render
on older versions), which runs during the CPU state-extraction phase and can
cause overlays to be drawn before the HUD's GPU render; change the 26.1+
injection to run during the GPU render phase (e.g., inject at the end of the
existing render method or another post-GPU-render hook) so overlays consistently
draw above HUD elements, keeping the method signature compatible with
IDraw2D.render / Draw2D.render (GuiGraphicsExtractor for 26.1+) or adapt to call
the GPU-phase GuiGraphics render path when switching injection points; update
MixinInGameHud to use the GPU-phase injection while preserving FHud.overlays
iteration and rendering logic.
common/src/main/java/com/jsmacrosce/wagyourgui/elements/Button.java (1)

88-127: ⚠️ Potential issue | 🟠 Major

Fix visibility: extractContents must be public, not protected.

The 26.1 override at line 105 declares protected void extractContents(...), but Minecraft 26.1's AbstractButton defines it as public abstract void extractContents(...). This visibility mismatch prevents the override from compiling or functioning correctly. Update line 105 to:

public void extractContents(GuiGraphicsExtractor drawContext, int mouseX, int mouseY, float delta) {

The same issue exists in AnnotatedCheckBox.java and likely other sibling widgets using this pattern.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@common/src/main/java/com/jsmacrosce/wagyourgui/elements/Button.java` around
lines 88 - 127, The override for extractContents in Button.java uses protected
visibility but must be public to match the AbstractButton signature; change the
method declaration for extractContents(GuiGraphicsExtractor drawContext, int
mouseX, int mouseY, float delta) from protected to public so it correctly
overrides; also verify the same visibility change for the alternative
overloads/variants (renderContents/renderWidget) where you conditionally declare
extractContents in AnnotatedCheckBox and any sibling widgets to ensure all
overrides are declared public and match the abstract method signature.
common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinChatHud.java (1)

47-65: ⚠️ Potential issue | 🔴 Critical

Fix commented-out GuiMessageSource import for 26.1+ code path

Line 12 has the import GuiMessageSource commented out (/*import ... */), but lines 48 and 61 reference GuiMessageSource.SYSTEM_CLIENT in the uncommented 26.1+ code branches. This will cause a compilation error in Minecraft 26.1+ because the class is undefined. Uncomment the import on line 12 to resolve.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinChatHud.java`
around lines 47 - 65, The 26.1+ code path uses GuiMessageSource.SYSTEM_CLIENT
but the GuiMessageSource import is commented out, causing compilation errors;
uncomment the GuiMessageSource import statement so GuiMessageSource is
available, then ensure references in methods jsmacros_addMessageAtIndexBypass
and the earlier addMessage call compile with addMessage(...,
GuiMessageSource.SYSTEM_CLIENT, ...), keeping the ThreadLocal
jsmacros$positionOverride usage unchanged.
common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Rect.java (2)

50-68: ⚠️ Potential issue | 🔴 Critical

The 26.1 pipeline declaration uses non-existent classes and methods that will not compile.

DepthStencilState, CompareOp, and the method RenderPipeline.Builder#withDepthStencilState() do not exist in Minecraft 26.1's public API. According to Mojang's deobfuscated mappings, depth control is handled via:

  • withDepthTestFunction(DepthTestFunction) — use DepthTestFunction.ALWAYS instead of CompareOp.ALWAYS_PASS
  • withDepthWrite(boolean) — to control depth write behavior

Replace the 26.1 block to use the correct methods.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Rect.java`
around lines 50 - 68, The 26.1 RenderPipeline block uses non-existent
DepthStencilState/CompareOp APIs; update the DEBUG_QUADS_SEE_THROUGH pipeline
builder to use withDepthTestFunction(DepthTestFunction.ALWAYS) and
withDepthWrite(false) (keep withCull(false) and the same location/name), then
recreate DEBUG_QUADS_SEE_THROUGH_TYPE with RenderType.create(...) using
RenderSetup.builder(DEBUG_QUADS_SEE_THROUGH).createRenderSetup(); ensure the
code references RenderPipeline, RenderPipelines.DEBUG_FILLED_SNIPPET,
DepthTestFunction, DEBUG_QUADS_SEE_THROUGH and DEBUG_QUADS_SEE_THROUGH_TYPE so
it compiles against 26.1 APIs.

396-452: ⚠️ Potential issue | 🟡 Minor

Unused SubmitNodeCollector collector parameter in the >=26.1 path should be either wired into the render logic or removed from the signature.

The parameter appears in the method signature for 26.1 but is never referenced in the body. This same pattern exists in Text.java, Image.java, and Line.java. While Item.java uses renderState.submit(collector, ...), the simpler geometry components rely directly on consumers.getBuffer(RenderTypes.debugQuads()). Clarify whether the collector should be threaded through these simple-geometry paths or whether the parameter is vestigial from an incomplete 26.1 port.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Rect.java`
around lines 396 - 452, The method render3D has an unused SubmitNodeCollector
collector in the >=26.1 signature; either remove the collector parameter from
Rect.render3D (and the matching signatures in Text.java, Image.java, Line.java)
if it's vestigial, or wire it into the render path like Item.java does by
submitting the draw to the collector instead of calling consumers.getBuffer(...)
directly: when enable the 26.1 path, obtain the correct RenderType (debug quads
or see-through variant) and call the project’s submission API (e.g., the same
renderState.submit(collector, ...) pattern used in Item.java) so the collector
is used for batching; apply the same change to Text, Image, and Line to keep
signatures consistent.
🧹 Nitpick comments (14)
common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/FakeServerCommandSource.java (1)

49-57: Nit: keep stonecutter directive whitespace consistent.

Existing blocks in this file use //? } else { / //? } (with a space after //?), but the newly added blocks use *///?} else { / //?} (no space). Both are accepted by Stonecutter, but mixed styles in the same file hurt grep/readability and make it easy to miss directives in future edits.

♻️ Suggested normalization
-    //? if >=26.1 {
+    //? if >=26.1 {
     /*public Collection<String> getCustomTabSuggestions() {
         return source.getCustomTabSuggestions();
     }
-    *///?} else {
+    *///? } else {
     public Collection<String> getCustomTabSugggestions() {
         return source.getCustomTabSugggestions();
     }
-    //?}
+    //? }
-        //? if >=26.1 {
+        //? if >=26.1 {
         /*Minecraft.getInstance().player.sendSystemMessage(feedbackSupplier.get());
-        *///?} else {
+        *///? } else {
         Minecraft.getInstance().player.displayClientMessage(feedbackSupplier.get(), false);
-        //?}
+        //? }

Also applies to: 101-105

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/FakeServerCommandSource.java`
around lines 49 - 57, Normalize the Stonecutter directive spacing in
FakeServerCommandSource by changing the inline comment markers to match the
file's existing style (use "//? } else {" and "//? }" with a space after "//?")
for the blocks around the getCustomTabSuggestions/getCustomTabSugggestions
methods (and the other similar block at lines ~101-105); update the
commented-out older-API variant so the closing markers read "//? } else {" and
"//? }" (with a space) to keep grep/readability consistent.
fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/api/classes/CommandBuilderFabric.java (1)

49-63: Argument-builder gating is consistent — minor DRY opportunity.

The two argument(...) overloads each repeat the same stonecutter >=26.1 switch with only the type.get() vs type.apply(e) difference. Functionally fine and the duplication is small, but if you'd like to reduce stonecutter surface area, consider extracting a single private helper such as buildArgument(String, Function<CommandBuildContext, ArgumentType<?>>) that contains the lone gated call, and have both overloads delegate to it (the Supplier form via e -> type.get()). Defer if not worth the churn.

♻️ Optional dedup sketch
     `@Override`
     protected void argument(String name, Supplier<ArgumentType<?>> type) {
-        //? if >=26.1 {
-        /*pointer.push(new Pair<>(true, (e) -> ClientCommands.argument(name, type.get())));
-        *///?} else {
-        pointer.push(new Pair<>(true, (e) -> ClientCommandManager.argument(name, type.get())));
-        //?}
+        argument(name, (CommandBuildContext e) -> type.get());
     }

     `@Override`
     protected void argument(String name, Function<CommandBuildContext, ArgumentType<?>> type) {
+        pushArgument(name, type);
+    }
+
+    private void pushArgument(String name, Function<CommandBuildContext, ArgumentType<?>> type) {
         //? if >=26.1 {
         /*pointer.push(new Pair<>(true, (e) -> ClientCommands.argument(name, type.apply(e))));
         *///?} else {
         pointer.push(new Pair<>(true, (e) -> ClientCommandManager.argument(name, type.apply(e))));
         //?}
     }
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/api/classes/CommandBuilderFabric.java`
around lines 49 - 63, The two argument overloads in CommandBuilderFabric
duplicate the gated stonecutter conditional; refactor by adding a private helper
(e.g., buildArgument(String name, Function<CommandBuildContext, ArgumentType<?>>
typeFn)) that contains the gated pointer.push call (using typeFn.apply(e)) and
then have the existing protected argument(String, Supplier<ArgumentType<?>>)
delegate by passing e -> type.get(), and the protected argument(String,
Function<CommandBuildContext, ArgumentType<?>>) delegate directly to
buildArgument; update references to pointer.push only inside the new
buildArgument method so the gate logic is centralized.
common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/BlockDataHelper.java (1)

9-19: Gate now-unused imports for the 26.1 target.

On the >=26.1 branch, the for (Entry<Property<?>, Comparable<?>> e : ...) loop is stripped, so import java.util.Map.Entry; (line 19) and import net.minecraft.world.level.block.state.properties.Property; (line 9) are no longer referenced in the 26.1 build and will surface as unused-import warnings (or errors under -Werror). Consider gating them with stonecutter the same way net.minecraft.Util is gated above, or moving the type to a local var inside the else-branch.

Same API caveat as in StateHelper.toMap(): base.getValues().forEach(v -> ...) assumes the new return type is iterable/streamable with v.property()/v.value() accessors. HashMap.put inside a sequential Stream.forEach is fine; just confirm getValues() isn't returning a parallel stream.

♻️ Suggested import gating
 import java.util.HashMap;
 import java.util.Map;
-import java.util.Map.Entry;
+//? if <26.1 {
+import java.util.Map.Entry;
+import net.minecraft.world.level.block.state.properties.Property;
+//?}

(and remove the unconditional Property import on line 9)

Also applies to: 125-131

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/BlockDataHelper.java`
around lines 9 - 19, The imports java.util.Map.Entry and
net.minecraft.world.level.block.state.properties.Property are unused on the 26.1
target because the Property-typed for-loop is stripped; remove the unconditional
imports and either (A) gate their use the same way net.minecraft.Util is gated
(only reference Property/Entry inside the version-conditional branch), or (B)
move the Property/Entry types out of the top-level imports and into the
else-branch using fully-qualified type names or local vars so the compiler only
sees them when that branch is compiled; also update the BlockDataHelper code
that iterates base.getValues() to use the new iterable/stream accessors
(v.property()/v.value()) and ensure the forEach on base.getValues() is executed
sequentially (not a parallel stream) when calling HashMap.put.
fabric/build.gradle.kts (1)

27-28: Prefer an explicit profile flag over a version prefix check.

minecraft_version.startsWith("26.") will break the moment another deobfuscated MC line ships (or, less likely, if any non-deobfuscated 26.x release lands). Driving this from a property in versions/<mc>/gradle.properties (e.g. mc_deobfuscated=true) keeps the loom-plugin selection declarative and mirrors how parchment_* and neoforge_* are already handled — set the flag per profile and read it via commonMod.prop("mc_deobfuscated").toBoolean().

♻️ Proposed refactor
-// MC 26.1 ships deobfuscated, so Loom 1.15+ skips the mappings layer and the
-// remap step. The non-obfuscated plugin `net.fabricmc.fabric-loom` routes to
-// `LoomNoRemapGradlePlugin`; the legacy `fabric-loom` alias still targets the
-// obfuscated-MC plugin used for 1.21.x. Both IDs come from the same JAR and
-// cannot be conditionalised inside the `plugins { }` block, so we apply the
-// correct one here.
-val isDeobfuscatedMc = minecraft_version.startsWith("26.")
-apply(plugin = if (isDeobfuscatedMc) "net.fabricmc.fabric-loom" else "fabric-loom")
+// Deobfuscated MC profiles set `mc_deobfuscated=true` in their version-specific
+// gradle.properties; everything else uses the legacy obfuscated plugin. Both IDs
+// resolve to the same JAR but route to different Loom plugin classes, and
+// cannot be conditionalised inside the `plugins { }` block above.
+val isDeobfuscatedMc = commonMod.prop("mc_deobfuscated").equals("true", ignoreCase = true)
+apply(plugin = if (isDeobfuscatedMc) "net.fabricmc.fabric-loom" else "fabric-loom")

And add mc_deobfuscated=true to versions/26.1.2/gradle.properties (default false/absent in the 1.21.x profiles).

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@fabric/build.gradle.kts` around lines 27 - 28, Replace the brittle runtime
check that sets isDeobfuscatedMc from minecraft_version.startsWith("26.") with a
declarative property read: use
commonMod.prop("mc_deobfuscated").toString().toBoolean() (or
commonMod.prop("mc_deobfuscated").toBoolean() if available) to determine the
boolean used by the apply(plugin = ...) expression; update the code paths that
reference isDeobfuscatedMc accordingly and document that
versions/26.x/gradle.properties should include mc_deobfuscated=true (leave it
absent/false in 1.21.x profiles).
common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/RegistryHelper.java (1)

104-114: Align with ItemHelper and CommandContextHelper by using createItemStack(1) instead of manual component handling.

RegistryHelper uses itemResult.item() and itemResult.components() on the 26.1 branch, while both ItemHelper and CommandContextHelper use the simpler createItemStack(1) pattern for the same ItemInput type. The manual approach appears redundant since createItemStack(1) already encapsulates component application.

♻️ Optional refactor to align with sibling code
         ItemParser reader = new ItemParser(Objects.requireNonNull(mc.getConnection()).registryAccess());
         //? if >=26.1 {
-        /*ItemInput itemResult = reader.parse(new StringReader(parseNameSpace(id) + nbt));
-        *///?} else {
+        /*ItemInput itemInput = reader.parse(new StringReader(parseNameSpace(id) + nbt));
+        return new CreativeItemStackHelper(itemInput.createItemStack(1));
+        *///?} else {
         ItemParser.ItemResult itemResult = reader.parse(new StringReader(parseNameSpace(id) + nbt));
         //?}
         ItemStack stack = new ItemStack(itemResult.item());
         stack.applyComponents(itemResult.components());
         return new CreativeItemStackHelper(stack);

This mirrors ItemHelper.getStackWithNbt and reduces reliance on ItemInput's internal accessors.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/RegistryHelper.java`
around lines 104 - 114, Replace the manual ItemStack construction in
RegistryHelper.getItemStack by invoking the ItemInput's createItemStack(1)
helper instead of calling itemResult.item() and itemResult.components();
specifically, after parsing with ItemParser (ItemParser or ItemParser.ItemResult
depending on branch), call itemResult.createItemStack(1) to obtain the stack and
return new CreativeItemStackHelper(stack) so behavior aligns with
ItemHelper.getStackWithNbt and CommandContextHelper.
common/src/main/java/com/jsmacrosce/jsmacros/util/ContainerInputCompat.java (1)

44-46: Use a switch instead of ClickType.values()[action] for the older-MC path.

The constants on Lines 12–18 happen to match the current ClickType enum ordinals, but that contract is implicit — any future Mojang reordering (or removal/insertion of an entry on a future 1.21.x patch) silently flips actions to the wrong type. The >=26.1 branch already uses an explicit switch, so mirroring that here keeps both paths symmetric, removes the per-call values() array allocation, and produces a clear IllegalArgumentException for unknown action ids instead of ArrayIndexOutOfBoundsException.

♻️ Proposed switch-based mapping
-    private static ClickType toAction(int action) {
-        return ClickType.values()[action];
-    }
+    private static ClickType toAction(int action) {
+        return switch (action) {
+            case PICKUP -> ClickType.PICKUP;
+            case QUICK_MOVE -> ClickType.QUICK_MOVE;
+            case SWAP -> ClickType.SWAP;
+            case CLONE -> ClickType.CLONE;
+            case THROW -> ClickType.THROW;
+            case QUICK_CRAFT -> ClickType.QUICK_CRAFT;
+            case PICKUP_ALL -> ClickType.PICKUP_ALL;
+            default -> throw new IllegalArgumentException("Unknown click action: " + action);
+        };
+    }
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@common/src/main/java/com/jsmacrosce/jsmacros/util/ContainerInputCompat.java`
around lines 44 - 46, Replace the fragile ordinal-based mapping in the private
static method toAction(int action) (which currently uses
ClickType.values()[action]) with an explicit switch mapping that mirrors the
>=26.1 branch's cases; map each known action id to the corresponding ClickType
constant, throw an IllegalArgumentException for unknown ids, and remove the
per-call values() access to avoid array allocation and out-of-bounds errors.
common/src/main/java/com/jsmacrosce/jsmacros/util/ChunkPosUtil.java (1)

5-23: Optional: add a brief class-level Javadoc.

A one-liner explaining that this util exists to bridge the ChunkPos.x/pos.x() field-to-accessor migration would help future maintainers decide when the util can be retired (i.e., once the minimum supported version is >=26.1).

📝 Proposed addition
 package com.jsmacrosce.jsmacros.util;

 import net.minecraft.world.level.ChunkPos;

+/**
+ * Cross-version accessor for {`@link` ChunkPos} coordinates.
+ * On Minecraft 26.1+ {`@code` x}/{`@code` z} are accessor methods; on earlier
+ * versions they are public fields. This util hides the difference so callers
+ * can avoid sprinkling stonecutter gates.
+ */
 public final class ChunkPosUtil {
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@common/src/main/java/com/jsmacrosce/jsmacros/util/ChunkPosUtil.java` around
lines 5 - 23, Add a one-line Javadoc to the ChunkPosUtil class that explains
this utility bridges the field-to-accessor migration for ChunkPos (providing
x(ChunkPos) and z(ChunkPos) compatibility) and notes it can be removed once the
minimum supported Minecraft version is >= 26.1; place the Javadoc immediately
above the class declaration (public final class ChunkPosUtil) so future
maintainers know the purpose and retirement condition for the x(ChunkPos) and
z(ChunkPos) helper methods.
common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/worldscanner/WorldScanner.java (1)

103-106: Optional: cache mc.player.chunkPosition() in a local.

Same nit as EntityHelper.getChunkPos() — call it once.

Proposed nit
     public List<Pos3D> scanAroundPlayer(int chunkRange) {
         if (mc.player == null) return new ArrayList<>();
-        return scanChunkRange(ChunkPosUtil.x(mc.player.chunkPosition()), ChunkPosUtil.z(mc.player.chunkPosition()), chunkRange);
+        var pos = mc.player.chunkPosition();
+        return scanChunkRange(ChunkPosUtil.x(pos), ChunkPosUtil.z(pos), chunkRange);
     }
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/worldscanner/WorldScanner.java`
around lines 103 - 106, In WorldScanner.scanAroundPlayer, avoid calling
mc.player.chunkPosition() twice; cache the result in a local variable (e.g.,
ChunkPos chunkPos = mc.player.chunkPosition()) and then pass
ChunkPosUtil.x(chunkPos) and ChunkPosUtil.z(chunkPos) into scanChunkRange so you
only invoke chunkPosition() once.
common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/TextFieldWidgetHelper.java (1)

153-158: Optional: gate the warn-once flags behind the same stonecutter conditional.

SET_TEXT_PREDICATE_WARNED and RESET_TEXT_PREDICATE_WARNED are only referenced from the >=26.1 branch, so on older targets they are dead static state. Cheap, but easy to gate to keep the legacy artifact identical to pre-PR.

Proposed gating
+    //? if >=26.1 {
+    /*private static final AtomicBoolean SET_TEXT_PREDICATE_WARNED = new AtomicBoolean();
+    private static final AtomicBoolean RESET_TEXT_PREDICATE_WARNED = new AtomicBoolean();
+    *///?}
-    private static final AtomicBoolean SET_TEXT_PREDICATE_WARNED = new AtomicBoolean();
-    private static final AtomicBoolean RESET_TEXT_PREDICATE_WARNED = new AtomicBoolean();

(If you take this, the AtomicBoolean import on line 15 should also be moved inside the same gate.)

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/TextFieldWidgetHelper.java`
around lines 153 - 158, The two warn-once static flags SET_TEXT_PREDICATE_WARNED
and RESET_TEXT_PREDICATE_WARNED (and the AtomicBoolean import) should be moved
inside the same stonecutter conditional used for the ">=26.1" branch so they are
only defined when that branch is compiled; update TextFieldWidgetHelper to
declare these AtomicBoolean fields inside that conditional (and remove the
top-level declarations/import) to avoid adding dead static state on older
targets.
common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/entity/EntityHelper.java (1)

186-188: Optional: extract chunkPosition() to a local.

Minor — base.chunkPosition() is called twice; a local would also make the call site easier to step through.

Proposed nit
     public Pos2D getChunkPos() {
-        return new Pos2D(ChunkPosUtil.x(base.chunkPosition()), ChunkPosUtil.z(base.chunkPosition()));
+        var pos = base.chunkPosition();
+        return new Pos2D(ChunkPosUtil.x(pos), ChunkPosUtil.z(pos));
     }
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/entity/EntityHelper.java`
around lines 186 - 188, The method getChunkPos() calls base.chunkPosition()
twice; assign the result to a local variable (e.g., var chunkPos =
base.chunkPosition() or ChunkPos chunkPos) and then call
ChunkPosUtil.x(chunkPos) and ChunkPosUtil.z(chunkPos) to construct the Pos2D,
which reduces duplicate calls and makes stepping through getChunkPos() easier.
common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinClientPlayerInteractionManager.java (1)

13-13: Gate the EntityHitResult import behind >=26.1 to match the rest of the file.

The import is unconditional but only consumed in the >=26.1 (commented-out) branch, so on pre-26.1 builds it’s an unused import. Cosmetic, but consistent with how other imports (e.g., GuiGraphicsExtractor in sibling files) are scoped.

Proposed gating
-import net.minecraft.world.phys.BlockHitResult;
-import net.minecraft.world.phys.EntityHitResult;
+import net.minecraft.world.phys.BlockHitResult;
+//? if >=26.1 {
+/*import net.minecraft.world.phys.EntityHitResult;
+*///?}
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinClientPlayerInteractionManager.java`
at line 13, The import for EntityHitResult in
MixinClientPlayerInteractionManager is unconditionally added but only used in
the >=26.1 branch; wrap/gate the import so it is only present for >=26.1 builds
to avoid unused-imports on older targets. Locate the import line referencing
EntityHitResult and conditionally include it following the same version-gating
pattern used elsewhere in the codebase (mirror how GuiGraphicsExtractor is
conditioned in sibling files) so the symbol EntityHitResult is only imported for
the >=26.1 variant.
common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/entity/ClientPlayerEntityHelper.java (1)

737-776: Extract cooldown-key formatting to a static helper method to reduce duplication across two methods.

Both getItemCooldownsRemainingTicks() and getTicksSinceCooldownsStart() carry identical version-specific logic for item key formatting. A static helper would localize the version gate and keep the methods DRY:

♻️ Suggested extraction
private static String cooldownKey(Item item) {
    //? if >=26.1 {
    /*return net.minecraft.network.chat.Component.translatable(item.getDescriptionId()).getString();
    *///?} else {
    return item.getName().getString();
    //?}
}

Then apply:

-        //? if >=26.1 {
-        /*return map.entrySet().stream().collect(Collectors.toMap(e -> Component.translatable(e.getKey().getDescriptionId()).getString(), e -> e.getValue().jsmacros_getEndTick() - tick));
-        *///?} else {
-        return map.entrySet().stream().collect(Collectors.toMap(e -> e.getKey().getName().getString(), e -> e.getValue().jsmacros_getEndTick() - tick));
-        //?}
+        return map.entrySet().stream().collect(Collectors.toMap(e -> cooldownKey(e.getKey()), e -> e.getValue().jsmacros_getEndTick() - tick));

Both branches produce equivalent localized strings. The early-init scenario risk is negligible here since these methods access item cooldowns that only exist after client initialization.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/entity/ClientPlayerEntityHelper.java`
around lines 737 - 776, Extract the duplicated version-specific item-to-string
logic into a private static helper method cooldownKey(Item item) that contains
the existing conditional version gate (the //? if >=26.1 { ... } else { ... }
block) and returns the localized String; then replace the lambda in
getItemCooldownsRemainingTicks() and getTicksSinceCooldownsStart() with e ->
cooldownKey(e.getKey()) so both methods call the new helper (keep the helper
private static and returning String).
common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Rect.java (1)

419-449: Stonecutter brace-straddling here is fragile.

The try { is opened only inside the <1.21.11 else-branch (line 424), the vc.addVertex(...) calls live ungated (429–432), and the matching } catch / } finally { ... } is reopened by the inner <1.21.11 gate at line 434–448. It compiles for both branches today, but any future edit (e.g., adding an unconditional statement between 432 and 434, or flipping a gate) will silently desync the braces between the two version variants and one of the build targets will break.

Consider duplicating the two render bodies fully under their own gates, or extracting two private helpers (renderSeeThrough_legacy / renderSeeThrough_modern) so each branch is syntactically self-contained.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Rect.java`
around lines 419 - 449, The Stonecutter version-gated braces are fragile because
the try/catch/finally is opened inside the <1.21.11 branch but the work
(vc.addVertex(...)) and the matching catch/finally are outside/inside the other
gate, risking mismatched braces; fix by making each branch syntactically
self-contained — either duplicate the rendering body under each gate or extract
two private helpers (e.g., renderSeeThroughLegacy(...) and
renderSeeThroughModern(...)) and call the appropriate helper from each
version-gate so that debugQuadsDepthTestFunction manipulation, the
VertexConsumer vc creation (consumers.getBuffer(...)), the vc.addVertex(...)
calls, and the try/catch/finally are all contained within the same gate and
method (referencing debugQuadsDepthTestFunction, RenderPipelines.DEBUG_QUADS,
consumers, MultiBufferSource.BufferSource, and the vc.addVertex calls to locate
the code).
common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Box.java (1)

205-279: Unused SubmitNodeCollector parameter in the 26.1 render signature is systematic across all render elements.

The collector parameter is accepted in Box.render() for >=26.1 but not referenced within the method body. The same pattern appears across all RenderElement3D implementations (Line3D, TraceLine, Surface, etc.) and is even threaded through Surface's helper methods (renderElements3D, renderElement3D). This suggests intentional placeholder implementation matching the deferred "RenderElement3D consolidation" plan. However, confirm that the 26.1 rendering pipeline does not expect elements to submit to the collector — otherwise these elements may silently fail to render once the rest of the pipeline begins enforcing collector usage.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Box.java`
around lines 205 - 279, The SubmitNodeCollector parameter in the 26.1 render
signature (e.g., Box.render(PoseStack, MultiBufferSource, SubmitNodeCollector,
float)) is currently unused across RenderElement3D implementations; explicitly
mark it as intentionally unused to avoid warnings and clarify intent by adding a
brief TODO comment about the pending "RenderElement3D consolidation" plan and a
`@SuppressWarnings`("unused") (or a single-line reference like _collector =
collector;) in each affected method (Box.render, Line3D.render,
TraceLine.render, Surface.render, Surface.renderElements3D,
Surface.renderElement3D, etc.) so the signature stays compatible while making
the placeholder status clear for later pipeline changes.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 32524666-33c2-455e-9a57-7eb2ab1efce6

📥 Commits

Reviewing files that changed from the base of the PR and between f32f661 and 4747e6d.

📒 Files selected for processing (112)
  • common/build.gradle.kts
  • common/src/main/java/com/jsmacrosce/jsmacros/client/access/IScreenInternal.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/FakeServerCommandSource.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/RegistryHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/TextBuilder.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/inventory/Inventory.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/inventory/LoomInventory.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/Draw2D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/Draw3D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/IDraw2D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/ScriptScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Draw2DElement.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Image.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Item.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Line.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Rect.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/RenderElement.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Text.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Box.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/EntityTraceLine.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Line3D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/RenderElement3D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Surface.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/TraceLine.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/worldscanner/WorldScanner.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/event/impl/EventRecvMessage.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/CommandContextHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/InteractionManagerHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/OptionsHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/PacketByteBufferHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/StyleHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/inventory/ItemHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/inventory/ItemStackHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/ChatHudLineHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/ClickableWidgetHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/TextFieldWidgetHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/BlockDataHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/ChunkHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/StateHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/entity/ClientPlayerEntityHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/entity/EntityHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/library/impl/FClient.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/library/impl/FWorld.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/MacroContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/MacroListTopbar.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/RunningContextContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/ServiceContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/ServiceListTopbar.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/overlays/AboutOverlay.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/overlays/EventChooser.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/overlays/FileChooser.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/overlays/TextOverlay.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/screens/CancelScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/screens/EditorScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/screens/MacroScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/CategoryTreeContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/SettingsOverlay.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingcontainer/AbstractMapSettingContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingcontainer/PrimitiveSettingGroup.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/BooleanField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/DoubleField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/FileField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/FloatField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/IntField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/LongField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/OptionsField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/StringField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinChatHud.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinHandledScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinInGameHud.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinItemRenderer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinItemStackRenderState.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinItemStackRenderStateLayer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinMinecraftClient.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinStyleSerializer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinChatHud.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinClientPlayNetworkHandler.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinClientPlayerInteractionManager.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinCreativeInventoryScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinHandledScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinMessageHandler.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinWorldRenderer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/ChunkPosUtil.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/ContainerInputCompat.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/InteractionCompat.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/SlotClickEventHelper.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/BaseScreen.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/containers/CheckBoxContainer.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/containers/ListContainer.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/containers/MultiElementContainer.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/AnnotatedCheckBox.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/Button.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/Scrollbar.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/Slider.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/TextInput.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/ConfirmOverlay.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/OverlayContainer.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/SelectorDropdownOverlay.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/TextPrompt.java
  • common/src/main/resources/accesswideners/26.1.2-jsmacrosce.accesswidener
  • fabric/build.gradle.kts
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/JsMacrosFabric.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/api/classes/CommandBuilderFabric.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/api/classes/CommandManagerFabric.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinDebugHud.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinGameRenderer.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinKeyboard.java
  • gradle/wrapper/gradle-wrapper.properties
  • settings.gradle.kts
  • stonecutter.gradle.kts
  • versions/26.1.2/gradle.properties

Comment on lines +60 to +67
//? if >=26.1 {
/*private static final RenderPipeline ENTITY_TRANSLUCENT_SEE_THROUGH = RenderPipeline.builder(RenderPipelines.ENTITY_SNIPPET)
.withLocation("pipeline/jsmacrosce/entity_translucent_see_through")
.withDepthStencilState(new DepthStencilState(CompareOp.ALWAYS_PASS, false))
.withCull(false)
.build();
private static final Map<ResourceLocation, RenderType> ENTITY_TRANSLUCENT_SEE_THROUGH_TYPES = new ConcurrentHashMap<>();
*///?} else if >=1.21.11 {
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Look for any other use of CompareOp / DepthStencilState in the repo to cross-check naming
rg -nP -C2 '\bCompareOp\.' --type=java
rg -nP -C2 'DepthStencilState' --type=java
# And the previous-version equivalent on the older pipeline builder:
rg -nP -C2 'withDepthStencilState|withDepthTestFunction' --type=java

Repository: JsMacrosCE/JsMacros

Length of output: 7710


🌐 Web query:

Minecraft 26.1 com.mojang.blaze3d.platform.CompareOp enum constants

💡 Result:

No evidence found of a class named com.mojang.blaze3d.platform.CompareOp in Minecraft 26.1 or any recent versions. Mappings sites like mappings.dev and ithundxr.dev list enums in com.mojang.blaze3d.platform such as DepthTestFunction, LogicOp, DestFactor, SourceFactor, but no CompareOp. The class may not exist, be in a different package (possibly com.mojang.blaze3d.opengl), or be obfuscated without public Yarn mappings available for 26.1. Minecraft 26.1 exists as a release (March 2026), but specific decompiled source for this class is not surfaced in searches. Closest matches are GlStateManager$DepthState which handles depth testing, likely using standard OpenGL compare functions (NEVER, LESS, EQUAL, LEQUAL, GREATER, NOTEQUAL, GEQUAL, ALWAYS).

Citations:


CompareOp.ALWAYS_PASS is not a valid Minecraft enum constant; this will cause a compile error when the >=26.1 code path activates.

The web search found no evidence that com.mojang.blaze3d.platform.CompareOp exists in Minecraft 26.1 or recent versions. Public Yarn mappings for 26.1 list DepthTestFunction in that package but no CompareOp. Standard OpenGL enum names do not include ALWAYS_PASS; the correct constant is ALWAYS.

The >=26.1 code path here (and identically in Rect.java line 54) uses an entirely different API from the active version—withDepthStencilState(new DepthStencilState(CompareOp.ALWAYS_PASS, false)) instead of the current withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST). Since this code is commented out, the compile error was not caught. These compile-time failures will surface when 26.1 support becomes active.

Confirm the correct 26.1 API names against deobfuscated source or the latest Yarn mappings and correct both Image.java and Rect.java.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Image.java`
around lines 60 - 67, The commented 26.1 branch in Image.java (and the identical
case in Rect.java) uses the non-existent CompareOp.ALWAYS_PASS and the old
DepthStencilState API; update these to the 26.1 API by removing the
DepthStencilState usage and calling the new withDepthTestFunction(...) method
(e.g. withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) or the exact
DepthTestFunction constant from Yarn), and ensure the
RenderPipeline/RenderPipelines setup (ENTITY_TRANSLUCENT_SEE_THROUGH and
ENTITY_TRANSLUCENT_SEE_THROUGH_TYPES) compiles; verify the exact enum/class
names (DepthTestFunction and its constants, and withDepthTestFunction signature)
against the deobfuscated 26.1/Yarn mappings and apply the same fix in Rect.java.

Comment on lines 157 to 166
public TextBuilder withShowItemHover(ItemStackHelper item) {
//? if >=26.1 {
/*if (!item.getRaw().isEmpty()) {
self.withStyle(style -> style.withHoverEvent(new HoverEvent.ShowItem(ItemStackTemplate.fromNonEmptyStack(item.getRaw()))));
}
*///?} else {
self.withStyle(style -> style.withHoverEvent(new HoverEvent.ShowItem(item.getRaw())));
//?}
return this;
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Cross-version behavior divergence for empty stacks.

On 26.1, an empty stack silently leaves the style without a hover event; on older versions, a ShowItem hover is still attached for AIR/empty stacks. Callers chaining .withShowItemHover(empty) will see different runtime behavior depending on the target version. Consider guarding both branches identically (or documenting the no-op) so the API contract stays stable.

🔧 Proposed alignment
     public TextBuilder withShowItemHover(ItemStackHelper item) {
+        if (item.getRaw().isEmpty()) return this;
         //? if >=26.1 {
-        /*if (!item.getRaw().isEmpty()) {
-            self.withStyle(style -> style.withHoverEvent(new HoverEvent.ShowItem(ItemStackTemplate.fromNonEmptyStack(item.getRaw()))));
-        }
+        /*self.withStyle(style -> style.withHoverEvent(new HoverEvent.ShowItem(ItemStackTemplate.fromNonEmptyStack(item.getRaw()))));
         *///?} else {
         self.withStyle(style -> style.withHoverEvent(new HoverEvent.ShowItem(item.getRaw())));
         //?}
         return this;
     }
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
public TextBuilder withShowItemHover(ItemStackHelper item) {
//? if >=26.1 {
/*if (!item.getRaw().isEmpty()) {
self.withStyle(style -> style.withHoverEvent(new HoverEvent.ShowItem(ItemStackTemplate.fromNonEmptyStack(item.getRaw()))));
}
*///?} else {
self.withStyle(style -> style.withHoverEvent(new HoverEvent.ShowItem(item.getRaw())));
//?}
return this;
}
public TextBuilder withShowItemHover(ItemStackHelper item) {
if (item.getRaw().isEmpty()) return this;
//? if >=26.1 {
/*self.withStyle(style -> style.withHoverEvent(new HoverEvent.ShowItem(ItemStackTemplate.fromNonEmptyStack(item.getRaw()))));
*///?} else {
self.withStyle(style -> style.withHoverEvent(new HoverEvent.ShowItem(item.getRaw())));
//?}
return this;
}
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/TextBuilder.java`
around lines 157 - 166, The withShowItemHover method in TextBuilder currently
differs by Minecraft version: newer branch skips attaching a hover for empty
stacks but the older branch always attaches a ShowItem (including AIR), causing
inconsistent API behavior; update the method (TextBuilder.withShowItemHover) to
perform the same emptiness guard in both branches by checking
item.getRaw().isEmpty() (or ItemStackHelper.isEmpty) before calling
self.withStyle(...) and only attach HoverEvent.ShowItem (using
HoverEvent.ShowItem and ItemStackTemplate.fromNonEmptyStack where applicable)
when the stack is non-empty so both code paths are identical no-ops for empty
stacks.

Comment on lines +15 to +21
public static InteractionResult interact(MultiPlayerGameMode gameMode, LocalPlayer player, Entity entity, InteractionHand hand) {
//? if >=26.1 {
/*return gameMode.interact(player, entity, new EntityHitResult(entity), hand);
*///?} else {
return gameMode.interact(player, entity, hand);
//?}
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

Synthetic EntityHitResult(entity) may misrepresent the actual interaction hit location.

new EntityHitResult(entity) uses the entity's position as the hit location instead of the real crosshair raycast point. For interactions where the hit location is meaningful (e.g., placing armor stand items, sitting on boats, mobs that respond to where they were clicked), this can produce incorrect behavior compared to vanilla — vanilla typically passes the EntityHitResult produced by the picker, which carries the precise hit Vec3.

Consider accepting a hit-location parameter (or letting callers pass an EntityHitResult they obtained from Minecraft#hitResult when available), and falling back to new EntityHitResult(entity) only when no real hit is known.

Sketch
-    public static InteractionResult interact(MultiPlayerGameMode gameMode, LocalPlayer player, Entity entity, InteractionHand hand) {
-        //? if >=26.1 {
-        /*return gameMode.interact(player, entity, new EntityHitResult(entity), hand);
-        *///?} else {
-        return gameMode.interact(player, entity, hand);
-        //?}
-    }
+    public static InteractionResult interact(MultiPlayerGameMode gameMode, LocalPlayer player, Entity entity, InteractionHand hand) {
+        //? if >=26.1 {
+        /*net.minecraft.world.phys.HitResult hr = net.minecraft.client.Minecraft.getInstance().hitResult;
+        EntityHitResult ehr = (hr instanceof EntityHitResult e && e.getEntity() == entity) ? e : new EntityHitResult(entity);
+        return gameMode.interact(player, entity, ehr, hand);
+        *///?} else {
+        return gameMode.interact(player, entity, hand);
+        //?}
+    }
Minecraft 26.1 MultiPlayerGameMode interact EntityHitResult signature
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@common/src/main/java/com/jsmacrosce/jsmacros/util/InteractionCompat.java`
around lines 15 - 21, The current InteractionCompat.interact method constructs a
synthetic EntityHitResult(entity) which can misrepresent the true crosshair hit
location; change the API to accept an EntityHitResult (or an optional hit Vec3)
from callers (the value usually available from Minecraft#hitResult) and pass
that through to MultiPlayerGameMode.interact instead of always constructing new
EntityHitResult(entity), falling back to new EntityHitResult(entity) only when
the caller provides null/absent hit info; update the method signature/overload
for InteractionCompat.interact and all call sites so they supply the real hit
result when available so MultiPlayerGameMode.interact receives the precise hit
location.

Comment on lines 117 to +122
@Override
//? if >=26.1 {
/*public void extractWidgetRenderState(GuiGraphicsExtractor drawContext, int mouseX, int mouseY, float delta) {
*///?} else {
public void renderWidget(GuiGraphics drawContext, int mouseX, int mouseY, float delta) {
//?}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Cross-check overload spelling/visibility across the project's 26.1-gated render hooks.
rg -nP '\b(extractWidgetRenderState|extractRenderState|renderWidget)\s*\(' --type=java -C1

Repository: JsMacrosCE/JsMacros

Length of output: 12238


Rename extractWidgetRenderState to extractRenderState and match visibility to Slider (use protected).

Two critical issues:

  1. Method name mismatch: The declared method is extractWidgetRenderState, but OverlayContainer.java:157 calls extractRenderState on AbstractWidget instances. If Scrollbar widgets are managed there, they'll ignore the call and silently fail to render on 26.1. The pattern across the codebase (CancelScreen, MacroScreen, EditorScreen, etc.) consistently uses extractRenderState, not extractWidgetRenderState.

  2. Visibility inconsistency: Scrollbar declares public while the sibling widget Slider.java:113 declares protected. Both use the same (likely incorrect) method name. Align to protected to match Slider.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@common/src/main/java/com/jsmacrosce/wagyourgui/elements/Scrollbar.java`
around lines 117 - 122, The Scrollbar class currently declares a public method
named extractWidgetRenderState but the codebase (OverlayContainer calling
extractRenderState on AbstractWidget and other widgets like Slider) expects a
protected extractRenderState method; rename extractWidgetRenderState to
extractRenderState and change its visibility to protected so its signature and
access match Slider and the AbstractWidget usage, ensuring OverlayContainer will
dispatch rendering correctly.

Comment on lines +30 to +37
//? if >=26.1 {
/*@Redirect(method = "extractGui", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/gui/screens/Screen;extractRenderStateWithTooltipAndSubtitles(Lnet/minecraft/client/gui/GuiGraphicsExtractor;IIF)V"))
private void onRender(Screen instance, GuiGraphicsExtractor drawContext, int mouseX, int mouseY, float delta) {
instance.extractRenderStateWithTooltipAndSubtitles(drawContext, mouseX, mouseY, delta);
if (!(minecraft.screen instanceof ScriptScreen)) {
((IScreenInternal) instance).jsmacros_render(drawContext, mouseX, mouseY, delta);
}
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Search the project for any references that imply the actual MC 26.1 method names, and confirm the mixin's
# target string is spelled consistently across the codebase (e.g., other gates referencing extractGui /
# extractRenderStateWithTooltipAndSubtitles).
rg -nP --type=java -C2 '\bextractGui\b|extractRenderStateWithTooltipAndSubtitles'
# Also surface any other GameRenderer mixins to ensure none have stale targets on 26.1.
fd -e java -i 'mixingamerenderer'

Repository: JsMacrosCE/JsMacros

Length of output: 1449


🏁 Script executed:

cat -n fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinGameRenderer.java

Repository: JsMacrosCE/JsMacros

Length of output: 3629


Add require = 1 to the 26.1 @Redirect to prevent silent failures if method names change.

The 26.1 branch changes the redirect target from method = "render" to method = "extractGui" and the intercept from Screen.renderWithTooltipAndSubtitles to Screen.extractRenderStateWithTooltipAndSubtitles. The descriptor (Lnet/minecraft/client/gui/GuiGraphicsExtractor;IIF)V correctly encodes the parameter signature (int, int, float).

However, Mixin logs redirect mismatches only at debug level by default—a typo or API shift would silently make the @Redirect a no-op, leaving the IScreenInternal hook never firing. The existing code is consistent with the version evolution pattern (shown in the >1.21.8 and <1.21.8 branches), but adding require = 1 to the annotation will surface any future Mojang renames as a hard failure instead of a silent skip.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinGameRenderer.java`
around lines 30 - 37, The `@Redirect` in MixinGameRenderer's onRender targeting
Screen.extractRenderStateWithTooltipAndSubtitles should include require = 1 so
the mixin fails loudly if the target method signature/name changes; update the
`@Redirect` annotation on the onRender method (the Redirect that references
Screen.extractRenderStateWithTooltipAndSubtitles and the descriptor
(Lnet/minecraft/client/gui/GuiGraphicsExtractor;IIF)V) to add require = 1 to
ensure the IScreenInternal.jsmacros_render hook cannot be silently skipped.

Comment on lines +27 to +32
@WrapOperation(method = "charTyped", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/gui/screens/Screen;charTyped(Lnet/minecraft/client/input/CharacterEvent;)Z"))
private boolean onCharTyped1(Screen instance, CharacterEvent characterEvent, Operation<Boolean> original) {
// 26.1's CharacterEvent is char-only by design — modifier bits only travel with KeyEvent now.
((IScreenInternal) instance).jsmacros_charTyped((char) characterEvent.codepoint(), 0);
return original.call(instance, characterEvent);
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Verify CharacterEvent shape in 26.1 across the codebase.
rg -nP --type=java -C2 '\bCharacterEvent\b'
rg -nP --type=java -C2 '\bcharacterEvent\.\w+'

Repository: JsMacrosCE/JsMacros

Length of output: 8433


🌐 Web query:

Minecraft 26.1 CharacterEvent fields modifiers codepoint

💡 Result:

In Minecraft Java Edition 26.1 (and compatible mod loaders like NeoForge), CharacterEvent is a record class in net.minecraft.client.input with two fields: codepoint (private final int) representing the Unicode codepoint of the character, and modifiers (private final @net.minecraft.client.input.InputWithModifiers.Modifiers int) representing keyboard modifier keys (e.g., shift, control). Both fields have public accessor methods: codepoint and modifiers. The modifiers field uses the InputWithModifiers.Modifiers annotation/type.

Citations:


Replace hardcoded 0 with characterEvent.modifiers() to fix behavioral regression.

The code passes a hardcoded 0 for modifiers (line 30), but CharacterEvent in 26.1 actually does provide a modifiers() accessor. This breaks backward compatibility: any user script reading modifiers inside a CHAR_TYPED handler will silently lose Shift/Ctrl/Alt detection.

The older version (lines 40–44) correctly calls characterEvent.modifiers(). The 26.1 branch should do the same for consistency:

((IScreenInternal) instance).jsmacros_charTyped((char) characterEvent.codepoint(), characterEvent.modifiers());
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinKeyboard.java`
around lines 27 - 32, Replace the hardcoded modifier value in
MixinKeyboard.onCharTyped1: instead of passing 0 to
IScreenInternal.jsmacros_charTyped, call the CharacterEvent.modifiers() accessor
(i.e., use characterEvent.modifiers()) so jsmacros_charTyped receives the actual
modifier bits.

Comment on lines +16 to +17
fabric_version=0.146.1+26.1.2
fabric_loader_version=0.19.2
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🌐 Web query:

What are the current Fabric Loader and Fabric API versions for Minecraft 26.1.2 on fabricmc.net?

💡 Result:

The current Fabric Loader version recommended for Minecraft 26.1 (including 26.1.2) is the latest stable release, 0.19.1. Fabric Loader is largely version-independent and supports Minecraft 26.1 via the Fabric installer on fabricmc.net, which selects the latest compatible loader (latest release as of 2026-04-25 is 0.19.1 from GitHub releases). The official Fabric blog for Minecraft 26.1 mentions "latest stable version of Fabric Loader (currently 0.18.4)" but this is outdated (published March 2026); subsequent releases include 0.19.0 (April 7) and 0.19.1 (April 9). The current Fabric API version for Minecraft 26.1.2 is 0.146.1+26.1.2, as per the latest release on FabricMC/fabric-api GitHub (April 17, 2026). This is confirmed by GitHub release notes specifically tagged for 26.1.2. Fabric API is downloaded separately from mod sites like Modrinth/CurseForge or GitHub after installing Loader, and fabricmc.net links to these.

Citations:


Fix incorrect Fabric Loader version: change 0.19.2 to 0.19.1.

fabric_loader_version=0.19.2 does not exist. The latest Fabric Loader version for MC 26.1.2 is 0.19.1 (released April 9, 2026). The fabric_version=0.146.1+26.1.2 coordinate is correct.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@versions/26.1.2/gradle.properties` around lines 16 - 17, Update the
fabric_loader_version property to the correct published version; change the
value of the fabric_loader_version variable from 0.19.2 to 0.19.1 in the
gradle.properties entry so it reads fabric_loader_version=0.19.1, leaving
fabric_version unchanged.

@grepsedawk
Copy link
Copy Markdown
Author

Reply to coderabbitai review (17 comments)

Thanks for the detailed pass — going through each. Most of these flag stonecutter-gated /*...*/ blocks (compile-time preprocessor) where the 26.1 branch is correct for the 26.1 build target. A few raise genuine pre-existing-behavior or trade-off concerns that are documented or out-of-scope for this PR.

Comment Path Verdict
LoomInventory.java:44 Critical Correct as-is. 26.1 branch correctly uses HolderSet<BannerPattern> holders = stack.get(DataComponents.PROVIDES_BANNER_PATTERNS); return holders != null ? ImmutableList.copyOf(holders) : List.of();. Verified runtime-clean in FO 26.1.2.
Image.java:67 Critical Correct as-is. DepthStencilState(CompareOp.ALWAYS_PASS, false) is the 26.1 API — replaces removed DepthTestFunction.NO_DEPTH_TEST. Compiles + runs against 26.1 client jar.
TextBuilder.java:166 Minor Trade-off acknowledged. 26.1 needs the !isEmpty() guard because ItemStackTemplate.fromNonEmptyStack(empty) throws. Pre-26.1 attaches a (no-op) hover for empty stacks. Could harmonize by adding the guard to <26.1 too — happy to do as a follow-up if maintainers prefer parity.
ItemHelper.java:296 Major Pre-existing behavior on <26.1, fixed by this PR on 26.1. The <26.1 path's new ItemStack(itemResult.item()) ignoring components predates this PR. The 26.1 branch's itemInput.createItemStack(1) is the correct behavior. Out of scope to fix the historical <26.1 bug here.
StateHelper.java:37 Critical Correct as-is. 26.1 stateHolder.getValues() returns Stream<Property.Value<?>> (record); we use .collect() accordingly. Pre-26.1's entrySet().stream() is correct for that version.
BooleanField.java:53 Minor Correct. Stonecutter swap of GuiGraphicsGuiGraphicsExtractor parameter; mechanical and verified.
IntField.java:62 Critical Correct. Same mechanical signature swap; render method is on AbstractWidget parent and matches 26.1 method dispatch.
MixinHandledScreen.java:74 (access) Critical Correct. Mixin descriptor switches renderSlotextractSlot for 26.1. Verified resolves at runtime — no Scanned 0 target(s) failure.
MixinScreen.java:953 Minor Documented intentional gap. API removed in 26.1; hover auto-applied via textRenderer(HoveredTextEffects). Noted in commit message under "Justified gaps".
MixinHandledScreen events:29 Major Correct. ContainerInput.id() returns identical numeric values to ClickType.ordinal() (verified across versions). Stonecutter gate preserves semantics.
MixinWorldRenderer.java:102 Major Documented intentional regression. 26.1 engine drains submitNodeStorage inside addMainPass before our addWeatherPass hook — collector.submitItem() silently no-ops. MBS draws (lines/rects/boxes via bufferSource) still render. Inline comment notes the future fix path (retarget to submitBlockDestroyAnimation in addMainPass). Noted in commit message under "Justified gaps".
ChunkPosUtil.java:22 Critical Correct. Coderabbit's web search said "no evidence of accessor change" but our build proves otherwise — pos.x field access fails to compile against 26.1 client jar; pos.x() accessor required. ChunkPosUtil bridges this for 7 call sites.
InteractionCompat.java:21 Major API constraint. new EntityHitResult(entity) uses entity center as hit location. Script-API entry points (InteractionManagerHelper.interactEntity, ClientPlayerEntityHelper.interact) only have an entity reference, no raycast info. Script users couldn't supply a hit location. Best-effort synthesis is the constraint. Could plumb through the actual hit result if scripts gained access to the raycast — out of scope here.
Scrollbar.java:122 Critical Correct. extractWidgetRenderState is the 26.1 rename of renderWidget on AbstractWidget; matches parent dispatch on 26.1 client.
MixinGameRenderer.java:37 Minor Correct. extractGui + extractRenderStateWithTooltipAndSubtitles are the 26.1 method names — verified against 26.1.2 client jar via javap. Resolves at runtime; FO 26.1 boots clean.
MixinKeyboard.java:32 Major Documented intentional design. 26.1's CharacterEvent is char-only (no modifier sibling event). 0 fallback is the correct 26.1 design. Noted in commit message under "Justified gaps".
versions/26.1.2/gradle.properties:17 Critical Correct for current shipping versions. fabric_loader=0.19.2 and fabric_api=0.146.1+26.1.2 are functional — verified via successful build + runtime launch in Fabulously Optimized 26.1.2 against play.civmc.net.

Net: 13 false positives (coderabbit misreading stonecutter /*...*/ gates), 3 documented intentional gaps, 1 pre-existing <26.1 bug out-of-scope, 0 genuinely new bugs.

Happy to take any of the trade-offs as follow-up PRs if maintainers feel strongly (TextBuilder hover-guard parity is the smallest one, ~2 lines).

@grepsedawk
Copy link
Copy Markdown
Author

Also would be stoked to rip out 1.21.x but didn't want to do that without a discussion first.

@grepsedawk grepsedawk force-pushed the feat/mc-26.1 branch 5 times, most recently from a75bbe6 to d8fa56f Compare April 25, 2026 23:35
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 3

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinChatHud.java (1)

68-96: ⚠️ Potential issue | 🟡 Minor

Three-way overrideMessagePos gate is correct; body duplication is unavoidable.

The split between >=26.1 (multiplayer.chat.GuiMessage), >=1.21.11 (client.GuiMessage with addFirst), and the legacy @ModifyArg (add(I,Object)) path correctly reflects upstream changes:

  • 1.21.11 introduced the addFirst redirection (matches the active code path).
  • 26.1 only changed the GuiMessage package, so the redirect body is identical apart from the descriptor.

The method descriptor must be statically bound to each version's signature, so duplication between >=26.1 and >=1.21.11 branches is unavoidable.

List.addFirst is indeed a Java 21 SequencedCollection method. Since the PR notes confirm FO 26.1.2 boots clean, the bytecode is correctly invoking List.addFirst at runtime and the redirect is firing as expected. If the redirect failed to bind (e.g., due to a direct method call on a concrete class), Mixin would raise an exception at load time.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinChatHud.java`
around lines 68 - 96, Keep the three-way gated overrides as-is: the duplicate
bodies of overrideMessagePos are required because the method descriptors differ
across versions (the two `@Redirects` for addMessageToQueue with signatures
"Lnet/minecraft/client/multiplayer/chat/GuiMessage;" and
"Lnet/minecraft/client/GuiMessage;" must be present and statically bound), and
the legacy `@ModifyArg` path (targeting List.add(I,Object)) is needed for older
builds; do not merge them into one method—instead, add a brief clarifying
comment above the overrideMessagePos definitions referencing
jsmacros$positionOverride, the two `@Redirect` annotations and the `@ModifyArg`
fallback so future readers understand the unavoidable duplication and
version-specific descriptors.
common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/RegistryHelper.java (1)

104-114: ⚠️ Potential issue | 🔴 Critical

Fix 26.1 branch: use createItemStack(1) to align with ItemHelper and avoid undefined method calls.

The 26.1 branch attempts to call itemResult.item() and itemResult.components() on ItemInput, but this class does not expose these methods. ItemHelper.getStackWithNbt() and CommandContextHelper both use ItemInput.createItemStack(1) on 26.1, which internally handles both item and component construction. Update the 26.1 branch to match:

/*ItemInput itemInput = reader.parse(new StringReader(parseNameSpace(id) + nbt));
return new CreativeItemStackHelper(itemInput.createItemStack(1));
*///?} else {
ItemParser.ItemResult itemResult = reader.parse(new StringReader(parseNameSpace(id) + nbt));
ItemStack stack = new ItemStack(itemResult.item());
stack.applyComponents(itemResult.components());
return new CreativeItemStackHelper(stack);
//?}
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/RegistryHelper.java`
around lines 104 - 114, In RegistryHelper.getItemStack, the 26.1 branch should
use ItemInput.createItemStack(1) instead of calling item()/components() on
ItemInput; update the branch that currently parses via ItemParser to declare
ItemInput (e.g., ItemInput itemInput = reader.parse(new
StringReader(parseNameSpace(id) + nbt))) and return new
CreativeItemStackHelper(itemInput.createItemStack(1)), removing the manual
ItemStack construction and applyComponents calls so behavior matches
ItemHelper/CommandContextHelper.
🧹 Nitpick comments (5)
common/src/main/java/com/jsmacrosce/jsmacros/util/ContainerInputCompat.java (1)

44-46: Avoid relying on ClickType ordinal order; mirror the 26.1 explicit switch.

ClickType.values()[action] silently couples this compat layer to Mojang's enum declaration order. It happens to align with the local PICKUP..PICKUP_ALL constants today, but a future reorder/insert in ClickType would re-map every action to the wrong value with no compile- or runtime-time signal. It also throws ArrayIndexOutOfBoundsException on bad input, whereas the 26.1 branch throws IllegalArgumentException — two different error contracts for the same public API depending on which jar you're on. Allocating a fresh values() array on every click is also avoidable.

Suggest mirroring the 26.1 branch for symmetry and robustness:

♻️ Proposed refactor
-    private static ClickType toAction(int action) {
-        return ClickType.values()[action];
-    }
+    private static ClickType toAction(int action) {
+        return switch (action) {
+            case PICKUP -> ClickType.PICKUP;
+            case QUICK_MOVE -> ClickType.QUICK_MOVE;
+            case SWAP -> ClickType.SWAP;
+            case CLONE -> ClickType.CLONE;
+            case THROW -> ClickType.THROW;
+            case QUICK_CRAFT -> ClickType.QUICK_CRAFT;
+            case PICKUP_ALL -> ClickType.PICKUP_ALL;
+            default -> throw new IllegalArgumentException("Unknown click action: " + action);
+        };
+    }
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@common/src/main/java/com/jsmacrosce/jsmacros/util/ContainerInputCompat.java`
around lines 44 - 46, The toAction(int action) method currently uses
ClickType.values()[action], which relies on enum ordinals, allocates a values
array each call, and throws ArrayIndexOutOfBoundsException for bad input;
replace it with an explicit switch over the int values mirroring the 26.1 branch
mapping (map each integer case to the corresponding ClickType constant) and have
the default case throw IllegalArgumentException with a clear message; update the
method signature in ContainerInputCompat.toAction to use that switch so no
values() allocation or ordinal-dependence remains.
common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/TextFieldWidgetHelper.java (1)

153-189: Reasonable handling of the upstream EditBox.setFilter removal.

The stonecutter split keeps <26.1 behavior intact while making the 26.1+ regression observable via a once-per-JVM LOGGER.warn (the /*…*///?} flip toggles the warn block into live code on 26.1+, so the warning is actually emitted — not dead). The AtomicBoolean.compareAndSet(false, true) gate is correct for a one-shot warning, and the inline comment block (Lines 153-156) clearly documents the rationale and the deliberate gap. This matches the intentional-regression note in the PR description.

One minor optional cleanup: the two static AtomicBoolean fields and the JsMacros / AtomicBoolean imports are referenced only from the 26.1+ branch, so on <26.1 builds they end up as dead state / unused imports. If you want fully version-clean output you could wrap the field declarations (and optionally the imports) in a //? if >=26.1 gate; entirely optional given the negligible footprint.

♻️ Optional: gate the warn-once state to 26.1+
-    private static final AtomicBoolean SET_TEXT_PREDICATE_WARNED = new AtomicBoolean();
-    private static final AtomicBoolean RESET_TEXT_PREDICATE_WARNED = new AtomicBoolean();
+    //? if >=26.1 {
+    /*private static final AtomicBoolean SET_TEXT_PREDICATE_WARNED = new AtomicBoolean();
+    private static final AtomicBoolean RESET_TEXT_PREDICATE_WARNED = new AtomicBoolean();
+    *///?}
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/TextFieldWidgetHelper.java`
around lines 153 - 189, The code currently emits a one-shot warning for removed
EditBox.setFilter on 26.1+ but leaves the two AtomicBoolean fields and their
imports present on all builds; to avoid unused-field/import warnings on <26.1
you can gate them to only compile on 26.1+: move or wrap the static fields
SET_TEXT_PREDICATE_WARNED and RESET_TEXT_PREDICATE_WARNED (and any related
JsMacros/AtomicBoolean imports) inside a version gate such as //? if >=26.1 so
they are only declared when the warning branch in
TextFieldWidgetHelper.setTextPredicate and
TextFieldWidgetHelper.resetTextPredicate is live. Ensure the gates match the
existing commented warn blocks so behavior is unchanged on 26.1+ and dead on
older builds.
common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinChatHud.java (1)

118-140: Two HEAD injectors on the same overload — consider consolidating (optional).

onAddMessage1 (lines 33-61) and onAddChatMessage (lines 118-140) both inject at @At("HEAD") with cancellable=true on the same addMessage overload. The split predates this PR (same pattern in the legacy branch), so it isn't a regression — but since you're already touching both for the 26.1 retarget, consolidating them into a single HEAD injector would halve the per-version gate maintenance and remove the implicit ordering assumption between the two cancels.

Not a blocker; flagging only because it would simplify the next stonecutter port.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinChatHud.java`
around lines 118 - 140, There are two HEAD injectors for the same addMessage
overload (the methods onAddMessage1 and onAddChatMessage) — consolidate them
into a single HEAD injector that handles both version gates instead of keeping
duplicate injectors; merge the null-check/cancel logic from onAddMessage1 and
onAddChatMessage into one injected method targeting the addMessage signature
used in the diff (the appropriate Lnet/minecraft/... addMessage descriptor) and
remove the redundant injector, preserving the version gating comments (the
?>=26.1 branch) so only one cancellable HEAD injection exists across versions.
fabric/build.gradle.kts (1)

117-124: Minor: defaultRefmapName is a no-op on the no-remap Loom variant.

mixin.defaultRefmapName.set(...) only matters when Loom generates a refmap during remapJar. On 26.1 (deobfuscated, no remapJar), this setting is harmless but unused. Not a blocker — keeping it unconditional avoids an extra branch and the property exists on LoomGradleExtensionAPI for both plugin variants — but consider a TODO comment so future readers don't assume refmaps are produced for 26.1 jars.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@fabric/build.gradle.kts` around lines 117 - 124, The
mixin.defaultRefmapName.set(...) call is a no-op for the no-remap Loom variant
(used in 26.1 where remapJar isn't run); add a short TODO comment next to the
mixin(Action { defaultRefmapName.set(...) }) line explaining that
defaultRefmapName is only used when Loom performs remapJar and that on the
no-remap/26.1 variant this setting is harmless but unused (reference
LoomGradleExtensionAPI, mixin, defaultRefmapName, remapJar) so future readers
don’t assume a refmap is produced for 26.1 jars.
stonecutter.gradle.kts (1)

142-159: LGTM, one small consistency nit.

The deobfuscated/remapping discriminator is duplicated as mcVersion.startsWith("26.") here and minecraft_version.startsWith("26.") in fabric/build.gradle.kts. If 26.2/27.x ever ships obfuscated again (or a different prefix is used), both call sites need to be updated in lockstep. Consider promoting this to a shared helper (e.g., a gradle.extra["isDeobfuscatedMc"] predicate or a buildSrc utility) at follow-up cleanup time.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@stonecutter.gradle.kts` around lines 142 - 159, The
mcVersion.startsWith("26.") check used in fabricArtifactTask is duplicated
elsewhere (minecraft_version.startsWith("26.") in fabric/build.gradle.kts);
extract that logic into a single shared helper (either expose a predicate on
gradle.extra like gradle.extra["isDeobfuscatedMc"] or add a small utility in
buildSrc) and replace both call sites (fabricArtifactTask and the check in
fabric/build.gradle.kts) to use the shared predicate to ensure one source of
truth for the deobfuscated/remapping decision.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/ScriptScreen.java`:
- Around line 40-44: The onRender MethodWrapper in ScriptScreen must use the
renamed second-argument type for MC 26.1+: change the declaration of onRender
(MethodWrapper<Pos3D, GuiGraphics, Object, ?>) to MethodWrapper<Pos3D,
GuiGraphicsExtractor, Object, ?> when targeting 26.1 and keep GuiGraphics for
older targets; update the conditional block around the onRender field so the
correct type is compiled for each target and ensure any call sites that
construct or reference onRender (and scripts that type the second parameter) are
adjusted to the corresponding GuiGraphicsExtractor/GiGraphics type.

In
`@fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinGameRenderer.java`:
- Around line 56-63: The >=26.1 injection for pick is currently commented out so
InteractionProxy.Target.onUpdate never runs on 26.1+; locate the commented
`@Inject` block in MixinMinecraftClient that was intended to replace pick(F)V (the
stub around the method that mirrors MixinGameRenderer.onTargetUpdate) and either
uncomment and restore the injection so it calls
InteractionProxy.Target.onUpdate(float) and cancels via CallbackInfo when true,
or implement an equivalent hook for the new 26.1+ method signature (ensuring the
injected method name and signature match Minecraft's current pick method and
still calls InteractionProxy.Target.onUpdate and ci.cancel()). Ensure the
injection annotation, method name and parameters match the runtime target so the
override actually executes.

In `@settings.gradle.kts`:
- Around line 46-55: Update both fabric-loom plugin declarations to use the
latest 1.15.x release: change the version string on id("fabric-loom") and
id("net.fabricmc.fabric-loom") from "1.15.4" to "1.15.5" so both plugin entries
match the current stable 1.15.5 release.

---

Outside diff comments:
In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/RegistryHelper.java`:
- Around line 104-114: In RegistryHelper.getItemStack, the 26.1 branch should
use ItemInput.createItemStack(1) instead of calling item()/components() on
ItemInput; update the branch that currently parses via ItemParser to declare
ItemInput (e.g., ItemInput itemInput = reader.parse(new
StringReader(parseNameSpace(id) + nbt))) and return new
CreativeItemStackHelper(itemInput.createItemStack(1)), removing the manual
ItemStack construction and applyComponents calls so behavior matches
ItemHelper/CommandContextHelper.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinChatHud.java`:
- Around line 68-96: Keep the three-way gated overrides as-is: the duplicate
bodies of overrideMessagePos are required because the method descriptors differ
across versions (the two `@Redirects` for addMessageToQueue with signatures
"Lnet/minecraft/client/multiplayer/chat/GuiMessage;" and
"Lnet/minecraft/client/GuiMessage;" must be present and statically bound), and
the legacy `@ModifyArg` path (targeting List.add(I,Object)) is needed for older
builds; do not merge them into one method—instead, add a brief clarifying
comment above the overrideMessagePos definitions referencing
jsmacros$positionOverride, the two `@Redirect` annotations and the `@ModifyArg`
fallback so future readers understand the unavoidable duplication and
version-specific descriptors.

---

Nitpick comments:
In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/TextFieldWidgetHelper.java`:
- Around line 153-189: The code currently emits a one-shot warning for removed
EditBox.setFilter on 26.1+ but leaves the two AtomicBoolean fields and their
imports present on all builds; to avoid unused-field/import warnings on <26.1
you can gate them to only compile on 26.1+: move or wrap the static fields
SET_TEXT_PREDICATE_WARNED and RESET_TEXT_PREDICATE_WARNED (and any related
JsMacros/AtomicBoolean imports) inside a version gate such as //? if >=26.1 so
they are only declared when the warning branch in
TextFieldWidgetHelper.setTextPredicate and
TextFieldWidgetHelper.resetTextPredicate is live. Ensure the gates match the
existing commented warn blocks so behavior is unchanged on 26.1+ and dead on
older builds.

In
`@common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinChatHud.java`:
- Around line 118-140: There are two HEAD injectors for the same addMessage
overload (the methods onAddMessage1 and onAddChatMessage) — consolidate them
into a single HEAD injector that handles both version gates instead of keeping
duplicate injectors; merge the null-check/cancel logic from onAddMessage1 and
onAddChatMessage into one injected method targeting the addMessage signature
used in the diff (the appropriate Lnet/minecraft/... addMessage descriptor) and
remove the redundant injector, preserving the version gating comments (the
?>=26.1 branch) so only one cancellable HEAD injection exists across versions.

In `@common/src/main/java/com/jsmacrosce/jsmacros/util/ContainerInputCompat.java`:
- Around line 44-46: The toAction(int action) method currently uses
ClickType.values()[action], which relies on enum ordinals, allocates a values
array each call, and throws ArrayIndexOutOfBoundsException for bad input;
replace it with an explicit switch over the int values mirroring the 26.1 branch
mapping (map each integer case to the corresponding ClickType constant) and have
the default case throw IllegalArgumentException with a clear message; update the
method signature in ContainerInputCompat.toAction to use that switch so no
values() allocation or ordinal-dependence remains.

In `@fabric/build.gradle.kts`:
- Around line 117-124: The mixin.defaultRefmapName.set(...) call is a no-op for
the no-remap Loom variant (used in 26.1 where remapJar isn't run); add a short
TODO comment next to the mixin(Action { defaultRefmapName.set(...) }) line
explaining that defaultRefmapName is only used when Loom performs remapJar and
that on the no-remap/26.1 variant this setting is harmless but unused (reference
LoomGradleExtensionAPI, mixin, defaultRefmapName, remapJar) so future readers
don’t assume a refmap is produced for 26.1 jars.

In `@stonecutter.gradle.kts`:
- Around line 142-159: The mcVersion.startsWith("26.") check used in
fabricArtifactTask is duplicated elsewhere (minecraft_version.startsWith("26.")
in fabric/build.gradle.kts); extract that logic into a single shared helper
(either expose a predicate on gradle.extra like gradle.extra["isDeobfuscatedMc"]
or add a small utility in buildSrc) and replace both call sites
(fabricArtifactTask and the check in fabric/build.gradle.kts) to use the shared
predicate to ensure one source of truth for the deobfuscated/remapping decision.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: e923ba99-7a63-4a65-a66c-765e974632db

📥 Commits

Reviewing files that changed from the base of the PR and between 4747e6d and d8fa56f.

📒 Files selected for processing (112)
  • common/build.gradle.kts
  • common/src/main/java/com/jsmacrosce/jsmacros/client/access/IScreenInternal.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/FakeServerCommandSource.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/RegistryHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/TextBuilder.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/inventory/Inventory.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/inventory/LoomInventory.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/Draw2D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/Draw3D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/IDraw2D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/ScriptScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Draw2DElement.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Image.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Item.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Line.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Rect.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/RenderElement.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Text.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Box.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/EntityTraceLine.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Line3D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/RenderElement3D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Surface.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/TraceLine.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/worldscanner/WorldScanner.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/event/impl/EventRecvMessage.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/CommandContextHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/InteractionManagerHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/OptionsHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/PacketByteBufferHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/StyleHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/inventory/ItemHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/inventory/ItemStackHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/ChatHudLineHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/ClickableWidgetHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/TextFieldWidgetHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/BlockDataHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/ChunkHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/StateHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/entity/ClientPlayerEntityHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/entity/EntityHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/library/impl/FClient.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/library/impl/FWorld.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/MacroContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/MacroListTopbar.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/RunningContextContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/ServiceContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/ServiceListTopbar.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/overlays/AboutOverlay.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/overlays/EventChooser.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/overlays/FileChooser.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/overlays/TextOverlay.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/screens/CancelScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/screens/EditorScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/screens/MacroScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/CategoryTreeContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/SettingsOverlay.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingcontainer/AbstractMapSettingContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingcontainer/PrimitiveSettingGroup.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/BooleanField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/DoubleField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/FileField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/FloatField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/IntField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/LongField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/OptionsField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/StringField.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinChatHud.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinHandledScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinInGameHud.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinItemRenderer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinItemStackRenderState.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinItemStackRenderStateLayer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinMinecraftClient.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinStyleSerializer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinChatHud.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinClientPlayNetworkHandler.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinClientPlayerInteractionManager.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinCreativeInventoryScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinHandledScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinMessageHandler.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinWorldRenderer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/ChunkPosUtil.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/ContainerInputCompat.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/InteractionCompat.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/SlotClickEventHelper.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/BaseScreen.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/containers/CheckBoxContainer.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/containers/ListContainer.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/containers/MultiElementContainer.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/AnnotatedCheckBox.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/Button.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/Scrollbar.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/Slider.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/TextInput.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/ConfirmOverlay.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/OverlayContainer.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/SelectorDropdownOverlay.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/TextPrompt.java
  • common/src/main/resources/accesswideners/26.1.2-jsmacrosce.accesswidener
  • fabric/build.gradle.kts
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/JsMacrosFabric.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/api/classes/CommandBuilderFabric.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/api/classes/CommandManagerFabric.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinDebugHud.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinGameRenderer.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinKeyboard.java
  • gradle/wrapper/gradle-wrapper.properties
  • settings.gradle.kts
  • stonecutter.gradle.kts
  • versions/26.1.2/gradle.properties
✅ Files skipped from review due to trivial changes (16)
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/ChatHudLineHelper.java
  • gradle/wrapper/gradle-wrapper.properties
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/event/impl/EventRecvMessage.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/ChunkPosUtil.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinDebugHud.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinStyleSerializer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinItemStackRenderStateLayer.java
  • common/src/main/resources/accesswideners/26.1.2-jsmacrosce.accesswidener
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinItemStackRenderState.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinItemRenderer.java
  • versions/26.1.2/gradle.properties
  • common/src/main/java/com/jsmacrosce/wagyourgui/containers/CheckBoxContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Draw2DElement.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/inventory/Inventory.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Image.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Item.java
🚧 Files skipped from review as they are similar to previous changes (40)
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/library/impl/FClient.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/StyleHelper.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/JsMacrosFabric.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/CommandContextHelper.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/api/classes/CommandManagerFabric.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinInGameHud.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinClientPlayerInteractionManager.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/entity/EntityHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/FakeServerCommandSource.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/OverlayContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinMinecraftClient.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/world/StateHelper.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/BaseScreen.java
  • common/src/main/java/com/jsmacrosce/jsmacros/util/SlotClickEventHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/TraceLine.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/overlays/TextOverlay.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/BooleanField.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/Button.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingfields/LongField.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/SelectorDropdownOverlay.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/containers/ListContainer.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/elements/Scrollbar.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/OptionsHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/settingcontainer/PrimitiveSettingGroup.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/Draw2D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/library/impl/FWorld.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/ServiceListTopbar.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/MacroContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/EntityTraceLine.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/settings/CategoryTreeContainer.java
  • fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/api/classes/CommandBuilderFabric.java
  • common/src/main/java/com/jsmacrosce/wagyourgui/overlays/TextPrompt.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components/Line.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/helper/screen/ClickableWidgetHelper.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Surface.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Box.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/api/classes/render/components3d/Line3D.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/events/MixinWorldRenderer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/gui/containers/ServiceContainer.java
  • common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinHandledScreen.java

Comment on lines +56 to +63
//? if <26.1 {
@Inject(at = @At("HEAD"), method = "pick(F)V", cancellable = true)
public void onTargetUpdate(float tickDelta, CallbackInfo ci) {
if (InteractionProxy.Target.onUpdate(tickDelta)) {
ci.cancel();
}
}
//?}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Locate any >=26.1 mixin/inject that calls InteractionProxy.Target.onUpdate to confirm pick parity.
rg -nP --type=java -C3 'InteractionProxy\.Target\.onUpdate'
echo
echo "=== mixins targeting pick / pickProjectile / extractGui under fabric ==="
rg -nP --type=java -C3 'method\s*=\s*"(pick|pickProjectile|extractGui)"'

Repository: JsMacrosCE/JsMacros

Length of output: 3245


The >=26.1 pick replacement is NOT wired in—it exists only as commented-out code.

The @Inject for pick(F)V in common/src/main/java/com/jsmacrosce/jsmacros/client/mixin/access/MixinMinecraftClient.java (lines 126–131) is commented out within the >=26.1 block. This means script-side raycast and interaction target overrides will silently no-op on 26.1. Either uncomment and activate the >=26.1 replacement, or provide an alternative implementation for Minecraft >=26.1.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@fabric/src/main/java/com/jsmacrosce/jsmacros/fabric/client/mixins/access/MixinGameRenderer.java`
around lines 56 - 63, The >=26.1 injection for pick is currently commented out
so InteractionProxy.Target.onUpdate never runs on 26.1+; locate the commented
`@Inject` block in MixinMinecraftClient that was intended to replace pick(F)V (the
stub around the method that mirrors MixinGameRenderer.onTargetUpdate) and either
uncomment and restore the injection so it calls
InteractionProxy.Target.onUpdate(float) and cancels via CallbackInfo when true,
or implement an equivalent hook for the new 26.1+ method signature (ensuring the
injected method name and signature match Minecraft's current pick method and
still calls InteractionProxy.Target.onUpdate and ci.cancel()). Ensure the
injection annotation, method name and parameters match the runtime target so the
override actually executes.

Comment thread settings.gradle.kts
Comment on lines +46 to 55
// see https://fabricmc.net/develop/ for new versions.
// fabric-loom is the legacy alias (LoomGradlePlugin, requires mappings) used for 1.21.x.
// net.fabricmc.fabric-loom is the non-obfuscated plugin (LoomNoRemapGradlePlugin, skips
// mappings) required for MC 26.1+ which ships deobfuscated. Both IDs resolve to the same
// plugin JAR.
id("fabric-loom") version "1.15.4" apply false
id("net.fabricmc.fabric-loom") version "1.15.4" apply false
// see https://projects.neoforged.net/neoforged/moddevgradle for new versions
id("net.neoforged.moddev") version "2.0.139" apply false
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🌐 Web query:

What is the latest stable version of fabric-loom 1.15.x as of April 2026?

💡 Result:

The latest stable version of fabric-loom 1.15.x as of April 2026 is 1.15.5.

Citations:


Update fabric-loom to version 1.15.5.

The dual plugin declaration (fabric-loom for legacy 1.21.x, net.fabricmc.fabric-loom for the deobfuscated 26.1+ path) correctly matches Fabric's official porting guidance for 26.1, and the inline comment captures the rationale precisely. However, the latest stable version in the 1.15.x line is 1.15.5, not 1.15.4. Update both plugin declarations to version "1.15.5".

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@settings.gradle.kts` around lines 46 - 55, Update both fabric-loom plugin
declarations to use the latest 1.15.x release: change the version string on
id("fabric-loom") and id("net.fabricmc.fabric-loom") from "1.15.4" to "1.15.5"
so both plugin entries match the current stable 1.15.5 release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant